Shigella and enterotoxigenic Escherichia coli (ETEC) are major bacterial pathogens of diarrheal disease that is the second leading cause of childhood mortality globally. Currently, it is well known that Shigella spp., and E. coli are very closely related with many common characteristics. Evolutionarily speaking, Shigella spp., are positioned within the phylogenetic tree of E. coli. Therefore, discrimination of Shigella spp., from E. coli is very difficult. Many methods have been developed with the aim of differentiating the two species, which include but not limited to biochemical tests, nucleic acids amplification, and mass spectrometry, etc. However, these methods suffer from high false positive rates and complicated operation procedures, which requires the development of novel methods for accurate and rapid identification of Shigella spp., and E. coli. As a low-cost and non-invasive method, surface enhanced Raman spectroscopy (SERS) is currently under intensive study for its diagnostic potential in bacterial pathogens, which is worthy of further investigation for its application in bacterial discrimination. In this study, we focused on clinically isolated E. coli strains and Shigella species (spp.), that is, S. dysenteriae, S. boydii, S. flexneri, and S. sonnei, based on which SERS spectra were generated and characteristic peaks for Shigella spp., and E. coli were identified, revealing unique molecular components in the two bacterial groups. Further comparative analysis of machine learning algorithms showed that, the Convolutional Neural Network (CNN) achieved the best performance and robustness in bacterial discrimination capacity when compared with Random Forest (RF) and Support Vector Machine (SVM) algorithms. Taken together, this study confirmed that SERS paired with machine learning could achieve high accuracy in discriminating Shigella spp., from E. coli, which facilitated its application potential for diarrheal prevention and control in clinical settings.