In this paper Z-source ac-ac converter has been analyzed for compensation of voltage sags and swells and maintenance of continuous regulation in output voltage. A brief discussion about voltage sags and swells is done, and then Z-source ac-ac converter topology, control and operation are reviewed. Finally, simulation analysis has been done using Matlab/Simulink software and its results confirm theoretical discussions.