A retrospective study included 707 mechanically ventilated patients in the ICU of the First Affiliated Hospital of Jinzhou Medical University from January 2022 to October 2025, with a 48-hour reintubation rate of 17.39% (123/707). Reintubation after extubation is associated with longer ICU and hospital stays and higher mortality. The RF-RFE and LASSO method was used to select the variables, the models were developed by seven machine learning algorithms. The best LASSO-logistic regression model achieved an AUROC of 0.879 (95% CI 0.814–0.935) and a Brier score of 0.090 on the test set (n=211). Analysis of the decision curve confirmed the clinical usefulness of the model. The model is available as a static nomogram and a web-based dynamic nomogram at https://predict-for-reintubation-within-48-hours.shinyapps.io/dynnomapp/. Nomograms integrate key predictors for early identification of at-risk patients.