The aim of this study was to create a dynamic web-based tool to predict the risks of methicillin-resistant Staphylococcus spp. (MRS) infection in patients with pneumonia. We conducted an observational study of patients with pneumonia at Cho Ray Hospital from March 2021 to March 2023. The Bayesian model averaging method and stepwise selection were applied to identify different sets of independent predictors. The final model was internally validated using the bootstrap method. We used receiver operator characteristic (ROC) curve, calibration, and decision curve analyses to assess the nomogram model’s predictive performance. Based on the American Thoracic Society, British Thoracic Society recommendations, and our data, we developed a model with significant risk factors, including tracheostomies or endotracheal tubes, skin infections, pleural effusions, and pneumatoceles, and used 0.3 as the optimal cut-off point. ROC curve analysis indicated an area under the curve of 0.7 (0.63–0.77) in the dataset and 0.71 (0.64–0.78) in 1000 bootstrap samples, with sensitivities of 92.39% and 91.11%, respectively. Calibration analysis demonstrated good agreement between the observed and predicted probability curves. When the threshold is above 0.3, we recommend empiric antibiotic therapy for MRS. The web-based dynamic interface also makes our model easier to use.