How do I set up a PTR record for my sending IP?

Still have a question, spotted an error, or have a better explanation or a source we should cite?

Before you can configure your PTR record, you need to understand one key thing: you don't set a PTR record through your domain registrar. You set it through whoever owns your sending IP address. That's usually your hosting provider, cloud provider, or ISP. If you're not sure who that is, look at your server control panel or the invoice for your VPS or dedicated server.

A PTR record maps your IP address back to a hostname. Receiving mail servers do a reverse DNS lookup on your sending IP to check whether that hostname looks legitimate. If nothing comes back, or if what comes back doesn't match your mail server's name, that's a red flag that can hurt your deliverability.

Here's how to actually set it up.

Step 1: Pick the right hostname

Your PTR hostname should match the name your mail server uses when it introduces itself (the HELO/EHLO name). Something like mail.yourdomain.com works well. Avoid using a generic hostname your provider assigned, like ec2-1-2-3-4.compute-1.amazonaws.com. Spam filters have learned to distrust those.

Step 2: Create a matching A record first

Your PTR hostname needs a matching A record in your DNS. So if your PTR points to mail.yourdomain.com, then mail.yourdomain.com must resolve back to that same IP address. This two-way match is called forward-confirmed reverse DNS (FCrDNS), and many receiving servers check for it. Set the A record in your DNS first, before requesting the PTR, so it's already live when your provider configures it.

Step 3: Set the PTR record through your IP owner

Where you do this depends on your infrastructure:

  • Amazon SES / EC2: Go to the EC2 console, find your Elastic IP, and look for "Reverse DNS" in the address details. You submit a request and AWS applies it within a day or two.
  • Google Cloud Platform: In the GCP console, go to VPC Network, then External IP addresses, and edit the PTR field directly on your static IP.
  • Azure: Navigate to your Public IP address resource in the Azure portal, look for the "Reverse FQDN" field under Configuration, and enter your hostname there.
  • Dedicated servers or VPS providers (Hetzner, DigitalOcean, Vultr, etc.): Most have a reverse DNS field right in the server or networking panel. Check your provider's docs if you can't find it.
  • Your ISP (for on-premises mail servers): You'll likely need to open a support ticket. Have your IP address and intended hostname ready.

Step 4: Verify it worked

And once the PTR is set (give it a few minutes to propagate), you can check it with a simple command in your terminal:

dig -x YOUR.IP.ADDRESS.HERE

The dig -x command performs a reverse DNS lookup. You should see your hostname in the ANSWER SECTION. Then confirm the forward match by running dig mail.yourdomain.com and making sure it returns the same IP. If both match, you're in good shape.

Not comfortable with the command line? Our free Email Header Analyzer can show you what your PTR currently looks like after parsing a sent message, or just drop us a note via the SOS hotline if you're stuck.

Contributors

Who worked on this answer

Every name links to their profile. Every company links to their site. Real people, real accountability.

Ask an AI · tailored to your setup

Walk me through my PTR setup

I need to set up a PTR record for my sending IP. Tell me exactly what hostname to use, where to set it based on my provider (AWS / GCP / Azure / VPS / ISP), what A record I need to create first, and how to verify the forward-confirmed reverse DNS match once it's live.

Edit the yellow boxes, then send to the AI of your choice.