The drug resistance of Staphylococcus aureus, Streptococcus pneumoniae, Streptococcus pyogenes and Haemophilus influenzae has become more and more serious, and it is urgent to seek new antibacterial drugs. In this study, Thesium chinense Turcz. extracts were tested for its potential antibacterial activities. T. chinense powder was extracted with 5 solvents of different polarity (ethyl alcohol, petroleum ether, ethyl acetate, n-butyl alcohol and double distilled water), and their antibacterial activities were tested. The Broth dilution method was used to evaluate the minimum inhibitory concentration (MIC) and minimum bactericidal concentration (MBC) of highly active plant extracts with a concentration of 1g/mL. The inhibitory activity of this extract on biofilm formation was investigated. Afterwards, we investigated its effect on the transcriptome of S. aureus. The ethanol extract coded as BRY, only inhibited S. aureus, whereas the ethyl acetate extract coded as BY2 showed inhibitory effect on all the tested bacteria. The MIC of BRY on S. aureus was 128 mg/mL, and the MBC was 512 mg/mL. The MIC of BY2 against S. aureus, S. pneumoniae, S. pyogenes and H. influenzae were 8 mg/mL, 4 mg/mL, 4 mg/mL, and 4 mg/mL, respectively. The MBC of BY2 for these four bacteria ranged from 4 to 256 mg/mL. Mechanism studies have shown that BRY and BY2 have an impact on anti-formation of biofilms at MIC concentrations. Transcriptome sequencing results showed that 531 genes were up-regulated and 340 genes showed down-regulated expression in S. aureus after BY2 treatment. BY2 has a broader antibacterial spectrum than BRY. Meanwhile, the inhibitory effect of BY2 on S. aureus is better than BRY. The mechanism of BY2 against S. aureus may relate to its inhibition of ribosome synthesis, restriction of key enzymes of citric acid cycle, decrease of pathogenicity and influence on biofilm formation. The results confirmed that BY2 was the main antibacterial part of T. chinense, which can be used as a source of antibacterial agents.