Epitaxial growth of Zn[sub 1-x]Mg[sub x]S alloy thin films on GaP(100) substrates was carried out using the molecular-beam-epitaxy technique. In situ reflection high-energy electron diffraction studies show that the alloys can be grown with a stable zinc-blende structure up to x around 30%. For x>30%, a structural transition will occur at a critical thickness which is sensitively dependent on the x composition. A near-band-edge peak with a full width at half maximum of about 10 nm was observed in room-temperature photoluminescence measurements made on as-grown alloy thin films. Several Zn[sub 1-x]Mg[sub x]S-based Schottky barrier photodetectors were fabricated. Room-temperature photoresponse measurements were performed on these detectors and abrupt long-wavelength cutoffs covering 325, 305, 295, and 270 nm were achieved for devices with Mg composition of 16%, 44%, 57%, and 75%, respectively. The response curve of the Zn[sub 0.43]Mg[sub 0.57]S device offers a close match to the erythemal action spectrum that describes human skin sensitivity to UV radiation. © 2001 American Institute of Physics. [ABSTRACT FROM AUTHOR]