I can tell you what you're made of just by looking at you. Through a spectrometer.
Who can take a rainbow, mix it with a sigh, soak it in the sun and make a strawberry lemon pie? The candyman. But who can take a rainbow, look at the ominous dark spots in it, and label it the absorption spectrum for a sun-like star? The spectroscoper can.
Possibly the most powerful scientific tools out there are the two things embedded in the front of your skull. Eyeballs have been, and continue to be, the most sensitive and useful scientific apparatus we have. They may fail us, or play tricks on us, but they remain incredible data collectors because they are sensitive to something that gives us a huge amount of information: light.
Spectrometers, like much other scientific equipment out there, were invented to take over when the limits of our eyes have been reached. Spectrometers do not amplify low light, and although they are used to analyze wavelengths of light that humans can't see, that's not their primary purpose. They were built to make it obvious to see which wavelengths of light are missing, or present, when our eyes can see only a mishmash of many different wavelengths.
To some extent, we are able to see when certain wavelengths are missing. When a light shines red, we're able to see that the wavelengths at blue end of the spectrum are either not emitted or are filtered out. Spectrometers make that process more accurate.
Spectrometers take in light and separate it out into different wavelengths, much like raindrops or prisms do. Different wavelengths are bent at different angles when they pass through certain substances. This is shown when sunlight passes through a prism and makes a rainbow. The rainbow is continuous, because sunlight is a combination of many different wavelengths and because a prism isn't that detailed a spectrometer. A lot of light sources are missing certain wavelengths.
Light is emitted when the electrons in an atom's electrons get excited enough to jump up to a higher energy level, and then fall down again. During the fall, they emit a photon. The photon's energy level corresponds to the energy dropped by the electron. That energy determines the wavelength of the light emitted. Electrons can jump only precise amounts, depending on which atom they're attached to, and therefore emit only precise wavelengths. Those wavelengths will show up on a spectrometer as bands of color.
Spectrometers don't just analyze things which emit light. They also analyze things that absorb it. When a light shines on, or through, an object, it's electons, again depending on their position and the atom they're attached to, absorb only certain wavelengths. The other wavelengths pass through. When those wavelenghths are sent through a spectrometer, the continuous band of color is disrupted by dark spots. Those correspond to wavelengths of light which are absorbed.
By studying the absorption and emission spectra for different elements, scientists can figure what objects are made of just by analyzing the light that they give off, or reflect. Spectroscopy is vital to astronomers, who use it to study the composition of heavenly bodies. It helped identify the properties of quasars, the minerals present on the surface of planets, and the composition of stars. Not bad for something as insubstantial as a rainbow.