UVB irradiation and diabetes lead to skin injury. However, UVB irradiation has rarely been studied in the field of diabetes. Silibinin has a positive therapeutic effect on many diseases. Nevertheless, the inhibitory effects of silibinin on UVB-induced damage to epidermal cells under high glucose (HG) conditions have been infrequently investigated. Consequently, this study examined the protective efficacy and mechanisms of silibinin in mitigating UVB-induced apoptosis in epidermal cells cultured under HG conditions. The effects of combination of HG and UVB on mitochondrial apoptosis and pro-inflammatory factors production in human immortalized keratinocytes (HaCaT) were mitigated by silibinin. Meantime, silibinin reversed the UVB-induced imbalance of fission/fusion in HG-cultured HaCaT cells. Furthermore, UVB exposure increased ROS levels and reduced mitophagy in HaCaT cells under HG conditions; however, these effects were subsequently reversed by silibinin treatment. AMPK preserves energy balance by negatively regulating YAP. Silibinin increased the levels of p-AMPK and cytoplasmic YAP proteins in HaCaT cells subjected to HG and UVB treatment. Moreover, silibinin improved the dysfunction of mitochondrial dynamics, increased mitophagy levels, the viability and the expression of cytoplasmic YAP protein, and these effects were reversed via the application of an AMPK inhibitor (compound C). In summary, silibinin safeguarded epidermal cells from UVB-induced apoptosis under HG conditions by modulating mitochondrial dynamics and mitophagy through the AMPK-YAP signaling pathway.