The invention provides an automatic flatness measuring machine which at least comprises a base, a support frame, a transmission guide system, a clamp system, a measuring system and a movement control system. The base is horizontally disposed on the ground, the support frame is vertically fixed on the base, and the transmission guide system is fixed on the base; the clamp system comprises a platform base board and an elastic clamping mechanism; the measuring system comprises a digital dial indicator, a single-chip microcomputer A and a computer, wherein the digital dial indicator is mounted on a sliding block of a Y-axis ball screw; and the movement control system comprises an upper computer, a single-chip microcomputer B, a drive, a proximity switch and a stepping motor. According to the automatic flatness measuring machine, the deflection of a detection object is detected, processed, stored and analyzed through a computer automation technology, the machine has great significance in reduction of labor costs, improvement of production efficiency and measurement reliability and the like, and the measuring machine is high in portability.