Hubble takes a spectrum of the star HD 189733 and the fully illuminated planet HD 189733b. By subtracting the star's spectrum from the combined spectrum, the spectrum of the planet is obtained.
Credit: NASA, ESA, and A. Feild (STScI)