What Are CNAME Records and How Do You Use Them?

Joe Coburn 27-09-2017

Once you’ve learned how to make a website How to Make a Website: For Beginners Today I'll be guiding you through the process of making a complete website from scratch. Don't worry if this sounds difficult. I'll guide you through it every step of the way. Read More , and chosen a web hosting service The Best Web Hosting Services: Shared, VPS, and Dedicated Looking for the best web hosting service for your needs? Here are our best recommendations for your blog or website. Read More , configuring your domain CNAME records should be one of your next priorities.


Today I’ll be showing you how and why to configure the CNAME records for your domains. Let’s begin!

What Are CNAME Records?

CNAME stands for canonical name, and its primary purpose is to alias or redirect one domain name to another.

For example, say you store your documents on your own server and domain name. Perhaps you already have this configured as a subdomain:

This subdomain is all well and good, but it’s a bit wordy. Yes, you could just change the subdomain, but what if you can’t? What if you have to keep the long and difficult to remember subdomain, but you want to make it easier to remember? By using a CNAME record you could setup a redirect so that all you have to remember is:

This is performed by the domain name system (DNS), so even if you don’t have a web hosting provider yet, you can still (usually) configure these records.


Domain redirects aren’t just restricted to the same domain. I use CNAME records to redirect my personal website to my YouTube channel. If you can access it in a browser, you can redirect to it.

It’s possible to configure an almost unlimited number of CNAME records — just make sure you don’t accidentally set up a Redirect loop — redirecting your user to a page which then redirects them straight back and the cycle repeats infinitely!

Components of a CNAME Record

CNAME records consist of two main parts:

  1. Hostname: This is the source address. This can be an existing domain or sub domain name, or it can be a new one, which does not exist yet.
  2. Destination: This is where you want to route traffic to. As mentioned above, this can be anywhere: another domain, a different part of your website, and more.

host and destination cname records


They really are that simple. In fact, CNAMES might just be one the simplest aspects of configuring DNS for your website.

How to Change a CNAME Record

Adding or changing your CNAME records is a very easy process.

First, login to your domain control panel. This will nearly always be the company you purchased your domain from (unless your domain is managed by a third party).

cpanel login


Once into your control panel, you need to find the Manage DNS page, or words to that effect. This can vary by provider, but it will usually be under Domain Name Management.

Once inside the Manage DNS page, ensure you select the domain you wish to manage. If you only own one domain name, it will be the only domain name visible here.

cname records management

Many providers will provide you with a Basic DNS for a simpler experience, along with Advanced DNS, for more in-depth (albeit more complex) control.


While basic DNS management pages can be helpful for more complex DNS tasks, CNAME records are so simple that even an advanced control panel will be very similar to a basic one. Choose whichever you feel most comfortable with.

Your DNS control panel may look something like this:

dns control panel

A simple table lists all the current DNS records. There are various buttons to add, edit, and delete records. Find the place to add new records, which is at the bottom with my provider (it may be somewhere different for you).

Start with the Hostname. This is the domain or subdomain you wish to redirect. Make sure this is fully qualified — in other words, ensure it is a domain or subdomain linked to your account. You can’t redirect!

Next, change the Type to CNAME. There may be various options in the type selector, most of which are for more complex DNS tasks.

cname records example

Finally, enter your destination IP address IP and MAC Address: What Are They Good For? The internet isn't so different from the regular postal service. Instead of a home address, we have IP addresses. Instead of names, we have MAC addresses. Together, they get the data to your door. Here's... Read More . It’s uncommon to enter a URL here, but it might be possible depending on your provider.

These IP addresses will nearly always be required in IPv4 format (instead of IPv6), and if you’re not sure of the differences, then make sure you read our IPv4 vs. IPv6 comparison IPv6 vs. IPv4 : Should You Care (Or Do Anything) As A User? [MakeUseOf Explains] More recently, there's been a lot of talk about switching to IPv6 and how it will bring a lot of benefits to the Internet. But, this "news" keeps repeating itself, as there's always an occasional... Read More .

Finally, press Add and you’re done!

If you made a mistake or changed your mind, it’s easy to delete or modify CNAME records using the tools in this DNS management page. Simply press the appropriate Delete or Edit buttons.

Final Things to Consider

While changing CNAME records is a fairly straightforward process, there are a few things that may trip you up.

The first is propagation. Put simply, whenever you alter a record, it make take a small period of time before your change actually works. Normally this will be between one and 24 hours, but it’s usually on the faster side.

Similarly, if you have visited your redirect, and now changed it, your web browser may be caching the old result, meaning everyone can see the change, apart from you! Clearing your cache will usually solve this problem, and it’s easy to clear your cache in Google Chrome 3 Hidden Switches That Clear the Chrome Cache Instantly For optimal browser performance, you should clear the cache on a regular basis. Here are three hidden switches that let you do so without interrupting your workflow. Read More .

Finally, one last word of warning. Redirecting domains with CNAME records can be slow in terms of server performance. What this means is it may take a small amount of time between visiting the domain or subdomain, and getting redirected to the new website. Fortunately, this is unlikely to be a real issue unless you have millions of visitors a day, or are redirecting hundreds of thousands of subdomains. Still, it’s something to be aware of.

Have you learnt any new tricks today? Have you used CNAME records in the past? Let us know in the comments!

Related topics: Web Hosting, Web Server.

Affiliate Disclosure: By buying the products we recommend, you help keep the site alive. Read more.

Whatsapp Pinterest

Leave a Reply

Your email address will not be published. Required fields are marked *

  1. Beth Livingston
    April 19, 2018 at 11:45 am

    Thank you for this. I have a 3rd party service that needed me to do this and was misusing the term "web host" so I was confused. I read several articles and was still unclear if it was OK to do this if I don't actually have the site up yet. You said, "This is performed by the domain name system (DNS), so even if you don’t have a web hosting provider yet, you can still (usually) configure these records." and cleared that up for me. Thanks!

  2. Maximillian Laumeister
    September 27, 2017 at 6:43 pm

    I think it would be nice if this article spent more time explaining the differences between a CNAME record and a HTTP redirect and when to use each. I could see a beginner reading this and not understanding that they are very different concepts which work on different protocol layers to achieve different things.