Diabetic foot ulcers are the most common and serious complication of diabetes mellitus, the high morbidity, mortality, and disability of which greatly diminish the quality of life of patients and impose a heavy socioeconomic burden. Thus, it is urgent to identify potential biomarkers and targeted drugs for diabetic foot ulcers. In this study, we downloaded datasets related to diabetic foot ulcers from gene expression omnibus. Dysregulation of mitophagy-related genes was identified by differential analysis and weighted gene co-expression network analysis. Multiple machine algorithms were utilized to identify hub mitophagy-related genes, and a novel artificial neural network model for assisting in the diagnosis of diabetic foot ulcers was constructed based on their transcriptome expression patterns. Finally, potential drugs that can target hub mitophagy-related genes were identified using the Enrichr platform and molecular docking methods. In this study, we identified 702 differentially expressed genes related to diabetic foot ulcers, and enrichment analysis showed that these genes were associated with mitochondria and energy metabolism. Subsequently, we identified hexokinase-2, small ribosomal subunit protein us3, and l-lactate dehydrogenase A chain as hub mitophagy-related genes of diabetic foot ulcers using multiple machine learning algorithms and validated their diagnostic performance in a validation cohort independent of the present study (The areas under roc curve of hexokinase-2, small ribosomal subunit protein us3, and l-lactate dehydrogenase A chain are 0.671, 0.870, and 0.739, respectively). Next, we constructed a novel artificial neural network model for the molecular diagnosis of diabetic foot ulcers, and the diagnostic performance of the training cohort and validation cohort was good, with areas under roc curve of 0.924 and 0.840, respectively. Finally, we identified retinoic acid and estradiol as promising anti-diabetic foot ulcers by targeting hexokinase-2 (-6.6 and -7.2kcal/mol), small ribosomal subunit protein us3 (-7.5 and -8.3kcal/mol), and l-lactate dehydrogenase A chain (-7.6 and -8.5kcal/mol). The present study identified hexokinase-2, small ribosomal subunit protein us3 and l-lactate dehydrogenase A chain, and emphasized their critical roles in the diagnosis and treatment of diabetic foot ulcers through multiple dimensions, providing promising diagnostic biomarkers and targeted drugs for diabetic foot ulcers.