A UV-Vis detector operates based on the principle of light absorption. When light passes through a sample, certain wavelengths are absorbed by the molecules, while others pass through. The detector measures the intensity of light before and after it passes through the sample, allowing the calculation of absorbance. This data can be used to determine the concentration of specific compounds by applying the Beer-Lambert Law.