Email DNS Check

DNS OPERATIONS GUIDE

Email DNS troubleshooting

Start with the failing record in your check. Compare the authoritative answer first, then verify the SMTP, HTTPS or reporting path the record refers to.

Reviewed by Mira John Updated

Find the active DNS zone

Run a trace for the failing name and type. Compare the parent’s delegation with the servers you intend to use. Query each delegated server directly. Look for the aa flag and compare the answers.

If the authorities disagree, fix the zone or its replication first. If they agree, compare the resolver answer and remaining TTL. For SERVFAIL, compare a validating lookup with one using +cdflag, then inspect DS and DNSKEY if disabling validation changes the result.

dig +trace example.com MX
dig @ns1.example.net example.com MX +norecurse
dig @1.1.1.1 example.com MX +dnssec
dig @1.1.1.1 example.com MX +dnssec +cdflag

Fix a missing or invalid SPF record

Use smtp.mailfrom in Authentication-Results to find the envelope domain. Inventory the services that send with that domain and take their SPF mechanisms from their setup guides.

At that DNS name, create or edit one TXT record beginning v=spf1. Merge duplicate policies and replace any effective +all with the intended policy. Recheck the TXT answer and send a fresh test message to verify spf=pass.

dig +short TXT example.com

Publish or repair a DKIM key

Read d= and s= in a sent message’s DKIM-Signature, or open the sending service’s DKIM setup. In the authoritative zone for d=, publish the provider’s TXT or CNAME at s._domainkey.d. For a CNAME, look up the target’s TXT to verify it returns the public key.

When rotating a revoked key, publish the replacement at its new selector, verify it from public DNS and enable signing in the provider console. Send a test and confirm dkim=pass for the intended signing domain.

dig +noall +answer TXT selector1._domainkey.example.com

Fix or verify a DMARC policy

Look up _dmarc at the From domain and check the applicable parent policy. If you need a policy at the exact name, publish one TXT record beginning v=DMARC1; p= and use the intended policy value. Keep reporting destinations on the same record.

Verify alignment for each sending service before moving from reporting to quarantine or reject. Send a fresh test message and check its Authentication-Results for dmarc=pass.

dig +short TXT _dmarc.example.com

Verify MTA-STS against the active MX set

Check _mta-sts TXT for the policy ID. Fetch the HTTPS policy and check version, mode, max_age and the mx entries. Verify that the listed patterns cover every active exchanger.

Test STARTTLS and hostname validation on each exchanger. Review TLS reports in testing mode before enforcing. Update the HTTPS policy and publish a new TXT ID when the policy changes.

dig +short _mta-sts.example.com TXT
curl -fsS https://mta-sts.example.com/.well-known/mta-sts.txt
openssl s_client -starttls smtp -connect mx1.example.net:25 -servername mx1.example.net -verify_hostname mx1.example.net -verify_return_error

Check the TLS reporting destination

Query _smtp._tls for one TLSRPTv1 policy. Check the rua endpoint in the reporting service or mailbox. Use a sender that supports TLS reporting and verify that its aggregate reports arrive.

For delivery incidents, correlate reported MX or certificate failures with the active MX set, the MTA-STS policy and your deployment time.

dig +short _smtp._tls.example.com TXT

Check BIMI from the From domain

Look up the BIMI selector, usually default._bimi. Check DMARC enforcement and alignment on a received message. Fetch the l= HTTPS URL and validate the logo against the SVG Tiny PS profile.

Check the receiving provider’s certificate requirements. If the record publishes a certificate URL, verify that it is reachable and matches the logo.

dig +short default._bimi.example.com TXT
curl -fsSI https://example.com/mail-logo.svg

References

Related guides

MX record monitoring

Check mail exchanger targets and priorities, compare MX records across public DNS resolvers, and set a baseline for mail routing changes.

Email DNS monitoring

Check MX, SPF, DKIM and DMARC at the right DNS names. Capture a baseline and isolate changes during email migrations and deliverability incidents.

Nameserver monitoring

Compare NS answers, verify the parent delegation against the zone apex, and check mail DNS and DNSSEC during a nameserver migration.

No MX record found

Find out why an MX lookup is empty, returns NXDOMAIN or SERVFAIL, or shows 0 . Check the authoritative zone and restore the intended mail route.