Email DNS records: SPF, DKIM and DMARC
Updated 11/29/2026
If you send email from your domain (from an app or your own server), three DNS records decide whether you reach the inbox or spam: SPF, DKIM and DMARC.
SPF: who is allowed to send
A TXT record that lists the servers authorized to send email for the domain:
example.com. TXT "v=spf1 ip4:203.0.113.10 -all"
DKIM: a cryptographic signature
The email server signs each message, and the public key is published in DNS:
selector._domainkey.example.com. TXT "v=DKIM1; k=rsa; p=PUBLIC_KEY"
DMARC: what happens to messages that fail
_dmarc.example.com. TXT "v=DMARC1; p=quarantine; rua=mailto:[email protected]"
Do not forget reverse DNS
Besides these three, you need a correct PTR for the server IP, see What is reverse DNS (PTR).
Verify
Send a test email to a Gmail account and check in the message details whether SPF, DKIM and DMARC show as "PASS". There are also free online tools to test these records.
Put this guide into practice on your own VPS
EU cloud servers, billed hourly, ready in minutes, with one-click installs for dozens of apps.
See pricingRelated tutorials
How to find your IP address on Windows: public and local
Find your public IP address in a second and your local IP from Settings, Command Prompt or PowerShell, on Windows 10 and 11.
Updated 11/29/2026Networking & DNSHow to use Cloudflare for DNS, cache and protection
Cloudflare offers fast DNS, global cache and basic protection for free. Here is how to connect it to your server.
Updated 11/29/2026Networking & DNSDNS record types explained simply
A, AAAA, CNAME, MX, TXT, NS: what each DNS record means and when to use it.
Updated 11/29/2026