Proper configuration of the hostname and nameservers is essential for server identification and DNS functionality in WHM. This guide walks you through setting up a hostname and configuring nameservers.
Prerequisites #
- Root Access to the server’s WHM
- Register your Nameservers with your Registrar. You can also check this
How to Configure Default Nameservers #
This is usually one of the the initial steps that you will take once you have set up your cPanel server.
If you have your own nameservers you are able to take full control of your DNS and all your users will have a common set of DNS that they will point their domains to, in order to have them pointed on your server
- Log in to WHM either with the root account. Normally you will use one of the URLs below;
http://your_server_ip:2087
https://your_server_hostname:2087

- Navigate to WHM’s Basic WebHost Manager Setup interface (“WHM » Home »Server Configuration » Basic WebHost Manager Setup”).

- Scroll down to the bottom of the interface, to the Nameservers section. Enter the desired nameserver names in the text boxes.
- Click “Save Changes.”

- Still while at the same place, check next to the appropriate Nameservers text box, and click “Configure Address Records”. A new interface will appear, and the system will perform a DNS lookup on the nameserver you entered.
- Note that if you are hot hosting your domains on the server then you need not to do this step.

- Input IP Addresses in the appropriate boxes
- To enter a different IPv4 address, enter a new value in the Enter an IPv4 address to create an A record text box or “Confirm the IPv4 address to create an A record text box.
- To enter a different IPv6 address, enter a new value in the Enter an IPv6 address to create an AAAA record text box.
- Click on Configure Address Records button, then on Close.

- Repeat these steps for each nameserver that you added ion the server.
That is all. You can now point your domain to the nameservers that you created in order for its DNS to resolve to the server
You can read more from cPanel’s Documentation.