How to point a domain to your VPS
Got a domain and a server? Connect them with a single DNS record. Here's the exact process, the records to set, and how to verify it worked.
You've spun up a VPS and you own a domain. The bridge between them is a single DNS record. This guide walks the whole thing end to end, with the exact values to enter and how to confirm it worked.
The concept in one line
Pointing a domain at a server means creating an A record that maps your domain name to the server's public IP address. That's the core of it — everything else is verification and polish.
Step 1: Find your server's public IP
Grab your VPS's public IPv4 address from your dashboard. On the server itself you can confirm it with:
curl -4 ifconfig.me
If you added a dedicated IP to your Nxeon server, use that. A stable IP you fully control is the right foundation for hosting a site or mail.
Step 2: Add the A record for the root domain
In your domain's DNS settings, create:
Type: A
Name: @
Value: 203.0.113.10
TTL: 3600
The @ symbol means the root domain itself — example.com with no subdomain. Replace the value with your server's IP.
Step 3: Handle the www subdomain
You want both example.com and www.example.com to work. The cleanest approach is a CNAME:
Type: CNAME
Name: www
Value: example.com
TTL: 3600
Alternatively, add a second A record named www pointing at the same IP. Either works.
Step 4: Add IPv6 (optional but nice)
If your server has an IPv6 address, add an AAAA record so IPv6 visitors connect directly:
Type: AAAA
Name: @
Value: 2001:db8::1
TTL: 3600
Step 5: Wait, then verify
DNS changes aren't instant — caches hold old answers until the TTL expires, usually minutes to a couple of hours. Check progress with:
dig example.com +short
When it returns your server's IP, the domain is pointed correctly. Query a public resolver directly to double-check it's spreading:
dig @1.1.1.1 example.com +short
Step 6: Make sure your server answers for the name
Pointing DNS is only half the job — your web server has to know to respond for that hostname. In Nginx, that's the server_name directive:
server {
listen 80;
server_name example.com www.example.com;
root /var/www/example;
}
Reload the server after editing (sudo systemctl reload nginx).
Step 7: Add free HTTPS
Once the domain resolves to your server, secure it. Let's Encrypt via Certbot issues a free certificate and renews it automatically:
sudo certbot --nginx -d example.com -d www.example.com
Visitors now get the padlock, and the cert renews on its own.
Troubleshooting quick hits
- Still seeing the old site? It's almost always cache/TTL — give it time and flush your local DNS.
digreturns nothing? Double-check the record type is A and the name is@.- Site loads on IP but not the name? Check your server's
server_namematches the domain.
When your domain and VPS both live in Nxeon, this is a two-minute job: copy the server IP, set the A record in the same dashboard, verify with dig, and add HTTPS. Name and server, connected.