Background: Little data are available regarding individual patients’ risk of surgical site infection (SSI) following mastectomy with or without immediate reconstruction. Our objective was to develop a risk prediction model for mastectomy-related SSI. Methods: Using commercial claims data, we established a cohort of women <65 years of age who underwent a mastectomy from 1 January 2004–31 December 2011. International Classification of Diseases, Ninth Revision, Clinical Modification diagnosis codes were used to identify SSI within 180 days after surgery. SSI risk factors were determined with multivariable logistic regression using derivation data from 2004–2008 and validated with 2009–2011 data using discrimination and calibration measures. Results: In the derivation cohort, 595 SSIs were identified in 7607 (7.8 %) women, and 396 SSIs were coded in 4366 (9.1 %) women in the validation cohort. Independent risk factors for SSIs included rural residence, rheumatologic disease, depression, diabetes, hypertension, liver disease, obesity, pre-existing pneumonia or urinary tract infection, tobacco use disorder, smoking-related diseases, bilateral mastectomy, and immediate reconstruction. Receipt of home healthcare was associated with lower risk. The model performed equally in the validation cohort per discrimination (C-statistics 0.657 and 0.649) and calibration (Hosmer–Lemeshow p = 0.091 and 0.462 for derivation and validation, respectively). Three risk strata were created based on predicted SSI risk, which demonstrated good correlation with the proportion of observed infections in the strata. Conclusions: We developed and internally validated an SSI risk prediction model that can be used to counsel women with regard to their individual risk of SSI post-mastectomy. Immediate reconstruction, diabetes, and smoking-related diseases were important risk factors for SSI in this non-elderly population of women undergoing mastectomy.