Transparent and high preferential c-axis-oriented ZnO thin films doped with SiO2 have been prepared by sol–gel method using zinc nitrate and tetraethylorthosilicate as precursors, absolute ethanol as solvent, and diethanolamine as sol stabilizer. Thin film deposition was performed by spin coating technique at a spinning speed of 2000 rpm/sec on glass substrate followed by calcinations at 500 °C. The structural characteristics of the samples were analyzed by x-ray diffractometer and atomic force microscope. The optical properties were studied by an ultraviolet–visible spectrophotometer. The results show that all the prepared ZnO thin films have a compact hexagonal wurtzite structure. With the change in the amount of SiO2 dopants, the intensity of (002) peak, particle size, surface root mean square roughness, thickness, transmittance, absorbance, and the optical band gap of the ZnO–SiO2 thin films were changed as well.