A grating spectrometer with a CCD photorecording system operating in the near infrared and visible spectral regions is presented. The spectrometer has the spectral resolution of 0.036 cm-1 and allows recording of absorption spectra with the accuracy of 0.003 cm-1 in line positions and 3% in the absorption coefficient. Absorption spectra of the atmospheric air were recorded with a 1-m long absorbing layer.