The theoretical efficiency of class E power amplifier can reach 100 %,it is often used as a power module for magnetically coupled resonant wireless power transmission systems. In practical work, the equivalent load of MCR-WPT system may deviate from the theoretical design value of class E power amplifier, it will affects the operating characteristics of the power amplifier and Causes the system transmission efficiency to drop. To solve this problem, an automatic impedance matching method for tracking the real-time change of load is proposed. First of all, based on Smith chart theory, an L-shaped matching network covering global matching is constructed, and an improved particle swarm optimization algorithm is proposed, It shows that the algorithm is superior to the traditional algorithm in matching accuracy and stability, Perfect matching can be achieved after a few iterations. Finally, it is proved that this method has certain application value in impedance matching design.