The heterojunction photodetector between n‐SrTiO3 (n‐STO) and p‐CuS‐ZnS (p‐CZS) is prepared by a simple chemical bath deposition. The p‐CZS/n‐STO photodetector exhibits excellent self‐powered characteristics under 390‐nm light illumination, including high photosensitivity (on/off ratio of 300), fast response speed (0.7/94.6 ms), and good wavelength selectivity (410‐380 nm). More importantly, the self‐powered n‐STO photodetectors can be regulated by varying the composition of CZS film (p‐CZS, p‐CuS, and n‐ZnS). All devices exhibit a large open‐circuit voltage and show different self‐powered behaviors because of the different built‐in electric fields. The open‐circuit voltages of the CZS/STO, CuS/STO, and ZnS/STO devices are measured to be 0.56, 0.30, and 0.35 V, respectively. This work provides a simple and effective way to fabricate tunable self‐powered photodetectors by varying the composition of the nanocomposite film.