"Redshift" is a term that astronomers use a lot. This is particularly true if they are extragalactic astronomers or (especially) cosmologists, but even galactic astronomers use it, and it is absolutely central to the method use to discover most of the extrasolar planets known today.
This post is going to be divided into three parts. First, I am going to explain that redshift itself is just a definition of an observable or measurable quantity, without any need to reference what caused it. Second, I'm going to talk about the more familiar source of redshift -- the Doppler shift. Finally, I'll talk about the gravitational redshift-- and, specifically, the cosmological redshift-- that is what astronomers are talking about when they talk about the expansion of the Universe.
The Observational Definition of Redshift
When you take a spectrum of an object, you are breaking its light out into its constituent colors. Many people are familiar with the fact that if you shine sunlight through a prism, you see a rainbow. Indeed, below is a picture of a high-resolution spectrum of the Sun taken at Kitt Peak. Visualize all the horizontal bands put end-to-end to make a really, really long rainbow— that's what makes it so high resolution!
There's something to notice here other than the rainbow: the dark bands. These are called "absorption lines." They are very specific colors — very specific wavelengths of light — where some type of atom found in the atmosphere of the Sun absorbs light. The neat thing about this is that the wavelengths of those lines are set by atomic physics. We can figure them out from calculations, or by making measurements in the lab. (In practice, we need both; some species, such as the Hydrogen atom, can be calculated very well. Other atoms and molecules are harder to calculate, so sometimes the calculations need to be supplanted with empirical determination.)
When we say we observe a redshift, we say that we are observing light whose wavelength has been shifted. For example, in red light, there's a well-known line that comes from the Hydrogen atom at 6563 Angstroms. If we observe a star that has that absorption line, but it shows up at 6567 Angstroms, we know that the light has been shifted to a wavelength that is 4 Angstroms longer. We know from atomic physics that when the light was emitted, it was at 6563 Angstroms, so something has happened between emission and detection to make the observed wavelength different.
We define the quantity redshift — often denoted with the variable z — as the difference in thew wavelength divided by the original wavelength. In my example above, the redshift z would be 4 Angstroms divided by 6563 Angstroms, or z=0.0006. If light shifts to shorter wavelengths, we would call that a negative redshift— or, sometimes a blueshift. (Red light has a longer wavelength than blue light, hence "redshift" being a shift to longer wavelength, although that would term apply even in the case of a shift from the red fo the infrared.)
And that's all there is to it! We can define and measure what redshift is without any reference to what causes it.
So what causes it?
The Doppler Shift
Most of us are familiar with the Doppler shift in sound. When a car goes by you, you hear the characteristiic "...rrrrrrRRRRROOOWWWWwwwww..." sound, with the pitch higher at first as it is coming towards you, and lower later when the car is moving away from you. The same thing happens with light. If I'm looking at you, and you are moving away from me, I will see all the light you emitted shifted to the red.
For low speeds (i.e. a lot less than the speed of light), it turns out that the redshift is just the speed of the emitter relative to the observer divided by the speed of light! Consider the example above. Suppose that you are holding a vapor tube with rarefied Hydrogen in it, and that Hydrogen is emitting light at 6563 Angstroms. If I observe that light at 6567 Angstroms, I would say that's a shift of 4 Angstroms, giving me a redshift z=0.0006 Angstroms, implying that you're moving 0.0006 times the speed of light (or about 400,000mph). (Slow down! Woah!)
If you were coming towards me, I would observe any light you emitted to be blueshifted— that is, I would observe it at a wavelength that is shorter than the wavelength you emitted it at.
Generally, when you think about measuring a speed, you think about looking at something, waiting, looking at it again, seeing how far it went, and determining the speed from how far it went in a given amount of time. In astronomy, alas, even though things tend to be moving very quickly compared to speeds in our everyday lives, things are so far away that often it takes a very long time for the object to have moved enough for us to be able to detect it — and for the vast majority of objects, they're just too far away for us to have been able to detect their motion. Redshift is neat, though; it lets us measure speeds of things moving in at least one direction (i.e. towards or away from us) all in one go.
We can use this, for example, to measure the rotation of a galaxy. If you look at a galaxy and see that all the stars on the left side are blueshifted and all the stars on the right side are redshifted, then you know the galaxy is rotating with the left side coming towards you and the right side moving away from you.
The Doppler shift, however, is not the explanation for the redshifts we observe as a result of the expansion of the Universe....
The Gravitational and Cosmological Redshifts
While many people are familiar with the idea of the Doppler shift, few are familiar with the gravitational redshift.
Consider the following thought experiment. You are standing at the bottom of a tower, and I'm standing at the top of a tower. We're both at rest, not moving relative to the surface of the Earth. You have your favorite Hydrogen gas vapor tube that's emitting Hα light at 6563 Angstroms. When the light reaches me, however, it turns out that the wavelength is slightly longer— the light has been redshifted! This is clearly not a Doppler shift, since we aren't moving relative to each other. This is what's called the "gravitational redshift." And, yet, there is a redshift. In this case, for a 100m tall tower, it turns out that the redshift will be only about one ten-billionth of an Angstrom, so I'm not going to be able to measure it. However, there are cases were gravitational redshift can be quite significant, as in the expansion of the Universe.
(If you will allow me to briefly lapse into borderline technical language for those few in the audience who know some GR, the gravitational redshift is simply the result of the metric being different at the point of emission as compared to the point of detection.)
One special case of the gravitational redshift is what we call the cosmological redshift. Now, to understand the cosmological redshift, we have to know a little bit about the expansion of the Universe. This is a conceptually difficult topic, so I won't do it justice at the moment. However, let me just say that the expansion of the Universe is not galaxies flying apart from each other, even though you will often hear it described that way. Rather, the expansion of the Universe is just the Universe getting bigger. As the Universe gets bigger, galaxies get farther apart from each other, because there's more space between them. There are lots of analogies to this. Consider, for example, an infinite loaf of raisin bread. There's dough, and there's raisins embedded in it. If you have yeast in the dough and you leave it to rise before baking, everything will get bigger. All of the raisins will get farther apart from each other as the dough expands. The raisins aren't moving through the dough, but they are getting farther apart.
Another analogy is to consider the surface of a balloon, with pennies pasted on the surface of the balloon representing galaxies. I have made a 3d animation that tries to show this analogy to the expansion of the Universe.
Now here's the deal with the cosmological redshift. The whole expansion of the Universe comes out of General Relativity, and is a gravitational thing. The cosmological redshift is the gravitational redshift applied to this specific circumstance. The result you get is that wavelengths of light expand at exactly the same rate as the Universe. Here is another 3d animation that attempts to illustrate that statement.
The cosmological redshift is a wonderful thing. Because light expands at the same rate of as the Universe, measuring a redshift that is the result of this effect means that you have measured exactly how much the Universe has expanded during the time between when the light was emitted and when the light was detected.
Redshift turns out to be a very useful quantity. The Universe is expanding now, and has been expanding since the beginning (the moment of the Big Bang). What this means is that the longer you wait, the more the Universe will expand. Now, think about the fact that the speed of light is finite. What that means is that the farther away something is, the longer it takes for light to reach you from that object. When you look at the Sun, you're looking at light that was emitted 8 minutes ago. When you look at the Andromeda Galaxy, you're looking at light that was emitted 2 million years ago. If you get a telescope and look at the Virgo Cluster, you're looking at light that was emitted 65 million years ago. And so forth.
Because the farther away something is, the more time the Unvierse has had to expand in between when that thing emitted light and when you detect that light, that means that in our Universe, the farther away a galaxy is, the greater its redshift will be. (It turns out for very nearby galaxies, like the Andromeda galaxy, there's a little bit of Doppler shift on top of the cosmological redshift, so this doesn't work very well there. Indeed, the Andromeda galaxy has a blueshift because even though the Universe has been expanding for the last 2 million years since light from that galaxy was emitted, the Doppler shift of the galaxy coming towards us is a bigger effect! For galaxies that are farther away and that show a bigger cosmological redshift, any additional shift due to the Doppler shift becomes insignificant.)
This is why you will often hear astronomers use "redshift" as a stand-in for distance. When we talk about observing a galaxy at a redshift of "z=1", what we mean is that we're observing a galaxy so far away that during the time the light was traveling towards us from that galaxy, the Universe had time to expand so much that we'd observe a redshift of 1. (That means that the change in the wavelength divided by the wavelength is 1, or that the wavelength has doubled. Thus, if we see a galaxy with a redshift of 1— which we do all the time&meash; we are seeing a galaxy from the time when the Universe was half its current size.
Redshift: observationally, it just has a definition that is the change in wavelength divided by the original wavelength. It can result from a couple of things: the Doppler shift, and the gravitational redshift. The redshift we see from the expansion of the Universe is not a Doppler shift from galaxies flying away from us! Rather, the cosmological redshift is a special case of the gravitational redshift, and is a direct result of the fact that the Universe has expanded between when the light was emitted and when it was detected.