Filter-free wavelength-selective photodetectors have garnered significant attention due to the growing demand for smart sensors, artificial intelligence, the Internet of Everything, and so forth. However, the challenges associated with large-scale preparation and compatibility with complementary metal-oxide-semiconductor (CMOS) technology limit their wide-ranging applications. In this work, we address the challenges by constructing vertically stacked graded-band-gap zinc-tin oxide (ZTO) thin-film transistors (TFTs) specifically designed for wavelength-selective photodetection. The ZTO thin films with various band gaps are fabricated via atomic layer deposition (ALD) by varying the ALD cycle ratios of zinc oxide (ZnO) and SnO2. The ZTO film with a small Sn ratio exhibits a decreased band gap, and the resultant TFT shows a degraded performance, which can be attributed to the Sn4+ dopant introducing a series of deep-state energy levels in the ZnO band gap. As the ratio of Sn increases further, the band gap of the ZTO also increases, and the mobility of the ZTO TFT increases up to 30 cm2/V s, with a positive shift of the threshold voltage. The photodetectors employing ZTO thin films with distinct band gaps show different spectral responsivities. Then, vertically stacked ZTO (S-ZTO) thin films, with gradient band gaps increasing from the bottom to the top, have been successfully deposited using consecutive ALD technology. The S-ZTO TFT shows decent performance with a mobility of 18.4 cm2/V s, a threshold voltage of 0.5 V, an on-off current ratio higher than 107, and excellent stability under ambient conditions. The resultant S-ZTO TFT also exhibits obviously distinct photoresponses to light at different wavelength ranges. Furthermore, a device array of S-ZTO TFTs demonstrates color imaging by precisely reconstructing patterned illuminations with different wavelengths. Therefore, this work provides CMOS-compatible and structure-compact wavelength-selective photodetectors for advanced and integrable optoelectronic applications.