Chemical spray pyrolysis (CSP) was utilized to create pure Zinc Sulfide (ZnS) and magnesium (Mg) doped thin films on a clean glass substrate at a temperature equal to 400°C. X-ray diffraction test revealed a cubic wurtzite crystal structure with average crystallite sizes of 10.99 and 12.27 nm for ZnS and ZnS: Mg, respectively. XRD analysis of the doped films revealed a polycrystalline structure with a predominant peak along the (220) plane and additional peaks along the (111), (200), and (222) planes. The grain size raised from 10.99 to 12.27 nm as a result of the XRD patterns. The increase in Mg content from 0% to 3%, affect the bandgap that fell from 3.52 to 3.42 eV. As the Mg content increased, the transmittance and refractive index of the films was lowered.