Herein, the effect of composition on the optical and photocatalytic performance of ZnS–ZnO composite is described. The composite samples are synthesized by chemical precipitation method using (NaOH + Na2S) mixture as the precipitating agent. The chemical composition of precipitating agent results in in situ formation of ZnO and ZnS. Lower content of NaOH in precipitating agent solution (1:3 by volume) exhibits the formation of ZnS, while, its higher concentration induces the phase separation with higher volume fraction of ZnO as observed from X‐ray diffraction patterns. Optical studies suggest the enhancement of visible absorption along with redshift in the absorption edge of composites as compared with bare ZnS nanoparticles (NPs). Moreover, the incorporation of ZnO with ZnS is also supported by optical emission spectra in which intense emission around 507 nm is associated with S‐species. ZnO encapsulation on ZnS NPs exhibits higher emission associated with O‐ defects as compared to S‐species. Since both are near‐UV excited semiconductors, both contribute toward the generation of charge carriers to produce radicals and hence photo‐oxidation of crystal violet dye. Further, little concentration of ZnO with ZnS NPs exhibits comparable photocatalytic efficiency (≈88%) that is observed with other ZnS–ZnO nanocomposite samples.