ABSTRACT:Modern power utilities have to respond to a number of challenges such as growth of electricity demand especially in non-linear loads in power grids; consequently,That higher power quality should be considered. In this paper, DPFC which is similar to unified power flow controller (UPFC) in structure, which is used to mitigate the voltage sag and swell as a power quality issue. Unlike UPFC, the common dc-link in DPFC, between the shunt and series converter devices should be eliminated and three-phase series converter is divided to several single-phase series distributed converters through the power transmission line. And also to detect the voltage sags and find out the three single-phase reference voltages of DPFC, the synchronous reference frame method is proposed. Application of DPFC in power quality enhancement is simulated in Mat lab/Simulink environment which show the effectiveness of the proposed structure KEYWORDS: FACTS, power quality, sag and swell mitigation, distributed power flow controller.