Iron deficiency (ID) is one of the most common micronutrient deficiencies affecting public health. Studies show that ID affects the prognosis of patients with heart disease, including heart failure, coronary artery disease and myocardial infarction. However, there is limited information regarding the impact of ID on patients undergoing cardiac surgery. This study aimed to evaluate the influence of preoperative ID on the prognosis of type 2 diabetes mellitus (T2DM) patients undergoing coronary artery bypass grafting (CABG). In the Glycemic control using mobile-based intervention in patients with diabetes undergoing coronary artery bypass to promote self-management (GUIDEME) study, patients with T2DM undergoing CABG were prospectively recruited. In this study, only those patients with preoperative iron metabolism results were enrolled. Patients were grouped based on the presence of preoperative ID. The primary endpoint was defined as the significant improvement of follow-up ejection fraction (EF) compared to postoperative levels (classified according to the 75th percentile of the change, and defined as an improvement of greater than or equal to 5%). Univariable logistic regression was performed to explore the potential confounders, followed by multiple adjustment. A total of 302 patients were enrolled. No deaths were observed during the study period. A higher incidence of the primary endpoint was observed in the ID group (25.4% vs 12.9%, p = 0.015). The postoperative and follow-up EF were similar beween the two groups. In the regression analysis, ID was noticed to be a strong predictor against the significant improvement of EF in both univariable (odds ratio [OR]: 0.44, 95% confidence interval [CI]: 0.22-0.86, p = 0.017) and multivariable (OR: 0.43, 95% CI: 0.24-0.98, p = 0.043) logistic regression. In the subgroup analysis, ID was a predictor of significant improvement of EF in age 60 years, male, EF 60%, and on-pump CABG patients. In T2DM patients undergoing CABG, ID might negatively affect the early recovery of left ventricular systolic function in terms of recovery of EF 3-6 months after surgery, especially in patients age 60 years, males, EF 60% and in those undergoing on-pump CABG.