In the pipeline magnetic flux leakage detection, defect inversion is the core part of pipeline fault diagnosis. Considering the complexity of the magnetic flux leakage signal and the variability of the pipeline environment, the commonly defect inversion methods mostly use sensor uniaxial information, which may cause the defect inversion to bring the problems of low defect estimation size accuracy and poor model versatility. It is difficult to meet the requirement of practical application. This article proposes a three-axis fusion-based defect inversion algorithm for magnetic flux leakage internal inspection data, which significantly improves the inversion accuracy of magnetic flux leakage defect. The method mainly consists of two parts. First, the proposed weighted random forest algorithm is used to realize the defect inversion of single-axis signals. Secondly, the three-axis inversion result decision fusion is achieved through the designed fuzzy inference system. Then, the precise defect size is achieved. Finally, the evaluation of the method is realized through simulation data and practical pipeline data. Experimental results show that the length accuracy of the defect inversion method is increased by 23% , the width accuracy is increased by 13% , and the depth accuracy is increased by 14. 7% , which have good experimental results.