Two-photon microscopy relies on the principle of two-photon absorption, where two photons of lower energy (usually in the infrared spectrum) are absorbed simultaneously by a fluorescent molecule. This results in the emission of a single photon with higher energy, usually in the visible range. This non-linear process occurs only at the focal point of the laser, allowing for highly localized excitation and reducing photodamage to surrounding tissues.