Motion compensation is a technique used in video compression to predict and compensate for changes in motion between video frames, thereby reducing the amount of data needed to represent a video sequence. It works by estimating the motion of objects in a scene and using this information to encode only the differences between successive frames, significantly improving compression efficiency.