Owing to its ultrafast scintillation, quite high light yield, strong radiation resistance, and non-deliquescence, ZnO(Ga) is a highly promising choice for an ultrafast X-ray detector. Because of its high deposition rate, good production repeatability and strong adhesive force, reactive magnetron sputtering was used to produce a ZnO(Ga) crystal on a quartz glass substrate, after the production conditions were optimized. The fluorescence lifetime of the sample was 173 ps. An ultrafast X-ray scintillating detector, equipped with a fast microchannel plate (MCP) photomultiplier tube (PMT), was developed and the X-ray tests show a signal full width at half maximum (FWHM) of only 385.5 ps. Moreover, derivation from the previous measurement shows the ZnO(Ga) has an ultrafast time response (FWHM = 355.1 ps) and a high light yield (14740 photons/MeV).