Background: APETALA2/ETHYLENE RESPONSIVE FACTOR (AP2/ERF) transcription factors play important roles in plant growth, development, metabolism, as well as in biotic and abiotic stress responses. However, there are few studies concerning AP2/ERF genes in sugarcane, which is the most critical sugar and energy crop worldwide. Results: A total of 218 AP2/ERF genes were identified in the Saccharum spontaneum genome. Phylogenetic analysis showed that these genes could be divided into four groups, including 43 AP2s, 160 ERFs, and Dehydration-responsive element-binding (DREB) factors, 11 ABI3/VPs (RAV) and 4 Soloist genes. These genes were unevenly distributed on 32 chromosomes. Analysis of the structural of SsAP2/ERF genes showed that 91 SsAP2/ERFs lacked introns. Sugarcane and sorghum have a collinear relationship between 168 SsAP2/ERF genes and sorghum AP2/ERF genes that reflects their similarity. Multiple cis-regulatory elements (CREs) are present in the SsAP2/ERF promoter, and many are related to abiotic stresses, suggesting that SsAP2/ERF activity could contribute to the adaptation of sugarcane crops to environmental changes. The tissue-specific analysis showed spatiotemporal expression of SsAP2/ERF in the stems and leaves of sugarcane at different stages of development. In 10 sugarcane samples, 39 SsAP2/ERFs were not expressed at all, whereas 58 SsAP2/ERFs were expressed in all samples. Quantitative PCR experiments showed that SsERF52 expression was up-regulated under salt stress, but suppressed under drought stress. SsSoloist4 had the most considerable upregulation in response to treatment with the exogenous hormones ABA and GA. Within 3 hours of ABA or PEG6000 treatment, SsSoloist4 expression was up-regulated, indicating that this gene could play a role in ABA and GA-associated drought stress response mechanisms. Analysis of AP2/ERF gene expression patterns under different treatments indicated that SsAP2/ERF genes play an important role in drought and salt stress responses of S. spontaneum. Conclusions: In this study, a total of 218 members of the AP2 / ERF superfamily were identified in sugarcane, and their genetic structure, evolution characteristics, and expression patterns were studied and analyzed. The results of this study provide a foundation for future analyses to elucidate the importance of AP2/ERF transcription factors in the function and molecular breeding of sugarcane.