Type 2 diabetes mellitus (T2DM) is a major risk factor for heart disease. Mortality rates after myocardial infarction (MI) are significantly increased in T2DM patients because of dysfunctional left ventricle (LV). However, molecular pathways underlying accelerated heart failure (HF) after MI in T2DM remain unclear. We investigated the underlying mechanisms by inducing MI in a well-established model of T2DM and control mice. Cardiac imaging revealed a significantly decreased global left ventricular ejection fraction in parallel with increased mortality after MI in T2DM mice compared with control mice. Genome-wide mRNA sequencing, immunoblot, electron microscopy, together with immunofluorescence staining for LC3 and p62 indicated an impaired mitophagy in peri-infarct regions of LV in T2DM mice compared with control mice. Furthermore, defective mitophagy was associated with an increased release of mitochondrial DNA, resulting in Aim2 and NLRC4 inflammasome and caspase-I hyperactivation in cardiomyocytes and cardiac macrophages in peri-infarct regions of LV in T2DM mice. Consistent with inflammasome and caspase-I hyperactivation, cardiomyocyte death and IL-18 secretion were increased in T2DM mice. Our results indicate that T2DM aggravates HF after MI through defective mitophagy, associated exaggerated inflammasome activation, cell death, and IL-18 secretion, suggesting that restoring mitophagy and inhibiting inflammasome activation may serve as novel targets for the prevention and treatment of HF in T2DM.