Transparent conducting zirconium-doped zinc oxide (ZnO:Zr) and aluminium-doped zinc oxide (ZnO:Al) thin films were deposited on glass substrates by direct current (DC) magnetron sputtering at room temperature. The crystallinity of ZnO:Zr and ZnO:Al thin films increases as the target-to-substrate distance decreases, and the crystallinity of ZnO:Zr films is found to be always better than that of ZnO:Al films prepared under the same deposition conditions. As the target-to-substrate distance decreases, the resistivity of both film types decreases greatly while the optical transmittance does not change much with the variation of the distance. When target-to-substrate distance is 4.1 cm, the lowest resistivity of 6.0×10-4 Ω·cm and 5.7×10-4 Ω·cm was obtained for ZnO:Zr and ZnO:Al films, respectively. The figure of merit arrived at a maximum value of 3.98×10-2 Ω for ZnO:Zr films lower than 5×10-2 Ω for ZnO:Al films.