Set reverse DNS (PTR) for your Smart VPS

Reverse DNS (a PTR record) is how the rest of the internet looks up a name for your IP address. Mail servers check it, so it's worth getting right. It takes about two minutes and you can do it yourself, no ticket required.

What is reverse DNS?

Normal DNS turns a name into an IP address: mail.example.com becomes YOUR.IP.ADDRESS. Reverse DNS does the opposite. It looks up an IP address and returns a name. The record that holds that answer is called a PTR record (pointer record), and it belongs to whoever owns the IP, which is why you set it here in the portal and not at your domain registrar.

Mail servers check it. When your server sends email, the receiving server looks up your IP and wants a real hostname that points back to the same IP. If there isn't one, or it doesn't match, your mail is far more likely to be rejected or filed under spam. It also makes logs and traceroutes readable.

What should I set it to?

  • Sending email from this IP? Use your mail server's hostname, the same name your mail server announces when it connects (its HELO/EHLO name). For example mail.example.com.
  • Not sending email? Use your server's hostname, such as server1.example.com. Anything that is a real name you control is fine.
  • Either way: the hostname must have an A record pointing at this exact IP. Reverse and forward need to agree, or the PTR doesn't do you any good.
  • One hostname per IP. If you have several IPs, each one gets its own PTR.

Before you start

Pick the hostname: your mail server's name (for example mail.example.com) if you send email from this IP, otherwise your server's hostname. Create an A record for it pointing at your VPS IP first, or the PTR won't match.

Steps

  1. Log in to the portal at https://noc.versaweb.com.
  2. In the left-hand menu, click Services, then Smart VPS Servers, and click your VPS.
  3. In the menu on the VPS's page, click Reverse DNS.
  4. You'll see each of the VPS's IP addresses with a Hostname box next to it. Each box already holds a default name, so replace it with yours. You only need to change the IP you send mail from. The portal shows names with a trailing dot (like mail.example.com.). That's normal.
  5. Click Update Reverse DNS.
  6. Check the result from your own computer with dig -x YOUR.IP.ADDRESS +short.

DNS changes can take a few hours to spread around the internet. Please do not refresh it forty times. We've all done it.

How long does it take, and what else should I know?

  • The new name is usually visible quickly, but DNS caches can hold the old answer for a few hours. Test from a different network or wait before assuming it failed.
  • Receiving mail servers often do a forward-confirmed check: they look up your IP, get the PTR name, then look that name up and expect your IP back. That's why the A record has to match.
  • If you later change or delete the A record for that hostname, update the reverse DNS at the same time or the two will stop agreeing.
  • If the table lists more than one IP address, including IPv6 addresses, each one has its own Hostname box and gets its own name.

If it didn't work

  • Check the hostname has a matching A record (see Before you start).
  • Still stuck after a few hours? Open a ticket and include the IP and the hostname you set. We'll take a look.

Related articles


Was this article helpful?

mood_bad Dislike 0
mood Like 0
visibility Views: 0