NIRS operates by shining near-infrared light onto a sample and measuring the amount of light that is absorbed and scattered. Different molecular bonds absorb light at specific wavelengths, creating a unique absorption spectrum. By analyzing these spectra, scientists can infer the presence and concentration of various biomolecules, such as proteins, lipids, and water.