Methylglyoxal (MGO) is an active metabolite of glucose and plays a prominent role in the pathogenesis of diabetic vascular complications, including endothelial cell apoptosis induced by oxidative stress. Metformin (MET), a widely prescribed antidiabetic agent, appears to reduce excessive reactive oxygen species (ROS) generation and limit cell apoptosis. However, the molecular mechanisms underlying this process are still not fully elucidated. We reported here that MET prevents MGO-induced apoptosis by suppressing oxidative stress in vitro and in vivo. Protein expression and protein phosphorylation were investigated using western blotting, ELISA, and immunohistochemical staining, respectively. Cell viability and apoptosis were assessed by the MTT assay, TUNEL staining, and Annexin V-FITC and propidium iodide double staining. ROS generation and mitochondrial membrane potential (MMP) were measured with fluorescent probes. Our results revealed that MET prevented MGO-induced HUVEC apoptosis, inhibited apoptosis-associated biochemical changes such as loss of MMP, the elevation of the Bax/Bcl-2 ratio, and activation of cleaved caspase-3, and attenuated MGO-induced mitochondrial morphological alterations in a dose-dependent manner. MET pretreatment also significantly suppressed MGO-stimulated ROS production, increased signaling through the ROS-mediated PI3K/Akt and Nrf2/HO-1 pathways, and markedly elevated the levels of its downstream antioxidants. Finally, similar results were obtained in vivo, and we demonstrated that MET prevented MGO-induced oxidative damage, apoptosis, and inflammation. As expected, MET reversed MGO-induced downregulation of Nrf2 and p-Akt. In addition, a PI3K inhibitor (LY-294002) and a Nrf2 inhibitor (ML385) observably attenuated the protective effects of MET on MGO-induced apoptosis and ROS generation by inhibiting the Nrf2/HO-1 pathways, while a ROS scavenger (NAC) and a permeability transition pores inhibitor (CsA) completely reversed these effects. Collectively, these findings broaden our understanding of the mechanism by which MET regulates apoptosis induced by MGO under oxidative stress conditions, with important implications regarding the potential application of MET for the treatment of diabetic vascular complications.