We study the CO(1-0)-to-H 2 conversion factor (X CO ) and the line ratio of CO(1-0)-to-CO(2-1) (R 21 ) across a wide range of metallicity (0.1 ≤ Z/Z ≤ 3) in high-resolution (∼0.2 pc) hydrodynamical simulations of a self-regulated multiphase interstellar medium. We construct synthetic CO emission maps via radiative transfer and systematically vary the "observational" beam size to quantify the scale dependence. We find that the kpc-scale X CO can be over-estimated at low Z if assuming steady-state chemistry or assuming that the star-forming gas is H 2 -dominated. On parsec scales, X CO varies by orders of magnitude from place to place, primarily driven by the transition from atomic carbon to CO. The pc-scale X CO drops to the Milky Way value of 2 × 10 20 cm −2 (K km s −1 ) −1 once dust shielding becomes effective, independent of Z. The CO lines become increasingly optically thin at lower Z, leading to a higher R 21 . Most cloud area is filled by diffuse gas with high X CO and low R 21 , while most CO emission originates from dense gas with low X CO and high R 21 . Adopting a constant X CO strongly over-(under-)estimates H 2 in dense (diffuse) gas. The line intensity negatively (positively) correlates with X CO (R 21 ) as it is a proxy of column density (volume density). On large scales, X CO and R 21 are dictated by beam averaging, and they are naturally biased towards values in dense gas. Our predicted X CO is a multivariate function of Z, line intensity, and beam size, which can be used to more accurately infer the H 2 mass.