Salmonella is one of the most important foodborne pathogens, which causes a huge economic burden worldwide. To detect Salmonella rapidly is very meaningful in preventing salmonellosis and decreasing economic losses. Currently, isolation of Salmonella is confirmed by biochemical and serobased serotyping methods, which are time consuming, labor intensive, and complicated. To solve this problem, a hexa-plex polymerase chain reaction (PCR) method was developed using comparative genomics analysis and multiplex PCR technology to detect Salmonella and Salmonella Typhimurium, Salmonella Enteritidis, Salmonella Agona, Salmonella Choleraesuis, and Salmonella Pullorum simultaneously. The accuracy of this method was tested by a collection of 142 Salmonella. Furthermore, the strategy described in this article to mine serovar-specific fragments for Salmonella could be used to find specific fragments for other Salmonella serotypes and bacteria. The combination of this strategy and multiplex PCR is promising in the rapid identification of foodborne pathogens.