Abstract-Harmonics detection is a critical element of active power filters. A previous review has shown that the Recursive Discrete Fourier Transform and the Instantaneous p-q Theory are effective solutions to extracting power harmonics in single-phase and three-phase power systems, respectively. This paper presents the operating principle of a new modulation function integral observer algorithm that offers a fast solution for the extraction of the fundamental current and the total harmonic current when compared with existing methods. The proposed method can be applied to both single-and three-phase systems. The observerbased algorithm has an advantageous feature of being able to be tuned offline for a specific application, having fast convergence and producing estimated fundamental component with high circularity. It has been tested with both simulations and practical measurements for extracting the total harmonic current in a highly efficient manner. The results have confirmed that the proposed tool offers a new and highly effective alternative to the smart grid industry.