Medical institutions worldwide strive to avoid adverse medical events, including adverse medication-related events. However, studies on the comprehensive analysis of medication-related adverse events are limited. Therefore, we aimed to identify the error factors contributing to medication-related adverse events using the Human Factors Analysis and Classification System (HFACS) and to develop error models through logistic regression. These models calculate the probability of a medication-related adverse event when a healthcare system defect occurs. Seven experts with at least 12 years of work experience (four nurses and three pharmacists) were recruited to analyze thirty-seven medication-related adverse events. The findings indicate that decision errors, physical/mental limitations, failure to correct problems, and organizational processes were the four factors that most frequently contributed to errors at the four levels of the HFACS. Seven error models of two types (error occurrence and error analysis pathways) were established using logistic regression models, and the relative probabilities of failure factor occurrences were calculated. Based on our results, medical staff can use the error models as a new analytical approach to improve and prevent adverse medication events, thereby improving patient safety.