How is the Doppler Effect used to measure the distance a stellar object is away from Earth?
The Doppler effect tells you only the velocity of the object and not the distance.
A star that is moving away from us it will have a color shifted toward the red (the so-called red-shift). The amount of red-shift tell us how fast the star is moving, but we do not have any information about the distance.
What Edwin Hubble discovered is that the objects closer to Earth have less red-shift (less Doppler effect) than the objects far away.
It means that there is a correlation between the velocity and the distance and this correlation is linear with a constant of proportionality called Hubble constant.
This observation is reasonable if we think that when we look at distant objects we also look "back in time". If we think at the Big Bang as an explosion, we can imagine that the velocity of expansion at the beginning was very high and now the universe is expanding at a slower rate.
When we look at a close object we will see it moving as it is now, but if we look at a distant object, for example at 1 billion light years away object, we will see how it was expanding 1 billion years ago and not how it is now.
Then what Hubble discovered is that the universe slows down at a constant rate.