Ten kinds of common sulfide flavors were selected and their inhibitory ability on Staphylococcus aureus and Listeria monocytogenes was investigated by measuring the diameter of inhibition zone. The relationship between the structure of sulfide flavors and the antibacterial ability was also analyzed. The sulfide flavor with the strongest antibacterial activity was selected and its effect on the expression of nuc gene in Staphylococcus aureus was investigated by qRT-PCR. The results showed that diallyl disulfide (DADS), methyl furfuryl disulfide (MFDs) and allyl sulfide (DAS) had good antibacterial effects on two Gram-positive bacteria, and the antibacterial activity was DADS > MFDS > DAS. Among the 10 kinds of sulfide flavors, DADS had the strongest antibacterial activity, and the minimum inhibitory concentration (MIC) of DADS against S. aureus and L. monocytogenes were 312.5 mmol/L and 1.25 mol/L, respectively. At the subinhibitory concentrations (1/16 MIC, 1/8 MIC, 1/4 MIC and 1/2 MIC), DADS significantly decreased the expression level of nuc gene in S. aureus (P<0.01). These results indicated that allyl and disulfide bonds could enhance the antibacterial activity of sulfide flvors and play an important role in inhibiting the virulence of S. aureus.