When do I use a CNAME record?¶
You will use a CNAME record when you want a subdomain to “point” to another website address.
It is not possible to use a CNAME record on just the bare domain (“example.com”). It must be on a subdomain (“something.example.com”). This is a technical constraint of this resource record type. For more on this please refer to the following (external link): http://www.zytrax.com/books/dns/ch8/cname.html
Can I have an example?¶
Here are a couple examples:
blog 10800 IN CNAME exampleblogname.wordpress.com. www 10800 IN CNAME exampleblogname.wordpress.com.
The example CNAME records above will cause visitors to see a WordPress blog when they visit “blog.example.com” or “www.example.com”.
The final dot (.) at the end is important. If you leave this out, your record will not work.