In summary, we identified five hub genes (JUN, NFE2L2, ATG5, KRAS, and HSPA5) that are closely associated with ferroptosis in diabetic islets, which are thus potential ferroptosis-related biomarkers for T2D therapy. This evidence concerns the gene HSPA5 and type 2 diabetes mellitus.