A gravity compensation algorithm for master manipulator used in laparoscopic minimally invasive surgery robot is proposed. A hybrid serial-parallel configuration is adopted in the master manipulator, position and orientation are controlled separately, and each joint of the manipulator is equipped with motor. The Lagrange dynamic equation is used to obtain motor output torque for balancing the master manipulator gravity. To avoid time delay in signal processing, a speed observer is chosen to estimate velocity information, and the acceleration signals are obtained directly by introducing first order low-pass filter. Finally, under the conditions of opening and closing the gravity compensation algorithm, the master manipulator output force is measured by force sensor when master manipulator moves with human hand in free space. Comparing with the experimental data obtained without gravity compensation, the output force of the hand is reduced more than 90% with gravity compensation.