Cardiovascular disease is the leading cause of mortality among breast cancer (BC) patients aged 50 and above. Machine Learning (ML) models are increasingly utilized as prediction tools, and recent evidence suggests that incorporating social determinants of health (SDOH) data can enhance its performance. This study included females ≥ 18 years diagnosed with BC at any stage. The outcomes were the diagnosis and time-to-event of major adverse cardiovascular events (MACEs) within two years following a cancer diagnosis. Covariates encompassed demographics, risk factors, individual and neighborhood-level SDOH, tumor characteristics, and BC treatment. Race-specific and race-agnostic Extreme Gradient Boosting ML models with and without SDOH data were developed and compared based on their C-index. Among 4309 patients, 11.4% experienced a 2-year MACE. The race-agnostic models exhibited a C-index of 0.78 (95% CI 0.76–0.79) and 0.81 (95% CI 0.80–0.82) without and with SDOH data, respectively. In non-Hispanic Black women (NHB; n = 765), models without and with SDOH data achieved a C-index of 0.74 (95% CI 0.72–0.76) and 0.75 (95% CI 0.73–0.78), respectively. Among non-Hispanic White women (n = 3321), models without and with SDOH data yielded a C-index of 0.79 (95% CI 0.77–0.80) and 0.79 (95% CI 0.77–0.80), respectively. In summary, including SDOH data improves the predictive performance of ML models in forecasting 2-year MACE among BC females, particularly within NHB.