Background Loss of function of key autophagy genes are associated with a variety of diseases. However specific role of autophagy-related genes in erectile dysfunction ED remains unclear. This study explores the autophagy-related differentially expressed genes (ARGs) profiles and related molecular mechanisms in Corpus Cavernosum endothelial dysfunction, which is a leading cause of ED. Methods The Gene Expression Omnibus (GEO) database was used to identify the key genes and pathways. Differentially expressed genes (DEGs) were mined using the limma package in R language. Next, ARGs were obtained by matching DEGs and autophagy-related genes from GeneCard using Venn diagrams. Gene Ontology (GO) and Kyoto Encyclopedia of Genes and Genomes (KEGG) analyses of ARGs were described using clusterProfiler and org.Hs.eg.db in R. Moreover, hub ARGs were screened out through protein-protein interaction (PPI), gene-microRNAs, and gene-transcription factors (TFs) networks then visualized using Cytoscape. Of note, the rat model of diabetic ED was established to validate some hub ARGs with qRT-PCR and Western blots. Results Twenty ARGs were identified from four ED samples and eight non-ED samples. GO analysis revealed that molecular functions (MF) of upregulated ARGs were mainly enriched in nuclear receptor activity. Also, MF of downregulated ARGs were mainly enriched in oxidoreductase activity, acting on NAD(P)H and heme proteins as acceptors. Moreover, six hub ARGs were identified by setting high degrees in the network. Additionally, hsa-mir-24-3p and hsa-mir-335-5p might play a central role in several ARGs regulation, and the transcription factors-hub genes network was centered with 13 ARGs. The experimental results further showed that the expression of Notch1, NOS3, and CDKN2A in the diabetic ED group was downregulated compared to the control. Conclusions Our study deepens the autophagy-related mechanistic understanding of endothelial dysfunction of ED. NOTCH1, CDKN2A, and NOS3 are involved in the regulation of endothelial dysfunction and may be potential therapeutic targets for ED by modulating autophagy.