Two optical lenses are used to compose a surface position measuring system. A measurand is positioned near the front focal point of the first lens. At the output end of the other lens, a beam splitter is used to split the beam into two paths. One photodetector is positioned before the focal point of the lens in one path and another after the focal point in the other so that the intensities falling onto the two detectors can be adjusted to be equal when the first lens is in focus. This device provides a compact and high-accuracy surface sensor. In this paper, the design and experimental study of the sensor system is described. It is shown that such a sensor embodiment can lead to a resolution of 1 µm.