In this research, Al-doped and (Al, Fe) codoped ZnO films were prepared on glass substrate by the sol–gel method. The surface morphology, structure, and optical property were characterized by scanning electron microscope (SEM), X-ray diffraction (XRD), X-ray photoelectron spectroscopy (XPS), and Ultraviolet-Visible-Near-infrared (UV-Vis-NIR) spectroscopy. The film surface morphologies all exhibited granular characteristics. With the Fe doping concentration increasing, the codoped films had smaller grain size and tended to be smoother. XRD analysis revealed that all films had a hexagonal wurtzite structure. The codoping can contribute to more Al and Fe ions entering the ZnO crystal structure, but result in the crystalline degree of the films decreasing. XPS results showed that the Al and Fe irons in the films exist in the form of trivalent. Moreover, the doped films had higher transmission, especially for codoped (Fe:Al = 3) film, but their absorption edge shifted to the short-wavelength direction.