When atoms or molecules absorb light, the incoming energy excites a quantized structure to a higher energy level. The type of excitation depends on the wavelength of the light. Electrons are promoted to higher orbitals by ultraviolet or visible light, vibrations and other interatomic motions are excited by infrared light, and rotations are excited by microwaves.
An absorption spectrum is the absorption of light as a function of wavelength. The spectrum of an atom or molecule depends on its energy level structure, and absorption spectra are useful for identifying compounds.
Measuring the concentration of an absorbing species in a sample is accomplished by applying the Beer-Lambert Law.