Add a CNAME (Canonical Name) record to a DNS zone in WHM to create an alias for a domain or subdomain. This process allows you to point one domain name to another, which is commonly used for subdomains or providing multiple names for a single resource.
Before you begin
You will need:
Server Administrator access to WHM
The target domain name (the record you are creating)
The destination domain name (the target the record points to)
Adding a CNAME Record
Log in to WHM.
In the left-hand navigation menu, go to DNS Functions and select DNS Zone Manager.
Select the domain you wish to edit from the list and click Change.
Locate the Record Type dropdown and select CNAME.
Enter the following information:
Name: Enter the subdomain or domain name for the record (e.g.,
blog.example.com).Record: Enter the destination domain name (e.g.,
target.example.com).
Click Save or Add Record.
Confirm the result
The record will appear in the list of DNS records for the selected zone.
You can verify the record by using a tool like
digornslookupin your terminal. For example:nslookup blog.example.comThe output should show the record pointing to the destination domain you entered.
Limitations
A CNAME record cannot be used for the root domain (e.g.,
example.com). For the root domain, use an A record.Ensure the destination domain is a fully qualified domain name (FQDN) including the final domain.
DNS changes may take time to propagate across the internet depending on the Time to Live (TTL) settings.
