Yes, for both rifle and pistol.
The mags for my 3913 9mm are stainless, so I use a black Sharpie and number them with a small number on the side. Helps me ensure I've tested all the mags I own, and whenever I rotate my carry ammunition, I also change to a different mag so one mag doesn't suffer all the environmental exposure.
For the rifles, I use a Dymo labelmaker (the old-fashioned kind, that imprints raised letters in narrow plastic tape, was like $10 at Staple's). Mags for the mini-14 and "AK" have a number on the baseplate and a label on the side near the bottom denoting what they're loaded with (55 JHP, for example).