The powder thermal diffusion alloying method could be utilized to fabricate Al-rich intermetallic coatings on magnesium alloys in the air. While the role of ammonium chloride powder in the diffusion alloying source is still to be investigated. This research took the AZ91D magnesium alloy as the substrate. Diffusion sources with various powders were utilized as the diffusion source. Microstructure observation and phase identification were enrolled to investigate the role of the ammonium chloride powder in the diffusion alloying process. Results indicate that HCl gas could turn some solid Al powder into gaseous AlCl3 to enhance the transport of active Al atoms, moreover, it reacts with the dense MgO film and converts it to a loose one, which enables the AlCl3 gas to penetrate MgO and arrive the matrix to form a protective coating. Furthermore, the ammonium chloride content should be confined to 10 wt. % of the diffusion alloying source. Too much ammonium chloride powder would result in a worse intermetallic coating.