Drug screening resembles finding a needle in a haystack: identifying a few effective inhibitors from a large pool of potential drugs. Large experimental screens are expensive and time-consuming, while virtual screening trades off computational efficiency and experimental correlation. Here we develop a framework that combines molecular dynamics (MD) simulations with active learning. Two components drastically reduce the number of candidates needing experimental testing to less than 20: (1) a target-specific score that evaluates target inhibition and (2) extensive MD simulations to generate a receptor ensemble. The active learning approach reduces the number of compounds requiring experimental testing to less than 10 and cuts computational costs by ∼29-fold. Using this framework, we discovered BMS-262084 as a potent inhibitor of TMPRSS2 (IC50 = 1.82 nM). Cell-based experiments confirmed BMS-262084’s efficacy in blocking entry of various SARS-CoV-2 variants and other coronaviruses. The identified inhibitor holds promise for treating viral and other diseases involving TMPRSS2.