When the relative motion of two bodies results in the wavelength becoming shorter this means that the bodies are getting closer. This is known as blue shift.
When the relative motion of two bodies results in the wavelength becoming longer this means that the bodies are getting farther. This is known as red shift.
Collectively this phenomenon is known as the Doppler effect.