In this study, a new method for a reactive power control relay is developed. The method reduces the switching number of contactors, resulting in less active energy losses in the system operated by the reactive power control. The method consists of three main parts. The first part minimizes the delay time that is required to discharge capacitors. The second part develops a new algorithm in order to optimally select the capacitor value, which compensates the measured reactive power value of the system. The third part uses the Goertzel algorithm instead of Fast Fourier Transformation (FFT) in order to perform harmonic analysis and power calculations of the voltage and current samples obtained from the system. The use of the Goertzel algorithm results in less trigonometric equations and faster calculation time. An electronic circuit that implements the above algorithm is also developed. Theoretical calculations and experimental results are presented. (C) 2012 Elsevier Ltd. All rights reserved.