The colour of e.g. an apple in the visible spectrum gives us information on a variety of pigments and chemicals in the fruit, but we can not ‘see’ things that do not absorb visible light (e.g. a sugar solution).
It happens that water, sugar, acids and a range of other organic substances absorb near infra-red in proportion to their concentration.
Spectroscopy is rapid, timely, less expensive, non-destructive, straightforward and sometimes more accurate than conventional analysis