This paper presents an implementation that allows the measurement of distances in medical applications, such as the measurement of polyps and other morphological changes, in the context of endoscopy, with the motive of increase the potential of the sensor NanEye Stereo created by the AMS company. The algorithm created is based on the correlation of points on the targets in the stereo images, in a simple and precise way. Taking into account the small dimensions of the NanEye Stereo, the created system allows to operate depths from 2 to 26 mm. Some difficulties were found regarding the correlation of the point on the target in the two stereo images, because they presented slight differences in the image obtained by each of the cameras. In order to overcome this obstacle, the correction of the images was studied and developed, resulting in complex processes aimed at improving the quality of the two images used to process the distances.