Gmail rejects mail from sources that look careless about their network identity. One of its checks produces the response 550-5.7.25 The IP address sending this message does not have a PTR record setup, or the corresponding forward DNS entry does not point to the sending IP. A related text says that "This message does not have authentication information or fails to pass authentication checks" for IPv6 senders, and another says that the connection must be encrypted with TLS. Together these messages share the code 5.7.25 and the same root idea: Gmail wants a sending address that is identifiable, consistently configured in DNS and secured. This guide explains what each variant means, how reverse DNS and forward-confirmed reverse DNS work, what changes for IPv6, what to configure on your server and in DNS, and how to test the result. It is most relevant to anyone running their own mail server, a dedicated IP at a provider or a cloud VM that sends mail directly.
The variants of the message
| Text in the reply | What Gmail is saying | Fix |
|---|---|---|
| The IP address sending this message does not have a PTR record setup | No reverse DNS exists for the connecting IP | Ask the owner of the IP block to create a PTR |
| ... or the corresponding forward DNS entry does not point to the sending IP | PTR exists, but the hostname does not resolve back to that IP | Create a matching A or AAAA record for the PTR hostname |
| Messages from IPv6 addresses must be authenticated | Source is IPv6 and fails SPF or DKIM, or lacks PTR | Add SPF/DKIM and PTR for the IPv6 address |
| This message is not encrypted / TLS required | Gmail expects STARTTLS on the connection | Enable and offer TLS on the sending server |
What a PTR record is
A PTR record is the reverse of an A record. Where an A record turns a hostname into an address, a PTR turns an address into a hostname. It lives in a special zone (in-addr.arpa for IPv4, ip6.arpa for IPv6), and whoever controls the IP address block controls that zone. That is usually your hosting provider, cloud vendor or ISP, not the owner of your domain. You normally set the PTR through the provider's control panel or by request. See reverse DNS, PTR and HELO for the background.
Forward-confirmed reverse DNS
Receivers check more than the existence of a PTR. They run forward-confirmed reverse DNS (FCrDNS): look up the PTR for the connecting IP, take the hostname it returns, look up that hostname's A (or AAAA) record and check that the answer includes the original IP. A mismatch at any step fails the test. An example of a correct pair:
# IP 203.0.113.25 connects to Gmail
$ dig -x 203.0.113.25 +short
mail.example.com.
$ dig mail.example.com A +short
203.0.113.25
# Both directions agree: FCrDNS passesCommon mistakes are a PTR pointing to the provider's generic name such as 203-0-113-25.static.provider.net (it passes FCrDNS if the provider also maintains the forward record, but it looks anonymous), a PTR that points to your domain without a matching forward record, several PTR records on one IP (avoid this; use one) and a PTR with a hostname in a domain you do not control.
Setting it up
- Choose a hostname for the sending IP, preferably in your own domain, such as
mail.example.comormta1.example.com. - Publish the forward record: an A record (for IPv4) or AAAA (for IPv6) from that hostname to the sending IP.
- Request the PTR from the owner of the IP block, pointing to that exact hostname. Many providers offer a field for "reverse DNS" on the IP.
- Set the HELO/EHLO name of your mail server to the same hostname. See HELO/EHLO errors.
- Wait for caches to expire, then test from outside your network.
- Check SPF and DKIM as well. See authenticate your sending domain and the checker.
IPv6 needs extra care
Gmail applies stricter rules to mail arriving over IPv6. In the general guidance for senders, IPv6 sources must have a valid PTR and must authenticate, and Gmail may reject IPv6 mail that does not. Many servers prefer IPv6 automatically when the recipient has an AAAA record, so a server that you thought was sending over IPv4 may be using an IPv6 address that nobody set up. Check the headers of a delivered message, or the logs of your server, to see which address connected. Then choose one of two paths:
- Configure IPv6 properly: assign a stable address, add a PTR and a matching AAAA record, include the IPv6 address in SPF with
ip6:and sign with DKIM. See sending email over IPv6. - Send over IPv4 only: tell the mail server to prefer IPv4 for outgoing connections (for example
smtp_address_preference = ipv4in Postfix, or force the interface address). This is a valid choice if you are not ready to run IPv6 for mail.
TLS
The 5.7.25 family also covers connections that offer no encryption. Gmail expects senders to use TLS when it is available, which it always is. Enable opportunistic STARTTLS on your sending server, install a valid certificate, and check that the server offers the strongest protocol versions your software supports. A failing TLS negotiation results in a different error, see SMTP connection timeouts and TLS errors and email TLS and STARTTLS.
Testing
# Reverse lookup
dig -x 203.0.113.25 +short
# Forward lookup of the name returned
dig mail.example.com A +short
# IPv6 equivalents
dig -x 2001:db8::25 +short
dig mail.example.com AAAA +short
# What does the server say in EHLO and does it offer STARTTLS?
openssl s_client -starttls smtp -connect smtp.example.com:25 -crlfThen send a test to a Gmail address and read the headers of the delivered message, in particular Authentication-Results and the Received lines. If you use Google Postmaster Tools, check the sections for authentication and encryption, see Postmaster Tools setup. Remember that DNS changes may take time to appear; the TTL of the old record applies.
If you use a sending provider
If you send through a managed relay or API, the PTR belongs to the provider's IPs and is not your responsibility. A 5.7.25 from Gmail in that situation points to an issue at the provider, or to a dedicated IP that has not been configured, and you should open a support request with the exact bounce text. If you route mail through your own server and then through the relay, verify which address Gmail sees, because the last hop is what counts. See dedicated vs shared IP.
Related checks Gmail makes
| Requirement | Why it matters | Where to read more |
|---|---|---|
| SPF or DKIM passes, DMARC published for bulk senders | Authentication of the message | bulk sender requirements |
| Low spam complaint rate | Reputation | complaint rates |
| One-click unsubscribe for marketing mail | Bulk sender rule | one-click unsubscribe |
| Valid message format and Message-ID | Standards compliance | Message-ID header |
| No blocklist entry for IP or domain | Reputation | blacklist check |
A 5.7.25 rejection is among the easier Gmail errors to cure: it is a matter of DNS and server settings, with no reputation to rebuild. Give the IP a clear identity, make the forward and reverse records agree, offer TLS and authenticate your mail.
Skip the DNS plumbing Send through managed, correctly configured IP addresses with reverse DNS in place.
References and further reading
Frequently asked questions
What does Gmail 550 5.7.25 mean?
The sending IP has no valid PTR record, the PTR hostname does not resolve back to the IP, or the connection fails Gmail's IPv6 and encryption expectations.
Who creates the PTR record for my IP?
The owner of the IP address block, usually your hosting provider or ISP. You ask them to point it at your chosen hostname.
What is forward-confirmed reverse DNS?
A check that the PTR hostname of an IP resolves back to the same IP address.
Why do I get 5.7.25 only for some messages?
Your server may use IPv6 for some recipients and IPv4 for others. The IPv6 address may lack a PTR or authentication.
Can I send over IPv4 only?
Yes. Configure your mail server to prefer IPv4 for outgoing connections if you are not ready to run IPv6 for mail.