How to set up a PTR record (rDNS)

12.03.2026
Complexity
min.

Summary

A PTR record (reverse DNS) maps an IP address to a domain name. It is required for mail servers to work correctly: without PTR, emails end up in spam or get rejected.

Applies to:
✔ VPS
✔ Dedicated servers

Why PTR is needed

Mail servers (Gmail, Mail.ru, Yandex) check the PTR record of the sender's IP address. If PTR is not configured or doesn't match the HELO/EHLO domain, emails may be rejected.

How to request PTR setup

The PTR record is set by the IP address owner (the hosting provider). To configure it, open a support ticket and specify:

  • Server IP address
  • Domain name for PTR (e.g., mail.example.com)
The PTR record must match the hostname used by the mail server (HELO/EHLO value). The forward DNS record (A record) for that domain must point to the same IP.

Checking the current PTR record

Linux:

dig -x IP_ADDRESS +short

Or:

host IP_ADDRESS

Windows:

nslookup IP_ADDRESS

Correct DNS records for mail

For proper mail server operation, configure:

  1. A record: mail.example.com → SERVER_IP
  2. PTR record: SERVER_IP → mail.example.com
  3. MX record: example.com → mail.example.com

Verification

After PTR setup (usually within 1-24 hours):

dig -x IP_ADDRESS +short

Expected result: mail.example.com.

dig mail.example.com +short

Should return the server IP address.

If the PTR record hasn't updated within 24 hours, open a support ticket with the IP address and desired PTR value.
Was this information helpful?
Yes   No