The change in the direction of a wave caused by a change in the refractive index of the medium it is passing through.