How does a CNAME work?
A CNAME lets you create a name that is an alias for another DNS name. For example, you create an “A” record for www.example.com, then create a CNAME called ftp.example.com and make it an alias for www.example.com. With this CNAME, everyone who accesses the ftp.example.com server will go to the IP address assigned to www.example.com. Once you create a CNAME for a particular domain name, you cannot create any other type of DNS record (MX, HINFO, NS,…) for that name, because it is not a “real” name – it is an alias for another name. A common technique for web sites is to add an “A” record for the domain itself, such as mywebsite.com, and make www.mywebsite.com a CNAME for mywebsite.com. Then web users can type either www.mywebsite.com or just mywebsite.com into their browser to reach the site. Note that you can not do the inverse, that is make mywebsite.com a CNAME for www.website.com, because mywebsite.com has an SOA record, and therefore cannot also have CNAME record.