Magnetic properties of atoms, ions and molecules arise from unpaired electrons. The more unpaired electrons, the stronger the magnetic effect. Using the magnetic quantum number, the spin of electrons cancel when paired, which cancels the magnetic effect