Why PTR records are important?
An email travels across the servers (MTAs) on the way to the recipient’s email client. Before it’s delivered to an inbox, most email providers will enforce one simple test. They’ll run a DNS lookup simultaneously with a Reverse DNS lookup and will compare whether the results match. If they don’t or a PTR record simply doesn’t exist, an email is likely to be sent to spam or even discarded.
PTR Records are a defense used by servers against spammers, especially those using fraudulent domain names (let’s say, mailtrop.io). If the records are configured for mailtrap.ip, resolving an IP address with a PTR lookup (Reverse DNS lookup) won’t point to a real domain. This, as a result, will send up a red flag for an MTA and will likely lead to an email being discarded.
That’s why it’s important to have a PTR record added to your domain’s DNS if you use it to send mass emails.
PTR records are also important for marketers and for their analytical tools, such as Google Analytics. As a website owner, you can easily see which IP addresses visit your pages. The numbers themselves would be rather meaningless but thanks to Reverse DNS lookup you can see the hostnames or domains of visitors. And this can give you some valuable information.
Let’s now learn how to add a PTR record to a domain’s DNS.
How to set up PTR records?
Same as when you add a regular A record, the steps for adding a PTR record also very much depend on your hosting provider. For some, you should be able to add one in your admin panel. For others, you might need to reach out to the support team so they can set this up for you. We’ll assume you’re able to add PTR Records yourself.
To do so, you’ll first need to define a Reverse zone. By definition, a zone is a separate portion of a domain name space in DNS. A zone is directly related to the size of your IP network. Mailtrap’s IP (3.215.223.38) uses a traditional IPv4 protocol (using an X.X.X.X structure) so there are 255 IP addresses available – 3.215.223.1, 3.215.223.2 and so on until 3.215.223.255.
Since we need an address for the entire zone, we omit the last digit and reverse the order of numbers. The address of our PTR record would be 223.215.3.in-addr.arpa. If we were to create a PTR record only for one single address, we would use 38.223.215.3.in-addr.arpa.
What’s up with in-addr.arpa in each address? It’s a second-level domain suffix that’s added to all the addresses in IPv4. If you were to use a more common IP in the IPv6 system, a PTR Record’s address would end with ip6.arpa.
Add a PTR record following these rules. Then, check if there’s a match. Mailtrap.io should point to 3.215.223.38 (A record) while 38.223.215.3.in-addr.arpa should point to Mailtrap.io (PTR record). If this is the case for your domain’s DNS, you can say you’ve reached a Forward-confirmed reverse DNS (FCrDNS).
A PTR record should look like this: