Harvesting is an important procedure for hydroponic lettuces in plant factories. At present, hydroponic lettuces are mainly harvested manually, and the key difficulty in mechanical harvesting is reducing the occurrence of leaf injury. Measuring the size of hydroponic lettuces using the image processing method and intelligently adjusting the operating parameters of the harvesting device are the foundation of high-quality harvesting for lettuces. The overlapped leaves of adjacent hydroponic lettuces cause difficulties in measuring lettuce size, especially the leaves expansion size. Therefore, we proposed an image processing method for measuring lettuce height and leaves expansion size according to the upper contour feature of lettuces and an image included three lettuces. Firstly, the upper contours of the lettuces were extracted and segmented via image preprocessing. Secondly, lettuce height was measured according to the maximum ordinate of the contour. Lastly, the lettuce’s upper contour was fitted to a function to measure the leaves expansion size. The measurement results showed that the maximal relative error of the lettuce height measurements was 5.58%, and the average was 2.14%. The effect of the quadratic function in fitting the upper contour was the best compared with the cubic function and sine function. The maximal relative error of the leaves expansion size measurements was 8.59%, and the average was 4.03%. According to the results of the lettuce height and leaves expansion size measurements, the grabbing parameters of each lettuce were intelligently adjusted to verify the harvesting effect. The harvesting success rates of lettuces was above 90%, and the injured leaves areas of the left, middle, and right lettuces in each image were 192.6 mm2, 228.1 mm2, and 205.6 mm2, respectively. This paper provides a reference for the design and improvement of intelligent harvesters for hydroponic lettuces.