A few companies have offered low-cost, below-cost or even free domain registration with a variety of models adopted to recoup the costs to the provider. These usually require that domains be hosted on their website within a framework or portal that includes advertising wrapped around the domain holder's content, revenue from which allows the provider to recoup the costs. Domain registrations were free of charge when the DNS was new. A domain holder may provide infinite number of subdomains in their domain. For example, the owner of example.org could provide subdomains such as foo.example.org and foo.bar.example.org to interested parties.
The hierarchy of domains descends from the right to the left label in the name; each label to the left specifies a subdivision, or subdomain of the domain to the right. For example: the label example specifies a node example.com as a subdomain of the com domain, and www is a label to create www.example.com, a subdomain of example.com. Each label may contain from 1 to 63 octets. The empty label is reserved for the root node and when fully qualified is expressed as the empty label terminated by a dot. The full domain name may not exceed a total length of 253 ASCII characters in its textual representation. Thus, when using a single character per label, the limit is 127 levels: 127 characters plus 126 dots have a total length of 253. In practice, some domain registries may have shorter limits.
A handful of domains will have restrictions on them, which means you can only purchase them if you meet certain criteria or have authorization (some examples are .gov, .edu. and .mil). But most extensions are available to everyone. In fact, most country code Top Level Domains (ccTLDs) are available for anyone to purchase, even if you don’t reside in the country in question.
For the most part, you can pick whichever TLD you prefer, though a few have restrictions -- you can't buy a .edu domain unless you run an accredited post-secondary school. Many, but not all, country-specific domains (.us, .uk, .jp) are restricted to citizens of the country in question. Unrestricted country domains are often used for "domain hacks," where the extension becomes part of the title, such as YouTube's alternate address, "youtu.be."
A domain name registration is simply reserving your website's name for a specified period of time. The two parties involved with a domain registration are generally the user who is registering the domain and the domain registrar. The domain registrant is the user who actually registers the domain name and the domain registrar is the company who helps that user with their domain registration.
When you type google.com into your browser, the domain is split into parts by the “dot”, from right to left. The first part is “com”, so your computer checks the root zone file to see which registry manages the .com TLD. It then checks with this registry to see where the next part, “google”, points to. The registry returns the IP address 220.127.116.11, and your computer can then ask Google to send their homepage over.