Deep-ultraviolet photoluminescence spectroscopy has been employed to study the temperature and compositional dependence of the band gap of AlxGa1−xN alloys in the temperature range between 10 and 800 K. Band-edge emission peaks in AlxGa1−xN alloys were fitted by the Varshni equation to obtain Varshni coefficients, which increase nonlinearly with x. The values of Varshni coefficients obtained for GaN and AlN binary compounds in the present study are in good agreement with the previously reported values. Based on the experimental data, the compositional and temperature dependence of the band gap of AlxGa1−xN alloy has been empirically determined for the entire alloy range.