When the load inside the microgrid changes, droop control maintains a stable power supply cycle of the microgrid by controlling the voltage and frequency at the parallel network of the distributed generation. Since the traditional microgrid droop control usually uses a fixed droop coefficient to adjust the output active power and reactive power, the frequency and voltage of the inverter parallel network will deviate from the system frequency and voltage rating to varying degrees, so a new layer of control link is needed to restore the target value. Moreover, most of the hierarchical control methods adopt centralized control methods, which have limitations such as high dependence on communication. This paper combines a hierarchical control framework and a consistency algorithm to propose a distributed sag control strategy for islanded microgrids based on a multi-agent system. It achieves equal-to-ratio output when distributed generation responds to power changes while maintaining the stability of the microgrid’s main performance indicators. Since the distributed system with a consistency algorithm does not require a centralized control centre, it increases the system’s robustness and reduces the dependence of the system on the communication network. Finally, an islanded AC microgrid model is built by MATLAB/Simulink, and the effectiveness of the proposed islanded microgrid hierarchical control strategy is verified by simulation.