A pulse oximeter measures oxygen saturation in the blood by using light to detect the different absorption rates of oxygenated and deoxygenated hemoglobin. It shines red and infrared light through a finger and detects the amounts of light absorbed, which depends on the concentration and path length of hemoglobin in the blood. Oxygenated hemoglobin absorbs more infrared light, while deoxygenated hemoglobin absorbs more red light. By calculating the ratio between these light absorptions, the pulse oximeter can determine the oxygen saturation percentage. Pulse oximetry is commonly used in operating rooms, ICUs, and other clinical settings to monitor patients.