Following diagnosis of breast cancer, many women experience serious psychological distress, which can adversely affect their cancer care and outcomes. We conducted this study to examine the association between mental health conditions and hospital outcomes and costs among women undergoing mastectomy for invasive breast cancer. Using nationally representative data from the 2005 to 2008 Nationwide Inpatient Sample, we identified women aged ≥18 years with invasive breast cancer who underwent inpatient mastectomy (N = 40,202). Individuals with a psychiatric diagnosis (major depressive, posttraumatic stress, panic, adjustment, or generalized anxiety disorder) or substance abuse were compared with those without a mental health condition. Outcomes included risk of complications, prolonged hospitalization (>3 days), and direct costs of care. Multivariable logistic and linear regression analyses were performed to control for sociodemographic and clinical characteristics. Overall, 4.5% of patients had a mental health condition. Patients with substance abuse were more likely than those without to experience both complications (8.5% versus 4.8%; adjusted odds ratio [AOR] = 1.61 [1.30–2.00]) and prolonged hospitalization (26.4% versus 13.6%; AOR = 2.25 [1.95–2.59]), and to have higher average costs ($9,855 versus $9,128, p = 0.009). Presence of psychiatric diagnoses was also significantly associated with increased complications (5.9% versus 4.8%; AOR = 1.21 [1.10–1.34]), prolonged hospitalization (8.5% versus 4.8%; AOR = 1.40 [1.32–1.49]), and higher average costs ($9,723 versus $9,108, p < 0.001). Mental health conditions are associated with poorer outcomes and higher costs in breast cancer patients undergoing inpatient mastectomy. Greater efforts are needed to identify and manage these patients with psychiatric and substance use disorders during the perioperative period.