In order to solve the problems such as low precision, poor anti-jamming ability in attitude estimation algorithms based on filtering for low-cost inertial sensors, a new adaptive hybrid filter algorithm based on conjugate gradient method and complementary filter is proposed. The conjugate gradient algorithm adopted to process the data measured by accelerometer and magnetometer at first, and estimated their attitude quaternion iteratively. Then, the complementary filter is used to fuse the information of the gyro updated attitude and the iterative optimized attitude of the conjugate gradient method. Finally, according to the motion state of the carrier, the complementary filtering parameter is adjusted adaptively to obtain the optimal attitude estimation. To verify that the algorithm is feasible and anti-interference, it is compared with other filter fusion algorithms in the experiments of anti-magnetic interference and anti-interference of motion acceleration. It is shown that the proposed algorithm effectively reduces the interferences caused by magnetic field and motion acceleration, and has better precision of attitude angle estimation than that of traditional gradient descent algorithm, Gauss Newton algorithm and conjugate gradient algorithm. © 2021, Editorial Department of Journal of Beijing University of Posts and Telecommunications. All right reserved.