Skip to content

SPF, DKIM and DMARC: the cornerstones of email deliverability and security

SPF, DKIM and DMARC: the cornerstones of email deliverability and security

SPF, DKIM, DMARC and BIMI are technologies that help your emails get through to the recipient’s inbox and protect your domain from misuse. Spam filters keep evolving, and the requirements for email authentication have tightened considerably in recent years.

In this article I go through what the following abbreviations mean and why they are critical:

  • SPF (Sender Policy Framework)
  • DKIM (DomainKeys Identified Mail)
  • DMARC (Domain-based Message Authentication Reporting and Conformance)
  • BIMI (Brand Indicator Message Identification)

Note: with Tuonetti‘s web hosting, SPF, DKIM and DMARC are often set up automatically or easy to turn on.

The big email services set the rules

Most of the world’s email traffic goes through Google’s Gmail and Microsoft’s Outlook. These companies have set strict rules on which messages get through.

In particular, since February 2024 Google and Yahoo have required bulk senders (more than 5,000 messages a day) to have SPF, DKIM and DMARC in order. If these are missing, the messages end up in spam or are rejected altogether.

What do SPF, DKIM and DMARC do?

In short, SPF, DKIM, DMARC and BIMI aim to verify that the sender of an email is genuine. They prevent identity theft and email forgery (spoofing). If your domain’s settings are incomplete, the receiving server may block your messages altogether to protect its users.

Updating the records in DNS management

SPF, DKIM, DMARC and BIMI are DNS records. To set them up, you need access to the name server (DNS) settings of your domain. A faulty record can cut off your email, so I recommend contacting your service provider if you are unsure.

SPF record (Sender Policy Framework)

An SPF record says which servers (IP addresses) are authorised to send email in your domain’s name. It usually lists your own email provider’s servers and any newsletter tools you use.

Example of an SPF record:

v=spf1 include:_spf.google.com include:amazonses.com ~all

  • DNS type: TXT
  • Content: always starts with v=spf1
  • Include: lists the allowed services, in this example Google Workspace and Amazon SES.
  • Restriction: the tag at the end sets how strict the record is:
    • -all (Fail): a strict block. Only the listed servers may send, and everything else is rejected.
    • ~all (SoftFail): the most common setting. Messages from elsewhere are marked as suspicious but may still get through (often to the spam folder).

DKIM record (DomainKeys Identified Mail)

A DKIM record adds a digital signature to an email. This confirms two things: that the sender is genuine and that the message is intact. With DKIM, the recipient knows the message hasn’t been altered along the way.

DKIM is based on a key pair: the private key sits on the server and signs the messages, while the public key is published in a DNS record so that the recipient can check the signature.

Example of a DKIM record:

v=DKIM1; k=rsa; p=MxxxxxxxxjANBxxxxxxxx…

  • DNS type: TXT (often on a subdomain, e.g. google._domainkey)
  • k=rsa: the encryption algorithm. A key of at least 2048 bits is recommended today.
  • p=…: the public key.

The DMARC record ties it all together

DMARC (Domain-based Message Authentication Reporting and Conformance) is the boss of modern email security. It uses the SPF and DKIM checks and tells the recipient what to do if they fail.

Without a DMARC record, the recipient has to guess whether a forged message should be rejected or not. DMARC also lets you receive reports, so you can see who is sending mail in your name.

Example of a DMARC record:

v=DMARC1; p=quarantine; rua=mailto:reports@yourdomain.com

  • DNS type: TXT (on the subdomain _dmarc)
  • p (Policy): what to do when the checks fail:
    • p=none: reporting only, no action. Good while you are setting things up.
    • p=quarantine: sends failed messages to spam.
    • p=reject: rejects the messages altogether. This is the goal if you want the strongest security.
  • rua: the email address the XML reports are sent to.

BIMI: your logo in the inbox (advanced feature)

BIMI (Brand Indicator Message Identification) is a standard that lets your company’s logo appear next to your message in the recipient’s email client. This builds trust and brand visibility.

Setting up BIMI is more demanding than the other records, though:

  1. The DMARC policy must be p=reject or p=quarantine.
  2. The logo must be in SVG Tiny PS format.
  3. Several services (such as Gmail) require a paid VMC certificate (Verified Mark Certificate) before they show the logo (Gmail now also accepts a CMC, or Common Mark Certificate, which doesn’t need a trademark). VMCs are issued by companies such as DigiCert, GlobalSign or SSL.com, and you need a registered trademark to get one.

You can find out more about the BIMI standard on the BIMI Group’s website.

Summary: why are SPF, DKIM and DMARC a must?

SPF, DKIM and DMARC are no longer just “fine-tuning for enthusiasts”: they are a basic requirement for email. If your company’s email matters, these settings have to be in order. Modern service providers such as Tuonetti or Google Workspace help you manage them.

Remember, though, that technical records alone don’t guarantee delivery if the content of the message itself looks like spam or the sending IP address has a poor reputation.

If you would like email for your company, with SPF, DKIM and DMARC records that I put in order together with you, take a look at business email, and if a domain is still waiting to be used, domain parking says on its behalf that it sends and receives no email.

Frequently asked questions

What is an SPF record?

SPF (Sender Policy Framework) is a DNS record that lists all the servers and IP addresses allowed to send email in that domain’s name. It stops other servers from forging the sender details.

Are SPF, DKIM and DMARC mandatory?

In practice, yes. Google and Yahoo, for example, tightened their rules in February 2024 and require these records, especially from bulk senders. Without them, your messages are likely to go to spam or be rejected.

What is the difference between DKIM and DMARC records?

DKIM signs the message digitally, confirming that it hasn’t been altered on the way. DMARC, on the other hand, plays the boss: it tells the recipient what to do if the SPF or DKIM check fails (for example, reject the message altogether).

How do I get my company logo to show in Gmail (BIMI)?

You need a working DMARC policy (quarantine or reject), an SVG logo file in the right format and, usually, a paid VMC certificate (Verified Mark Certificate) that proves you own the trademark, or a CMC certificate if your logo isn’t a registered trademark. Without the certificate, the logo usually won’t show in Gmail.

Blog

Read next

All articles
Google Tag Manager: what it is and how to use it

Guides

Google Tag Manager: what it is and how to use it

Google Tag Manager transforms the way digital marketing work gets done. In this guide I explain what GTM is, why every website needs it and how to set it up step by step, from installation all the way to the Consent Mode v2 settings.

How to stop spam on your WordPress site

Guides

How to stop spam on your WordPress site

Spam is one of the most common headaches for anyone who runs a WordPress site, but today it is easier to fight than ever. This guide covers the most effective ways to stop spam on your WordPress site, from good-quality web hosting to smart plugins and privacy-friendly CAPTCHA alternatives.

What is DNS?

Guides

What is DNS?

Without DNS, we would have to remember long strings of numbers to visit websites. This article explains in plain language what DNS is, how a lookup happens in milliseconds and why optimising your name server settings can make your browsing faster and safer.

Need a hand with this? Ask me.

Tuomas LindroosI answer myself, usually within two hours. You can also send a message through the contact form.