In reality, each shot already represents a colorthe wavelength of light captured by the filter when that picture was taken. But in some cases the images represent colors that we wouldn't be able to see...To create a composite image that has the full range of colors seen by the human eye, an astronomer picks one image and makes it red, picks another and makes it blue, and completes the set by coloring a third image green. When he overlays the three images, one on top of the other, they produce a full-color picture. (Televisions and computer monitors create color in the same way.)
(The galaxy above lies 6 million light-years away in the north circumpolar constellation Ursa Major. More images released this week by NASA here.)