We obtain an effective analytic formula, with explicit constants, for the number of distinct irreducible factors of a polynomial
$f \in \mathbb {Z}[x]$
. We use an explicit version of Mertens’ theorem for number fields to estimate a related sum over rational primes. For a given
$f \in \mathbb {Z}[x]$
, our result yields a finite list of primes that certifies the number of distinct irreducible factors of f.