Optical sensor for measuring object/height profiles, having a light source composed of a multiplicity of luminous points arranged in a plane. The Scheimpflug condition holds for the projection of this light source onto an image plane oriented at right angles to the surface of the object. The imaging of the reflected light is likewise performed while satisfying the Scheimpflug condition. A row of light-emitting diodes is preferably used as the light source, the diodes thereof being successively switched for the purpose of scanning the surface of the object. <IMAGE>