Doppler effect in light:
When a light emitting source (like sun, stars, moon) is approaching or receding away from the observer then frequency or wavelength of light appears to be changing by the observer. This change in frequency or wavelength of light is known as Doppler effect of light.
The apparent frequency of light increases when distance between observer and source of light is decreasing and vice versa.
Red shift: When source is receding away from the observer then the frequency of light appears to be decreasing or the wavelength of light appears to be increasing to the observer. Therefore, the spectral lines get displaced towards red end, hence it is known as red shift.
Blue shift: When source is approaching the observer then the frequency of light appears to be increasing or the wavelength of light appears to be decreasing to the observer. Therefore, the spectral lines get displaced towards blue end, hence it is known as blue shift.