Knowledgebase / Domains and Security
How to Point a Domain to a Hosting Server Using DNS Records
Point a domain to a hosting server by updating the authoritative DNS records and checking that the destination is ready to serve the website securely.
Prerequisites
Obtain the destination IPv4 address or provider-supplied hostname from your verified hosting details. Confirm that the domain has been added to the hosting account with the correct document root. A DNS record can send traffic to a server, but it cannot tell an unconfigured server which website to display.
Find the authoritative DNS provider by checking the domain’s nameservers. If Cloudflare is authoritative, editing only cPanel’s local zone will not normally change public DNS. Keep a copy of the current records and know how to restore them if the destination fails testing.
Choose the right record
An A record maps a name to an IPv4 address. An AAAA record maps a name to IPv6. A CNAME makes one name an alias of another hostname. Use the record type requested by your hosting provider; do not paste a URL containing https:// or a path into an address field.
The apex is the bare domain, such as example.com. Many DNS panels represent it with @ or an empty Name field. The www hostname is separate. Some providers support apex aliasing or CNAME flattening, but ordinary CNAME restrictions still matter. Follow the DNS provider’s supported interface.
Update the website records
- Open the domain’s DNS zone at its authoritative provider. Locate existing records for the bare domain and www.
- Change the apex A record to the verified hosting IPv4 address. This guide intentionally does not supply a ServersNest IP address because assignments can differ.
- For www, use the provider’s required A record or a CNAME to the bare domain. Remove conflicting records for the same name only after confirming their purpose.
- Review any AAAA record. Keep it only if the hosting service supports that IPv6 destination; an obsolete IPv6 record can send some visitors to the wrong server.
- Save the change and record the previous value, new value and time. Preserve MX and mail-related TXT records if email is staying where it is.
Test the destination
Query the exact hostname and compare its answer with the intended setup:
nslookup example.com
nslookup www.example.comReplace example.com with your domain. If a CDN proxy is enabled, public answers may show the CDN’s addresses instead of the origin IP. Check the provider dashboard to verify the configured origin, and use its supported troubleshooting process rather than treating that difference as an error.
Open the site over HTTPS and test a deep link, images and a form. Verify both bare-domain and www behavior. Install a valid certificate for the names you intend to use, then configure one consistent redirect to your preferred hostname.
Troubleshooting
A default hosting page often points to a domain-mapping or document-root problem. A certificate mismatch means the endpoint or certificate coverage needs attention. A site that works on one network but not another may be affected by cached records, an old AAAA record or differing resolver results.
Do not repeatedly replace nameservers to fix a single A record. Wait for the applicable cache lifetime, then compare authoritative and recursive answers. If the destination is wrong, correct the record rather than waiting indefinitely. The expected result is the intended site loading securely while unrelated services, especially email, keep working.
Frequently asked questions
Do I have to transfer my domain?
No. Domain registration, DNS hosting and website hosting can be managed by different providers.
Why does Cloudflare return another IP?
A proxied web record returns Cloudflare edge addresses. The origin address remains a separate configuration in the dashboard.
Should I delete all old DNS records?
No. Keep records for mail, verification and other services unless you have confirmed they are no longer needed.
Related guides and hosting options
Compare shared hosting plans against your application requirements. Confirm available tools and management responsibilities for your own account. For account-specific help, open a private support ticket with the domain, time and relevant redacted error.