Photoluminescence is a common technique used to characterize the optoelectronic properties of semiconductors and other materials. Its principle is simple: electrons are excited from the valence to the conductance band of the material by a laser with an energy larger than the bandgap. As a consequence, the photoexcited carriers relax and then spontaneously recombine with holes in the conduction band. In the case of direct semiconductors, the excess energy is emitted in the form of light (spontaneous emission). By analyzing the spectrum of the emitted light, it is possible to measure the material's response in terms of intensity as a function of wavelength. This gives access to information about the band structure – the bandgap width, the relative light generation efficiency, the quality of the material (inhomogeneous broadening), etc. Additional information can be gained by controlling the sample's environment, e.g., adding a magnetic field or changing the sample's temperature.