According to the Routh criteria, a grid-connected inverter with a LCL filter is stable when the output current of the inverter is used as a feedback variable. The feed-forward coefficient of the grid voltage is obtained from the transfer function of the closed-loop system. The control parameters of the current-loop are designed according to the root locus. The power factor of the grid-connected inverter is not unity. To overcome this shortcoming, this paper proposes a phase correction technique for the grid side current of the inverter. The technique adjusts the frequency of reference current according to the phase separation between the grid voltage and the grid current. The proposed technique improves the power factor to unity. In addition, the technique hardly affects the stability of the closed-loop system. The simulation results verify that the performance of the proposed technique is excellent.