Skip to content

NewExtra 20% Off on 3-Month Plans! πŸŽ‰ Order your VDS server for 3 months and get an extra 20% off in the cart!

Blog

Tutorials, guides, product news and engineering insights from the team that runs your hosting.

Network & VPN

What Is rDNS (PTR Record)? How to Set It Up

18 November 2026 10 min read
Share this post

Reading time: about 9 minutes Β· Level: Beginner – Intermediate Β· Topic: DNS, email delivery and server management

If emails sent from your own server land in the spam folder in Gmail or Outlook, or never arrive at all, one of the first settings to check is rDNS (Reverse DNS), that is, your IP address's PTR record. This one-line record, which is often forgotten, has a direct impact on your email delivery rate.

In this guide, we explain what rDNS is, how a PTR record works, why it matters, how to set it up and test it, and the most common mistakes.

Short answer

rDNS (Reverse DNS) is a lookup that resolves an IP address to a domain name. Regular DNS resolves domain name β†’ IP, while rDNS resolves IP β†’ domain name. The record that holds this mapping is called a PTR record. A PTR record isn't set in your domain's DNS panel; it is defined by the provider that owns the IP address. Especially for mail servers, having a PTR record that matches the A record (FCrDNS) is a basic requirement for getting past spam filters.

Section 1

What Is rDNS?

On the internet, devices find each other by IP address; domain names make those addresses easier for people to remember. A lookup that translates a domain name into an IP address is called forward DNS, and it is provided by A and AAAA records. If you'd like to learn about DNS record types in detail, take a look at our article what is DNS and what A, CNAME and MX records do.

Reverse DNS is the exact opposite: you have an IP address and want to find out which hostname it belongs to. For example, an rDNS lookup for 203.0.113.25 might return mail.example.com.

Feature Forward DNS Reverse DNS (rDNS)
Question What is this domain's IP? Which domain does this IP belong to?
Record type A / AAAA PTR
Who manages the record? The domain's DNS provider The provider that owns the IP address
Example mail.example.com β†’ 203.0.113.25 203.0.113.25 β†’ mail.example.com
Section 2

How Does a PTR Record Work?

PTR records aren't kept in the regular DNS tree where domain names live, but in a special zone reserved for reverse lookups. For IPv4 this zone is in-addr.arpa, and for IPv6 it is ip6.arpa. The record name is formed by writing the IP address's octets in reverse order:

PTR record for 203.0.113.25
25.113.0.203.in-addr.arpa.   3600   IN   PTR   mail.example.com.

The reason for the reverse order is that DNS works hierarchically from right to left. This allows reverse DNS authority for an IP block to be delegated from the regional internet registry that allocates it (such as RIPE NCC) to the data center or provider that owns the block. For more on IP blocks, read our article what is an IP block.

Info: An IP should have a single PTR record

Although it's technically possible to add more than one PTR record to an IP address, it isn't recommended. Many mail servers only consider the first answer. Define a single PTR record per IP address and set it to the hostname of the server that sends email from that IP.

Section 3

Why Does rDNS Matter?

01

Email delivery rate

Gmail, Outlook, Yahoo and most corporate mail servers run an rDNS lookup on the IP address of the connecting server. If there's no PTR record, or it returns a generic name such as 203-0-113-25.static.provider.net, your email may be marked as spam or rejected outright. We covered the other causes of this in our article why business emails go to spam.

02

Trust and reputation

A meaningful PTR record that matches your domain shows that the IP address belongs to a properly managed server. Many blacklists and reputation services treat IPs with generic names or no PTR as home connections or compromised devices.

03

Reading logs and troubleshooting

Seeing hostnames instead of IP addresses in server logs, traceroute output and security tools makes it easier to understand where traffic is coming from. Network administrators also use PTR records to name their own infrastructure.

Section 4

FCrDNS: Forward and Reverse Matching

Mail servers usually check not just whether a PTR record exists, but also a two-way match called FCrDNS (Forward-Confirmed reverse DNS). The check is done in two steps:

  1. The PTR record of the connecting IP address is looked up: 203.0.113.25 β†’ mail.example.com
  2. The A record of the returned hostname is looked up: mail.example.com β†’ 203.0.113.25

If the two results confirm each other, FCrDNS passes. That's why, before defining the PTR record, you should create an A record in your domain's DNS panel for the hostname you'll use in the PTR, pointing to the same IP address.

Tip: Match the HELO / EHLO name too

The name your mail server uses to identify itself in the SMTP connection (myhostname in Postfix, primary_hostname in Exim) should be the same as the hostname in the PTR record. When the PTR, the A record and the HELO name are all identical, you get the cleanest picture as far as spam filters are concerned. Don't forget to complete this with SPF, DKIM and DMARC records.

Section 5

How to Set Up a PTR Record

You can't add a PTR record from your domain's DNS panel, because the reverse DNS zone belongs to the owner of the IP address. If you rent a server, that owner is the provider you rent it from. The general flow is as follows:

Step 1

Choose a hostname

Choose a meaningful hostname for your server under your domain. For example, mail.example.com works for a mail server and srv1.example.com for a general-purpose server.

Step 2

Create the A record

In your domain's DNS management, add an A record for the chosen hostname pointing to your server's IP address (plus an AAAA record if you use IPv6). Don't request the PTR until you've confirmed the record has propagated; some providers don't accept PTR requests that don't match.

Step 3

Have your provider set the PTR record

If your provider's client area has an rDNS or Reverse DNS setting, enter the hostname for the relevant IP address yourself. If there's no such field, open a support ticket with the IP address and the hostname you want.

Step 4

Match the server settings

Set the server's own hostname and the mail software's HELO name to the same value. On Linux servers, you can do this with the following command:

Setting the hostname on a Linux server
sudo hostnamectl set-hostname mail.example.com
hostnamectl
Info: If you have your own IP block

If you have an IP block allocated to you by RIPE NCC, you can delegate authority for the reverse DNS zone to your own DNS servers in the RIPE database and manage the PTR records yourself. With leased IP blocks, this is usually done through the provider. For details, see our article what is IPv4 leasing.

Section 6

How to Check rDNS

You can test that the PTR record is set correctly with a few simple commands. Depending on the record's TTL, changes can take anywhere from a few minutes to a few hours to propagate.

Linux / macOS: reverse lookup with dig
dig -x 203.0.113.25 +short
# Expected output:
# mail.example.com.
Windows: reverse lookup with nslookup
nslookup 203.0.113.25
FCrDNS check (forward lookup)
dig mail.example.com A +short
# Expected output:
# 203.0.113.25

If you'd rather not use the command line, online MX and rDNS checkers run the same query. Sending a test email and inspecting the headers in Gmail with Show original is also a practical way to see the PTR, SPF, DKIM and DMARC results at a glance.

Section 7

Common Mistakes

  • βœ“ Trying to add the PTR record in the domain's DNS panel: It has no effect unless the record is defined on the provider's side.
  • βœ“ Sending email with a generic PTR: Automatic names such as static.provider.net increase your spam score.
  • βœ“ Using a hostname without an A record: Even if the PTR is correct, FCrDNS fails.
  • βœ“ Setting the PTR to the bare domain: Instead of example.com, prefer a server-specific subdomain such as mail.example.com.
  • βœ“ Forgetting IPv6: If the server sends email over IPv6, the IPv6 address needs a PTR record too; otherwise services like Gmail may reject the email.
  • βœ“ Not updating the PTR after moving servers: When you switch to a new IP address, update the PTR, A record and SPF record together.
Section 8

Frequently Asked Questions

Do I need rDNS for my website?

No. A / AAAA records are all visitors need to reach your website. rDNS mainly matters for servers that send email and for network management.

I use shared hosting. Can I change the PTR record?

Usually not. On shared hosting, many sites use the same IP address, so the PTR record shows the provider's server name and the provider manages the email reputation. To set your own PTR record, you need a VDS or dedicated server with its own IP address.

Can I set up PTR records for multiple domains on one IP address?

It isn't recommended. You can send email for multiple domains from the same server; it's enough for the PTR record to show the server's hostname and for that name to match its A record. Set up SPF, DKIM and DMARC separately for each domain.

How long does it take for a PTR record to become active?

Once the record is defined, it can usually be queried within minutes. Depending on the previous record's TTL, some resolvers may show the old value for a few hours.

Does rDNS replace SPF and DKIM?

No. These checks complement each other. rDNS identifies the sending server, SPF defines the authorized IPs, DKIM shows the message hasn't been altered, and DMARC sets the policy to apply based on those results.

Section 9

Conclusion

rDNS and the PTR record are among the basic settings anyone who sends email from their own server should complete on day one. Choose a meaningful hostname, create an A record for it, have your provider set the PTR record and set your server's HELO name to the same value. When you apply these steps together with SPF, DKIM and DMARC, the chances of your emails reaching the inbox increase significantly.

Servers with Their Own IP Address

Netiyo VDS and dedicated servers run on Turkey-based infrastructure with a dedicated IP address, KVM virtualization and full root / administrator access. Run your mail server or application on your own IP address; for even higher performance, you can also explore our dedicated server options.

Explore VDS Server Plans
Never Miss a Post

Get our latest tutorials, guides and product news in your inbox.

You're subscribed to our newsletter.