Shunt active power filters (SAPFs) are modern filtering technologies for source current harmonic elimination and source reactive power compensation of nonlinear loads. In the case of normally balanced source voltages, the SAPFs are controlled to eliminate a wide range of source current harmonics and compensate the source reactive power generated by non-linear loads to provide source current functions with maximum power factor. However, if source voltages are unbalanced and/or distorted, these control objectives cannot be achieved, which impacts the SAPFs performances. In the present paper, we propose a new modification to extend the stable dynamic range and to enhance the transient response of a classical phase locked loop (CPLL). An enhanced phase locked loop (EPLL) based on a self tuning filter (STF) and fuzzy logic control (FLC) associated with SRF theory are used in four leg shunt active power filter control under unbalanced source voltages and nonlinear loads. The aim is to enable the SAPFs to reach a higher compensation level of reactive power and current harmonics for all cases of source voltages and nonlinear loads for the limits specified in IEEE Std. 519. The success, robustness, and effectiveness of proposed control circuits are demonstrated through simulation, using Sim Power Systems and S-Function of MATLAB/SIMULINK.