Purpose: To analyse the related risk factors of moderate to severe asthma attack in children by logistic regression and decision tree. Patients and Methods: A retrospective analysis of clinical data of children diagnosed with asthma attacks in our hospital from January 2020 to August 2023 was conducted. The patients were divided into mild group (n=459, 57.02%) and moderate to severe group (n=346, 42.98%). Related risk factors of moderate to severe asthma attack in children were analyzed by univariate logistic regression, and then multivariate logistic regression and decision tree model were obtained. Results: The results of univariate logistic regression showed that there were significant differences between the two groups in age, medical history, allergy history, family history, C-reactive protein (CRP), neutrophil percentage (NEU%), Mycoplasma pneumoniae (MP) infection, Rhinovirus (RV) infection (all p < 0.05). The results of multivariate logistic regression showed that age (≥ 6 years) (OR=1.636, 95% CI=1.046– 2.559), medical history (OR=1.460, 95% CI=1.063– 2.006), allergy history (OR=2.387, 95% CI=1.733– 3.288), family history (OR=2.564, 95% CI=1.619– 4.058), NEU% (OR=1.020, 95% CI=1.009– 1.031), MP infection (OR=2.140, 95% CI=1.571– 2.916), RV infection (OR=4.546, 95% CI=2.274– 9.089) were related risk factors of moderate to severe asthma attack in children (all p< 0.05). The decision tree model showed that MP infection, CRP, allergy history, NEU%, and medical history were risk factors of moderate to severe asthma attacks in children, with importance levels of 0.41, 0.29, 0.134, 0.130, and 0.061, respectively. Multivariate logistic regression (AUC=0.733, 95% CI: 0.698~0.767) and decision tree (AUC=0.694, 95% CI: 0.658~0.731) both exhibited good prediction accuracy. Conclusion: Allergic history, medical history, MP infection, and increased NEU% were related risk factors that predict moderate to severe asthma attack in children. Multivariate logistic regression and decision tree both had a good predictive effect for analyzing the risk factors of moderate to severe asthma attack in children.