SPF, DKIM and DMARC Explained: Keep Your Business Email Out of Spam

Written by

in

When emails from your domain land in spam or get rejected, the cause is usually missing or incorrect email authentication records in DNS. Three records matter most: SPF, DKIM and DMARC. Here is what each one does.

SPF: who may send email for your domain

SPF is a TXT record on your domain that lists the servers allowed to send mail on its behalf. A domain should have only one SPF record. A typical example looks like this:

v=spf1 a mx include:_spf.your-provider.com ~all

Replace the include value with the one your email or newsletter provider gives you.

DKIM: a signature on every message

DKIM adds a cryptographic signature to outgoing messages. Your mail server signs each message with a private key, and you publish the matching public key as a TXT record, usually at a name like selector._domainkey.yourdomain.com. In cPanel you can check and enable it under Email Deliverability.

DMARC: what to do when checks fail

DMARC tells receiving servers what to do when SPF or DKIM fails, and where to send reports. Start in monitoring mode, published as a TXT record at _dmarc.yourdomain.com:

v=DMARC1; p=none; rua=mailto:[email protected]

After you have reviewed the reports for a few weeks and fixed any legitimate senders that fail, you can tighten the policy to quarantine and later to reject.

Common mistakes

  • Publishing two SPF records instead of merging them into one.
  • Exceeding the limit of 10 DNS lookups in SPF by adding too many include entries.
  • Forgetting a third-party sender, such as a newsletter or invoicing service.
  • Editing DNS in the wrong place when your nameservers are hosted elsewhere.

How to check your setup

Send a test message to a Gmail mailbox, open the original message source and look for the Authentication-Results header. It should show spf=pass, dkim=pass and dmarc=pass.

Our hosting package includes free email accounts on your own domain, set up with these records.

Comments

Leave a Reply

Your email address will not be published. Required fields are marked *

Ready to talk about your website?Get a free quote