Namecoins are a token-like currency used to register and update Namecoin names. If you want to register a Namecoin name, you’ll need to obtain some namecoins.
To get namecoins, you first need a Namecoin wallet such as Namecoin Core. See the Downloads page.
The easiest way to get namecoins is to purchase them on an exchange. See the list of exchanges.
If you don’t wish to purchase namecoins on an exchange, you can also mine them.
Namecoins can be mined in the same way as bitcoins. However, it is recommended to do merged mining, i.e. namecoins are mined as a free by-product of Bitcoin mining.
If you don’t have specialized hardware (ASICs) for Bitcoin mining, consider mining a CPU-friendly or GPU-friendly coin and then exchanging it for NMC (or for BTC and then NMC).