For a ramified covering f : Y --> X between compact complex manifolds, we establish a formula relating the Chern numbers of Y and X. We obtain the formula by localizing characteristic classes via the Cech-de Rham cohomology theory. As corollaries, we deduce generalizations of such formulas as the Riemann-Hurwitz formula and a formula of Hirzebruch for the signature, as well as formulas, for other invariants such as the Todd genus.