Dental plaque biofilms are responsible for numerous chronic oral infections and cause a severe health burden. Many of these infections cannot be eliminated, as the bacteria in the biofilms are resistant to the host's immune defenses and antibiotics. There is a critical need to develop new strategies to control biofilm-based infections. Biofilm formation in Streptococcus mutans is promoted by major virulence factors known as glucosyltransferases (Gtfs), which synthesize adhesive extracellular polysaccharides (EPS). The current study was designed to identify novel molecules that target Gtfs, thereby inhibiting S. mutans biofilm formation and having the potential to prevent dental caries. Structure-based virtual screening of approximately 150,000 commercially available compounds against the crystal structure of the glucosyltransferase domain of the GtfC protein from S. mutans resulted in the identification of a quinoxaline derivative, 2-(4-methoxyphenyl)-N-(3-{[2-(4-methoxyphenyl)ethyl]imino}-1,4-dihydro-2-quinoxalinylidene)ethanamine, as a potential Gtf inhibitor. In vitro assays showed that the compound was capable of inhibiting EPS synthesis and biofilm formation in S. mutans by selectively antagonizing Gtfs instead of by killing the bacteria directly. Moreover, the in vivo anti-caries efficacy of the compound was evaluated in a rat model. We found that the compound significantly reduced the incidence and severity of smooth and sulcal-surface caries in vivo with a concomitant reduction in the percentage of S. mutans in the animals' dental plaque (P < 0.05). Taken together, these results represent the first description of a compound that targets Gtfs and that has the capacity to inhibit biofilm formation and the cariogenicity of S. mutans.