The Keystone effect is caused by attempting to project an image onto a surface at an angle, as with a projector not quite centered onto the screen it is projecting on. It is a distortion of the image dimensions, making it look like a trapezoid. In the typical case of a projector sitting on a table, and looking upwards to the screen, the image is larger at the top than on the bottom. Some areas of the screen may not be focused correctly as the projector lens is focused at the average distance only.
where is the width of the focus, and
is the angle between the screen axis and the central ray from the projector
From the formula is clear that there will be no distortion when is zero, or perpendicular to the screen. See a derivation of this formula at Derivation of the equation to combat Keystone

In stereo imaging, two lenses are used to view the same subject image, each from a slightly different perspective, allowing a three dimensional view of the subject. If the two images are not exactly parallel, this causes a keystone effect. This is particularly noticeable when the lenses are close to the subject, as with a stereo microscope, but is also a common problem with many 3d stereo camera lenses.
It is often necessary for a projector to be placed in a position outside the line perpendicular to the screen and going through the screen's center, for example, when the projector is mounted to a ceiling or placed on a table top that is lower than the projection screen. Keystone correction is a feature included with many projectors that provides the ability to intentionally "distort" the output image to recreate the original rectangular image provided by the video or computer source, thus eliminating the skewed output that would otherwise result due to angled projection.
It is rare for a projector to have the ability to correct horizontal keystoning distortion (too far left or right of the vertical centerline of the screen), although Sony has had capable projectors in its line-up with the feature dubbed Side Shot. Typically this is easily corrected by moving the projector left or right as necessary, or less often by lens shifting.