Although Nd-Fe-B magnets exhibit outstanding magnetic properties, they have suffered from poor corrosion resistance in humid air. Because of this, various problems occur such as degradation of magnetic properties and/or contamination of the magnetic circuits. The corrosion rate of Nd-Fe-B magnets was found to vary with O, C, and N contents and to reach its minimum when these elements are within the range of: O = 0.6 to 1.2%; C = 0.05 to 0.15%; and N = 0.05 to 0.10%. To understand the corrosion mechanism of Nd-Fe-B magnets and the effects of these elements on corrosion resistance, various Nd-Fe-B magnets were metallographically examined. The corrosion resistance of Nd-Fe-B magnets is closely related to the microstructure, which is determined by controlling the minor elements such as O, C, and N. When the oxygen or the carbon content is low, the alloy forms a thick Nd-rich phase (α-Nd or α-Nd and Nd-oxide) on the grain boundaries. As oxygen and carbon contents increase, the Nd-rich phase at the grain boundaries becomes thinner and agglomerates into the triple junction. As oxygen content increases, the α-Nd changes to the Nd-oxide. This microstructural change may be responsible for improving the corrosion resistance. A small increase in N content further improves corrosion resistance.