What are SPF, DKIM and DMARC and what are they for?
They are three records you publish in your domain’s DNS so the servers receiving your mail can check it is really yours. SPF lists the servers allowed to send with your domain. DKIM adds a signature to every message that is verified with a public key. DMARC requires at least one of the two to validate the domain shown as the sender, says what to do with anything that fails and sends you reports. BIMI, which is optional, shows your logo once DMARC is enforced, and ARC helps forwards and mailing lists avoid breaking authentication.
The minimum for a domain that sends email in 2026:
- A single SPF record listing your servers, ending in
~allor-alland staying within 10 DNS lookups. - DKIM enabled in every service that sends for you, with 2048-bit keys signing with your domain.
- A published DMARC record: start at
p=nonewith reports and move toquarantineorrejectwithin a few weeks. - If you send more than 5,000 emails a day to Gmail, Yahoo or Outlook.com, all of the above plus one-click unsubscribe are mandatory.
Published and reviewed on . Covers RFC 9989 (DMARCbis, May 2026) and the IETF proposal to retire ARC.
Email was designed in the 1980s for a small network where everybody knew each other. The protocol that carries it, SMTP, does not check who you are: anyone can write any domain they like as the sender. Everything that protects a domain from spoofing today was bolted on later, on top, which is why it pays to understand first how a message travels.
In the reviews I carry out, the problems rarely come from not knowing the acronyms. They come from a marketing platform nobody authenticated, an SPF record that went past ten lookups without anyone noticing, or a DMARC record sitting at p=none for years. This guide explains why each thing happens so you can decide with good judgement.
How an email travels, from your keyboard to the inbox
A message passes through at least four different programs. Each one has a name and a role. They are worth knowing, because email headers, admin panels and the RFCs themselves all speak in those terms.
- MUAMail User Agent
Your email program: Outlook, Gmail in the browser, Apple Mail, Thunderbird or the mobile app. It writes, sends and reads.
- SMTP · 587 or 465 · with username and password
- MSAMail Submission Agent
Your provider’s front door. It checks you are an authorised user before accepting the message.
- inside the provider
- Outbound MTAMail Transfer Agent
It signs the message with DKIM, asks DNS which server receives the recipient’s mail (its MX record) and hands the message over.
DKIM signature - SMTP · port 25 · STARTTLSDNS: MX for destination.com?
- MX · inbound MTAthe recipient’s server
The one listed in the recipient’s MX. This is where SPF, DKIM and DMARC are checked, by querying your domain’s DNS.
SPF · DKIM · DMARC - filtering and delivery
- MDAMail Delivery Agent
It stores the message in the mailbox and applies spam filtering, rules and quarantine.
- IMAP · POP3 · JMAP · Exchange
- MUAthe recipient’s program
It displays the message. If your domain has BIMI, this is where your logo appears.
BIMI
In Microsoft 365 or Google Workspace the MSA, MTA and MDA are part of the same platform, but the Received headers still leave a trace of every internal hop. A server can also act as a relay: it accepts mail from another server in order to pass it on. If it accepts mail from anyone without authentication, it is an open relay, one of the classic mistakes that end up on blocklists.
The MX record is the piece that connects both worlds: it publishes which servers receive a domain’s mail and with what preference (the lowest number is tried first). A domain that receives no mail can say so with a null MX, 0 ., defined in RFC 7505.
| Protocol | Port | What it is for |
|---|---|---|
| SMTP | 25 | Between servers, MTA to MTA. Usually encrypted with STARTTLS. |
| SMTP submission | 587 | From the email program to your server, with username, password and STARTTLS (RFC 6409). |
| Submission with implicit TLS | 465 | The same as 587, but encrypted from the first byte. RFC 8314 prefers it. |
| IMAP / IMAPS | 143 / 993 | Reading mail while keeping it on the server. |
| POP3 / POP3S | 110 / 995 | Downloading mail to the device. |
| JMAP | 443 | A modern protocol over HTTPS (RFC 8620 and 8621). |
| Exchange and Microsoft Graph | 443 | What Outlook and mobile devices use with Microsoft 365. |
The SMTP conversation, and why anyone can write your domain
When one server delivers mail to another, they hold a fairly readable text conversation. This is a condensed version of what happens when empresa.es sends an invoice to destino.es:
- S
220 mx.destino.es ESMTP - C
EHLO mail.empresa.esThe greeting: it identifies the connecting server (HELO). - S
250-STARTTLS - C
STARTTLSFrom here on the conversation is encrypted, if both sides can do it. - C
MAIL FROM:<[email protected]>The envelope. Bounces go back to this address, and it is the one SPF checks. - C
RCPT TO:<[email protected]>Who it is delivered to. - C
DATA - C
From: Billing <[email protected]>The letter. What Ana sees in her inbox and what DMARC protects. - C
DKIM-Signature: v=1; d=empresa.es; s=selector1; …The signature added by the outbound server. - C
Subject: September invoice - C
.A dot on a line by itself marks the end of the message. - S
250 OK: queued
Nothing in this conversation forces MAIL FROM and From to match, or either of them to belong to whoever is connecting. That is what makes spoofing possible and, at the same time, what makes legitimate uses possible: a sending platform puts its own envelope on a message with your From, and a forward keeps your sender even though it leaves from another server. SPF, DKIM and DMARC exist to tell one case from the other.
Envelope and letter: the identities of an email
The comparison with postal mail works well. The envelope carries the address to return the letter to if it cannot be delivered; the letter inside carries the signature and the sender the recipient reads. An email has four different identities, and each protocol validates one of them:
- HELO / EHLO
mail.sending-provider.com- MAIL FROM → Return-Path
[email protected]
SPF checks the IP may send for this domain.
- From
Example Shop <[email protected]>- DKIM-Signature
d=empresa.es; s=k2
DKIM checks the signature of the d= domain.
DMARC asks: has SPF or DKIM validated a domain that matches the From? In this example SPF validates sending-provider.com (no match) and DKIM validates empresa.es (match). DMARC passes thanks to DKIM.
| Identity | Where it lives | Who sees it | What validates it |
|---|---|---|---|
| HELO / EHLO | SMTP greeting | Servers | SPF, when the envelope is empty |
| MAIL FROM (RFC 5321) | SMTP envelope; recorded as Return-Path | Servers; it receives bounces | SPF |
| From (RFC 5322) | Message header | The person reading it | DMARC, through aligned SPF or DKIM |
| DKIM d= | DKIM-Signature header | Servers | DKIM |
There is a fifth identity nobody validates: the display name (“Example Bank” or “Managing Director”). That is why phishing relies on it so much, and why DMARC, even when perfectly configured, does not replace training or external sender warnings.
Try it: six emails, six outcomes
Pick a scenario and watch what the recipient’s server checks at each step. All of them assume empresa.es publishes SPF, DKIM and DMARC with p=reject.
| Scenario | SPF | DKIM | DMARC | What happens |
|---|---|---|---|---|
| Legitimate email | pass, aligned | pass, aligned | pass | Inbox, with logo if BIMI is set up. |
| Direct spoofing | fail | no signature | fail | Rejection or quarantine depending on your policy. |
| Automatic forward | fail: it leaves from the forwarder’s IP | pass, aligned | pass | It arrives thanks to DKIM. |
| List that changes the subject | pass for the list’s domain, not aligned | fail: the message changed | fail | It only survives if the list rewrites the From or the receiver trusts its ARC seal. |
| Unconfigured platform | pass for its domain, not aligned | pass for its domain, not aligned | fail | Your newsletter ends up in spam or rejected. |
| Look-alike domain | pass | pass | pass for the attacker’s domain | It arrives: DMARC does not protect against domains that resemble yours. |
SPF: the list of authorised servers
SPF (Sender Policy Framework, RFC 7208) is a TXT record in your domain’s DNS that lists which servers may send mail on its behalf. The server receiving a message compares the connecting IP address with that list, using the envelope domain (MAIL FROM). If the IP is authorised, SPF returns pass.
How the receiver evaluates it
- It takes the
MAIL FROMdomain. If the envelope is empty, as it is in bounce notifications, it uses the one from theHELOgreeting. - It looks up a TXT record in that domain starting with
v=spf1. If it finds two, the result is a permanent error. - It walks through the mechanisms from left to right until one matches the IP.
- That mechanism’s qualifier sets the result:
+pass (the default),-fail,~softfail and?neutral.
v=spf1 ip4:203.0.113.10 include:spf.protection.outlook.com include:_spf.mlsend.com ~all
v=spf1Identifies the record. It must come first, and a domain can only have one record like this.ip4:203.0.113.10Authorises one specific IP, for example your invoicing server. It uses no DNS lookups.include:spf.protection.outlook.comAuthorises the servers Microsoft 365 publishes. It costs one lookup, plus any inside it.include:_spf.mlsend.comAuthorises MailerLite, which sends the newsletter.~allEverything else, softfail: not authorised and best treated with suspicion.
| Term | What it authorises | DNS lookup? |
|---|---|---|
ip4: · ip6: | An address or a CIDR range. | No |
a | The IPs the domain points to (A and AAAA records). | Yes |
mx | The IPs of the servers that receive the domain’s mail. | Yes, plus one per MX |
include: | Whatever another domain’s SPF authorises. | Yes, plus those inside |
exists: | Any IP if a name exists, usually built with macros. | Yes |
ptr | IPs whose reverse DNS ends in the domain. The RFC itself advises against it. | Yes |
all | Everything that has not matched before. It always goes last. | No |
redirect= | Uses another domain’s SPF if nothing matches. | Yes |
| Result | Meaning |
|---|---|
pass | The IP is authorised. |
fail | The IP is not authorised and the domain asks for it to be rejected (-all). |
softfail | The IP is not authorised, but the domain only asks for it to be flagged (~all). |
neutral | The domain makes no statement (?all). |
none | The domain publishes no SPF. |
temperror | A temporary DNS failure; a retry may work. |
permerror | The record is broken: two SPF records, bad syntax or more than 10 lookups. |
The ten DNS lookup limit
So that evaluating SPF does not overload DNS, RFC 7208 limits the terms that trigger lookups to ten: include, a, mx, ptr, exists and redirect, including those inside each include. If an evaluation needs more, the result is permerror. It also recommends no more than two void lookups: names that do not exist or return nothing.
It is the mistake I see most often in companies that have been adding suppliers over the years. Each platform asks for its own include and nobody looks at the total. The deceptive part is that mail does not always fail: the receiver stops counting once it finds a match, so messages sent through the first include entries pass and those sent through the last ones return an error.
| Include | Lookups | Comment |
|---|---|---|
_netblocks.mimecast.com | 9 | Mimecast’s global include. The regional one (eu._netblocks.mimecast.com) costs 1. |
email.freshdesk.com | 7 | Almost the whole budget in one go. |
mailgun.org | 5 | The EU region’s eu.mailgun.org costs 2. And it belongs on the sending subdomain. |
icloud.com | 5 | A redirect and three nested include entries. |
zoho.com | 5 | In the European data centre, zoho.eu costs 2. |
mx.ovh.com | 3 | It uses the ptr mechanism. |
_spf.mail.hostinger.com · _spf.odoo.com | 3 | Both nest other include entries. |
spf.protection.outlook.com · _spf.google.com | 1 | Microsoft 365 and Google Workspace publish their ranges directly. |
How to get below ten, from the cleanest option to the most delicate:
- Remove the
includeentries of services you no longer use. It is the most common fix and the easiest. - Replace
aandmxwithip4:andip6:when the addresses are yours and stable. - Do not add the
includeof platforms that align on their own: Mailchimp, Brevo, Acumbamail, SendGrid with Automated Security or Amazon SES use their own envelope, and thatincludeadds nothing to DMARC. - Send marketing from a subdomain (
news.empresa.es) with its own SPF. You also keep the reputation of commercial mail apart from that of your people’s mail. - Use “flattening” services that replace the
includeentries with IPs. They work, but if the supplier changes its ranges and the service does not update in time, your mail fails.
What SPF does not do
SPF does not protect the From the reader sees: it validates the envelope, and an attacker can put their own domain on the envelope and yours on the letter. Nor does it survive forwarding, because the message arrives from the forwarder’s IP, which is not on your list. And it does not sign the content. On its own it achieves little; its value appears when DMARC requires the envelope domain to match the From domain.
The risk of authorising shared infrastructure
When you include a supplier’s SPF, you authorise every IP that supplier publishes, including those its other customers use. In 2024 the BreakSPF study, presented at the NDSS symposium, found 23,916 domains whose SPF authorised shared cloud, proxy and CDN ranges, 23 of them among the thousand most visited sites on the internet, and showed it was possible to send spoofed mail that passed SPF and DMARC. The practical lesson is twofold: review the broad ranges in your SPF, and make DMARC rely on DKIM, which does not depend on the IP.
~all or -all
For years -all was recommended as the “safe” option. With DMARC enforced, the nuance matters: some receivers reject on SPF early in the connection, before reading the message, and a forward that would have passed thanks to DKIM is lost without appearing in your reports. RFC 9989 describes exactly that effect, and Google recommends ~all. My rule of thumb: ~all on domains that send mail with DMARC enforced; -all on domains that send nothing.
DKIM: the signature that travels with the message
DKIM (DomainKeys Identified Mail, RFC 6376) is a cryptographic signature the outbound server adds to every message in the DKIM-Signature header. The receiver looks up the public key in the signing domain’s DNS and checks that the headers and body have not changed since they were signed. Unlike SPF, DKIM survives forwarding, because the signature travels inside the message.
Outbound server · empresa.es
- It calculates a digest (hash) of the body and of the chosen headers:
From,Subject,Date… - It encrypts it with its private key, which never leaves the server.
- It adds
DKIM-Signature: d=empresa.es; s=k2; bh=…; b=…
Recipient’s server
- It reads
d=ands=and looks upk2._domainkey.empresa.esin DNS. - With the public key it decrypts the signature and recalculates the digest.
- If they match,
dkim=passforempresa.es.
| Tag | What it contains |
|---|---|
d= | The signing domain. This is the one that counts for DMARC. |
s= | The selector: the public key lives at <s>._domainkey.<d>. |
a= | The algorithm: rsa-sha256 or ed25519-sha256. rsa-sha1 has been forbidden since RFC 8301. |
h= | The signed headers. From is mandatory. |
bh= · b= | The body digest and the signature. |
c= | Canonicalisation: how much whitespace change it tolerates. relaxed/relaxed is the robust choice. |
t= · x= | When it was signed and when the signature expires. |
l= | How many bytes of the body are signed. Best avoided: it lets content be appended without breaking the signature. |
Keys: length, selectors and rotation
RFC 8301 sets a minimum of 1024 bits for RSA keys and recommends 2048, which is what Google Workspace, SendGrid and Amazon SES generate today. Microsoft 365 still creates 1024-bit keys by default, although it lets you rotate them to 2048. 4096-bit keys do not fit in a single TXT string and some DNS panels truncate them: they add nothing in practice. Ed25519 (RFC 8463) produces short, robust signatures, but some verifiers still do not recognise it, so it is used as a second signature alongside an RSA one.
The selector lets you hold several keys at once: one per supplier, and two per supplier while they rotate. M3AAWG, the industry’s anti-abuse working group, recommends rotating DKIM keys at least every six months. Microsoft 365 publishes selector1 and selector2 precisely to switch from one to the other without touching your DNS.
A detail that confuses many people: DKIM gives no way to list a domain’s selectors. You can only ask for specific names. That is why every checker “guesses” from a list of common selectors, and why the reliable way to find yours is to look at the s= in the DKIM-Signature header of an email you have sent.
What breaks a DKIM signature
- Mailing lists that add a tag to the subject (
[List]) or a footer at the end of the message. - Security gateways that rewrite links or add “external sender” banners before passing the message on.
- Intermediate servers that reformat the message, especially with
simplecanonicalisation. - A badly published key: split across two records, with extra quotes or truncated by the DNS panel.
Signature reuse (DKIM replay)
A valid DKIM signature stays valid as long as the signed parts do not change. Attackers take advantage of this: they get your platform to sign a harmless message and resend it to thousands of recipients, with your domain authenticated. The defences sit on the sender’s side: sign From, To, Subject and Date twice (oversigning) so no extra headers can be added, set a short expiry with x=, and avoid signing content other people can control, such as web forms that send copies to arbitrary addresses.
DMARC: the policy that ties SPF and DKIM together
DMARC (Domain-based Message Authentication, Reporting and Conformance, RFC 9989) is a TXT record at _dmarc.yourdomain that requires SPF or DKIM to validate a domain aligned with the From domain, says what to do with mail that does not manage it and asks receivers for reports. It is the piece that turns SPF and DKIM into real protection against spoofing of the visible sender.
Alignment, where everything is decided
A message passes DMARC if at least one of these two conditions is met:
- SPF returns
passand the envelope domain is aligned with theFromdomain. - DKIM returns
passand the signature’sd=domain is aligned with theFromdomain.
“Aligned” has two modes. In relaxed mode, the default, both domains only need to share the same organisational domain: news.empresa.es and empresa.es are aligned. In strict mode (adkim=s, aspf=s) they must be identical.
From: …@empresa.esMicrosoft 365 with DKIM enabled
- SPF
empresa.es· pass- DKIM
d=empresa.es· pass
DMARC passes both ways
Mailchimp with the domain authenticated
- SPF
mcsv.net· pass, not aligned- DKIM
d=empresa.es· pass
DMARC passes thanks to DKIM
An unconfigured platform
- SPF
platform.com· pass, not aligned- DKIM
d=platform.com· pass, not aligned
DMARC fails even though everything “passes”
The third case is the one that surprises people most in audits: SPF and DKIM show pass in the headers and yet the email fails DMARC. They pass for the platform’s domain, not for yours.
The policy: none, quarantine or reject
| Policy | What you ask for | When to use it |
|---|---|---|
p=none | Nothing: reports only. Failing mail is delivered as if there were no DMARC. | At the start, while you find out who sends with your domain. |
p=quarantine | Treat failing mail as suspicious: usually the spam folder or quarantine. | Once your legitimate sources pass aligned. |
p=reject | Reject failing mail during the SMTP connection itself. | On domains that only send automated mail or send nothing; elsewhere, with the nuances of RFC 9989. |
The record’s tags
v=DMARC1; p=quarantine; np=reject; rua=mailto:[email protected]; adkim=r; aspf=r
| Tag | What it does | Default |
|---|---|---|
v | Version. Always DMARC1 and always first. | Required |
p | Policy for the domain. | none if missing and rua is present |
sp | Policy for subdomains that exist. | That of p |
np | Policy for subdomains that do not exist in DNS. New in RFC 9989. | That of sp or p |
adkim · aspf | Relaxed (r) or strict (s) alignment. | r |
rua | Where to send aggregate reports. | No reports |
ruf | Where to send individual failure reports. | No reports |
fo | When to generate failure reports: 0, 1, d or s. | 0 |
t | Test mode: with y, the receiver applies one level less. New in RFC 9989. | n |
psd | States whether the domain is a public suffix. Only for registries and top-level domain operators. | u |
Reports: your map of who sends with your domain
With rua, the large receivers send you a daily aggregate report in XML, usually compressed. It does not include the content of the emails: it says which IPs sent messages with your domain, how many, what SPF and DKIM returned and what the receiver did. It is the only reliable way to discover the survey platform someone in marketing signed up for two years ago.
Failure reports (ruf) contain data from specific messages. For privacy reasons most large providers do not send them, so do not count on them.
If reports go to another domain, for example a specialist service, that domain has to authorise it by publishing empresa.es._report._dmarc.service.com with v=DMARC1 (RFC 9990). Services do this on their own; if you set up your own mailbox on another domain, it is a step that often gets forgotten. You can read your XML files without uploading them anywhere in the tool’s reports tab.
Subdomains and the organisational domain
If an email uses facturas.empresa.es and that subdomain has no DMARC record of its own, the receiver climbs the DNS tree until it finds the organisational domain’s record and applies its sp tag, or np if the subdomain does not even exist. RFC 9989 replaced the public suffix list used before with a DNS tree walk, capped at eight lookups:
a.facturas.empresa.es_dmarc.a.facturas.empresa.esno record_dmarc.facturas.empresa.esno record_dmarc.empresa.esrecord found: organisational domain_dmarc.esno record
The np=reject tag is one of the best investments you can make: it stops anyone inventing security-support.empresa.es to impersonate you, without affecting any real subdomain.
Do you always have to reach p=reject?
Most guides take it for granted. RFC 9989 is more nuanced. It asks you to spend at least a month at p=none and as long again at p=quarantine before rejecting; it requires anyone publishing p=reject to sign with DKIM, because SPF does not survive forwarding; and it advises against p=reject on domains whose users post to mailing lists, because their messages bounce at subscribers and the list ends up unsubscribing them. It also asks receivers not to reject on the policy alone.
The large mailbox providers are a good gauge. This is how their own records stood on 29 September 2026:
| Domain | Policy |
|---|---|
gmail.com | p=none; sp=quarantine |
outlook.com | p=none; sp=quarantine |
icloud.com | p=quarantine; sp=quarantine |
proton.me | p=quarantine, with strict alignment |
yahoo.com | p=reject |
My practical recommendation: p=reject for domains and subdomains that only send automated mail (invoices, notifications, marketing) and for those that send nothing; p=quarantine as a sensible target for the main domain when staff take part in external mailing lists, unless you accept that cost in exchange for the extra protection.
What DMARC does not protect
- Look-alike domains:
empresa-es.comorernpresa.esbelong to someone else, who can authenticate them perfectly well. They are countered by monitoring domain registrations, with BIMI and with training. - The display name: “Empresa <[email protected]>” passes DMARC for
gmail.com. - Compromised accounts: if someone’s mailbox at your company is stolen, their emails pass DMARC, because technically they are legitimate.
- The content: DMARC tells you who is sending, not whether the message can be trusted.
What DMARCbis (RFC 9989) changes
In May 2026 the IETF published RFC 9989, known for years as DMARCbis, together with RFC 9990 (aggregate reports) and RFC 9991 (failure reports). They replace RFC 7489, from 2015, and make DMARC an IETF standard. Your v=DMARC1 record keeps working; these are the changes that matter:
| Aspect | RFC 7489 (2015) | RFC 9989 (2026) |
|---|---|---|
| Status | Informational, outside the standards process | IETF Proposed Standard |
| Organisational domain | Public Suffix List | DNS tree walk, up to eight lookups |
| Applying to a percentage | pct=0 to 100 | Removed; replaced by t=y |
| Non-existent subdomains | No policy of their own | np= |
| Public suffixes | RFC 9091, experimental | psd= |
| Reports | In the same RFC; rf= and ri= | RFC 9990 and 9991; rf, ri and the size limit in rua are gone |
| p=reject | No nuances | Requires DKIM and is discouraged on domains with users on mailing lists |
| Receivers | Apply the policy | Do not reject on p=reject alone; without further analysis, treat it as quarantine |
What is worth doing: remove pct (at 100 it is harmless; with any other value each receiver interprets it in its own way), add np=reject and, if you publish records on subdomains with complex structures, check that the DNS walk finds the organisational domain you expect.
ARC: the chain of custody for forwarded mail, and its successor
ARC (Authenticated Received Chain, RFC 8617) lets an intermediary (a mailing list, a forwarder, a gateway) vouch for the authentication results the message had when it reached them. The final receiver can then accept an email that fails DMARC because of the intermediary, if it trusts whoever sealed it.
Each intermediary adds a set of three headers numbered with i=:
ARC-Authentication-Results: what it checked on receipt (SPF, DKIM, DMARC).ARC-Message-Signature: a signature of the message as it is being forwarded, similar to DKIM.ARC-Seal: a signature over the chain, withcv=stating whether the previous chain was valid (noneon the first link).
- empresa.esDKIM signature
- lists.example.orgchecks: dkim=pass, dmarc=pass · changes the subject · seals
i=1,cv=none - GmailDKIM no longer matches · DMARC fails · validates the ARC chain and trusts the list · delivers
Gmail, Microsoft 365 and Yahoo use ARC. In Microsoft 365 you can declare your gateways or third-party services as trusted ARC sealers, and compauth reason code 130 in the headers shows that a trusted ARC seal overrode a DMARC failure.
The experiment is coming to an end, though. In April 2026 the IETF DMARC working group published a draft proposing to reclassify RFC 8617 as Historic, because ARC never achieved a useful trust model between strangers. Its successor is DKIM2, being developed in the IETF DKIM working group (draft draft-ietf-dkim-dkim2-spec): every server that handles the message adds its signature, forming a verifiable chain of who handled it. Until DKIM2 is deployed, ARC will keep working at the large providers; if you run a mailing list, a forwarder or a gateway, keep sealing.
BIMI: your logo in the inbox
BIMI (Brand Indicators for Message Identification) is a TXT record at default._bimi.yourdomain that points to your logo in SVG format and, optionally, to a certificate proving the brand is yours. Compatible mailboxes show the logo next to your emails, but only if the message passes DMARC and your policy is enforced. BIMI is not an RFC: it is an IETF draft driven by the BIMI Group.
With BIMI and a VMC certificate, Gmail shows the logo and a verification tick. An impersonator cannot get either.
Requirements
- DMARC enforced on the domain and its subdomains:
p=quarantineorp=reject, withoutsp=noneand, if you still use it, withpct=100. - The logo in SVG Tiny Portable/Secure (SVG Tiny PS): square, with
baseProfile="tiny-ps", with a<title>element, no scripts, no embedded images or external links, served over HTTPS. The BIMI Group recommends keeping it under 32 KB. - For Gmail and Apple Mail, a certificate: a VMC (Verified Mark Certificate), which requires a registered trademark, or a CMC (Common Mark Certificate), which requires the logo to have been in public use for at least 12 months.
- The record:
default._bimi.empresa.es TXT "v=BIMI1; l=https://empresa.es/bimi/logo.svg; a=https://empresa.es/bimi/vmc.pem"
| Mailbox | Shows BIMI | Certificate |
|---|---|---|
| Gmail and Google Workspace | Yes | VMC (with the blue verification tick) or CMC (without it) |
| Apple Mail and iCloud | Yes, since iOS 16 and macOS Ventura | VMC only |
| Yahoo and AOL | Yes | Not required if the sender has a good reputation |
| Fastmail, Zoho Mail, La Poste, GMX and Web.de | Yes, with caveats | It varies; Fastmail does not require one |
| Outlook, Hotmail and Microsoft 365 | No | — |
Apple also offers its own system, Branded Mail, inside Apple Business Connect: it uses neither BIMI nor certificates and only affects mail read on Apple devices. Is BIMI worth it? If your brand sends a lot of email to consumers and you already have DMARC enforced, yes: it strengthens recognition and makes imitation harder. If your DMARC is still at p=none, the right order is the other way round.
Encryption in transit: STARTTLS, MTA-STS, TLS-RPT and DANE
SPF, DKIM and DMARC tell you who is sending. Encryption makes sure nobody reads or alters the message between servers. Between MTAs, encryption is negotiated with STARTTLS, which is opportunistic: if an attacker in the middle strips the 250-STARTTLS announcement, the servers carry on talking in plain text without warning anyone. Three mechanisms close that gap:
| Mechanism | What it does | What you publish |
|---|---|---|
| MTA-STS (RFC 8461) | Requires servers sending you mail to use TLS with a valid certificate for your MX hosts. | A TXT record at _mta-sts and a policy file at https://mta-sts.yourdomain/.well-known/mta-sts.txt. |
| TLS-RPT (RFC 8460) | Sends you daily reports of encrypted delivery failures. | A TXT record at _smtp._tls with v=TLSRPTv1; rua=mailto:…. |
| DANE (RFC 7672) | Publishes your MX certificates’ fingerprints in DNS; the sender checks them with DNSSEC. | TLSA records at _25._tcp.your-mx, with the zone signed with DNSSEC. |
Gmail validates MTA-STS when sending. Exchange Online has validated DANE when sending since 2022 and has supported it for inbound mail since October 2024, although it has to be switched on explicitly. Always start with MTA-STS in testing mode plus TLS-RPT, and move to enforce once the reports are clean.
What Gmail, Yahoo and Microsoft require
Until 2024, authenticating email was good practice. Since then, the large mailbox providers have required it, and since 2025 they have enforced it with rejections.
| Mailbox | Who | What it requires | Since |
|---|---|---|---|
| Gmail | All senders | SPF or DKIM, valid forward and reverse DNS, TLS, RFC 5322 formatting, spam rate below 0.3%, no impersonation of Gmail headers. | February 2024 |
| Gmail | More than 5,000 a day to personal accounts | SPF and DKIM, aligned DMARC (p=none is enough), one-click unsubscribe (RFC 8058) on commercial mail. | February 2024; 5xx rejections since November 2025 |
| Yahoo and AOL | Bulk senders | SPF and DKIM, aligned DMARC at p=none or stricter, one-click unsubscribe honoured within two days, spam rate below 0.3%. | February 2024 |
| Outlook.com and Hotmail | More than 5,000 a day | Passing SPF and DKIM, and aligned DMARC at p=none or stricter. | 5 May 2025, with the rejection “550 5.7.515” |
The 5,000 threshold is counted per From domain and across everything you send, not per campaign. And once you cross it, Google treats you as a bulk sender permanently.
Provider by provider: what the documentation leaves out
These notes come from setting up and reviewing these services. The tool generates the exact records for each combination.
Microsoft 365
- DKIM is not switched on by itself for your domains. Until you do it, Microsoft signs with
yourdomain.onmicrosoft.com, which is not aligned: DMARC relies on SPF alone and fails as soon as someone forwards an email. - Since May 2025, new domains get CNAME records ending in
.dkim.mail.microsoft; older ones still point to.onmicrosoft.com. Always copy them from the portal or fromGet-DkimSigningConfig. - The default key is 1024 bits.
Rotate-DkimSigningConfig -KeySize 2048raises it to 2048; the change takes four days to apply. - If your MX records point to a gateway (Mimecast, Proofpoint…), turn on Enhanced Filtering for Connectors. Without it, Microsoft sees the gateway’s IP and SPF fails on all your inbound mail.
- Since September 2025 you can reject unauthorised Direct Send with
Set-OrganizationConfig -RejectDirectSend $true, a route used in phishing campaigns against Microsoft 365 users.
Google Workspace
- Without its own key, Gmail signs with a technical domain like
yourdomain-com.<date>.gappssmtp.com, which does not align. Generate the key in Apps › Google Workspace › Gmail › Authenticate email and click “Start authentication”. - If your DNS provider does not accept long TXT records, split the 2048-bit key into several strings within the same record rather than dropping to 1024.
_spf.google.comnow publishes its ranges directly: it costs a single lookup.
Hosting companies and control panels (IONOS, OVHcloud, Arsys, Dinahosting, cPanel, Plesk)
- If the hosting company manages your DNS, enabling DKIM from its panel usually publishes the record automatically. If your DNS is elsewhere, you have to copy the records yourself, and that is where they get left half done.
- The SPF that cPanel-style panels suggest is usually
a mxplus an IP or two. Replacingaandmxwith the real IPs saves lookups and avoids authorising too much. - WordPress forms send through the server’s
mail()function, with the server’s own envelope: it is the most common source of unaligned mail in small businesses. Set up sending through authenticated SMTP. - OVHcloud’s
includeusesptr, which is discouraged, and ends in?all; IONOS’s also ends in?all. It does not affect your result, which your ownalldecides, but it is worth knowing when you read the tree.
Marketing platforms (Mailchimp, Brevo, Acumbamail, MailerLite…)
- Almost all of them use their own domain on the envelope, so SPF never aligns with yours and DMARC passes through DKIM alone. That is why authenticating the domain in the platform, with its CNAME records, is essential, and why adding its
includeto your SPF is often pointless. - When you authenticate the domain automatically, Brevo may offer to replace your DMARC record with its own. If you already have one with your own report destinations, do it manually.
- My advice: send marketing from a subdomain (
news.empresa.es). You keep the reputations apart and can take that subdomain top=rejectwithout affecting your people’s mail.
Transactional email (SendGrid, Amazon SES, Mailgun, Postmark)
- SendGrid with Automated Security gives you three CNAME records: one turns a subdomain of yours into the envelope (
em1234.empresa.es) and aligns SPF. Do not also addinclude:sendgrid.netto your root SPF. - Amazon SES uses its own envelope by default (
amazonses.com). Puttinginclude:amazonses.comon your root domain is a common mistake that aligns nothing; what aligns SPF is setting up a custom MAIL FROM domain on a subdomain. - Mailgun recommends a sending subdomain (
mg.empresa.es) with its own SPF. In the European region the include iseu.mailgun.org, which costs 2 lookups against 5 for the global one. - Postmark aligns SPF with a
pm-bouncesCNAME; without it, DMARC depends on DKIM alone.
CRM, support desks and gateways
- HubSpot gives you an
includespecific to your account and two DKIM CNAME records (hs1-…,hs2-…): copy them exactly. include:email.freshdesk.comuses 7 of your 10 lookups. If you use Freshdesk alongside Microsoft 365 and one more platform, you will go over the limit.- With Mimecast, use your region’s include (
eu._netblocks.mimecast.com, one lookup) rather than the global one (nine).
The mistakes I see most
- Two SPF records. Each supplier asked you to “add a TXT record” and two were added. The result is
permerror: they need merging into one. - SPF over ten lookups. It works some of the time, which is worse than not working. Measure the whole tree, not just your record.
- DKIM published but not enabled. The CNAME records are in DNS, but nobody clicked “Enable” in Microsoft 365 or “Start authentication” in Google Workspace.
- DKIM CNAME records behind the Cloudflare proxy. The name stops returning the key. Mail records should always be “DNS only”.
- The domain repeated. The panel appends the domain and the record ends up at
_dmarc.empresa.es.empresa.es. Always check from the outside. ruawithoutmailto:or with commas where semicolons belong. The record stops working or you lose the reports.- Reports sent to another domain without authorisation. The
_report._dmarcrecord is missing and receivers send you nothing. p=rejecton day one. The invoices sent from the ERP and the newsletter nobody had authenticated are lost.p=noneforever. You receive reports nobody reads and the domain can still be spoofed.- A forgotten
sp=none. The main domain is protected, but anyone can usefacturas.empresa.es. - Unprotected secondary domains. The
.com, the old company name or a campaign domain send no mail, but anyone can send with them. - 1024-bit keys not rotated for years. They work, but they are below the recommendation and nobody knows any more who holds the private key.
Domains that do not send email
Every domain you register is a domain someone can use to impersonate you. If it does not send email, tell the world with these records:
empresa-antigua.es. TXT "v=spf1 -all"
_dmarc.empresa-antigua.es. TXT "v=DMARC1; p=reject; sp=reject; np=reject"
*._domainkey.empresa-antigua.es. TXT "v=DKIM1; p="
empresa-antigua.es. MX 0 .
The last record, the null MX, says the domain does not receive mail either. If it does, remove that line and keep the other three.
A rollout plan that loses no mail
- Week 0Inventory
List everything that sends with your domain: mailboxes, ERP, CRM, marketing, support, invoicing, web forms, printers and system alerts.
- Week 0SPF and DKIM
A single SPF record under ten lookups. DKIM enabled in every service, signing with your domain.
- Week 1DMARC in monitoring mode
v=DMARC1; p=none; rua=mailto:[email protected]. Reports start arriving. - Weeks 1 to 5Read and fix
Every legitimate source that does not pass aligned is configured or moved to a subdomain. Anything you do not recognise is spoofing.
- Week 5Quarantine
p=quarantine; np=reject. Compare the reports with the previous phase for at least four weeks. - Week 9Reject, where it makes sense
p=rejecton domains and subdomains that only send automated mail. Consider the mailing list case before doing it on the main domain. - AlwaysMaintain
Every new supplier goes through SPF, DKIM and the reports before it sends. Rotate DKIM keys at least every six months.
Tick what you already have. The list resets on reload and your answers are not sent.
Would you rather we go through it together?
I review your setup with your real suppliers, go through the DMARC reports with you and support the move to quarantine and reject without losing legitimate mail.
Let’s talk about your domain →Frequently asked questions
What is the difference between SPF, DKIM and DMARC?
SPF publishes which servers may send with your domain and is checked against the envelope domain (Return-Path). DKIM signs every message and the receiver verifies the signature with a public key published in your DNS. DMARC requires at least one of the two to validate the same domain that appears in the From, says what to do with anything that fails and sends you reports.
Do I need all three?
Yes. SPF and DKIM authenticate, but neither of them protects the sender the reader sees on its own; DMARC does that by requiring alignment. In addition, Gmail, Yahoo and Outlook.com require all three from anyone sending more than 5,000 emails a day.
Can I have two SPF records?
No. If a domain publishes two records starting with v=spf1, the result is permerror and SPF stops working. They have to be merged into a single record with all the mechanisms.
How many DNS lookups can an SPF record have?
Ten. The include, a, mx, ptr and exists mechanisms and the redirect modifier count, including those inside each include. If an evaluation needs more, the result is permerror. RFC 7208 also recommends no more than two void lookups.
Why does DMARC fail if SPF and DKIM pass?
Because they pass for another domain. An unconfigured sending platform authenticates with its own domain on the envelope and in the signature; DMARC requires one of the two to match the From domain. The fix is to authenticate your domain in the platform so it signs DKIM with it.
Do I have to reach p=reject?
Not always. RFC 9989 asks you to go through p=none and p=quarantine for at least a month each, requires anyone publishing reject to sign with DKIM, and advises against p=reject on domains whose users post to mailing lists. For domains that only send automated mail or send nothing, reject is the right choice.
Is it better to end SPF with ~all or -all?
With DMARC enforced, ~all is what Google recommends, and RFC 9989 warns that with -all some receivers reject on SPF before looking at DMARC, so forwards that DKIM would have saved are lost. On domains that send no email, -all.
How often do DMARC reports arrive?
The large receivers usually send one aggregate report a day per domain, as compressed XML. It includes the IPs that sent with your domain, how many messages and the SPF, DKIM and DMARC results, without the content of the emails.
What is BIMI and what do I need to use it?
BIMI shows your brand’s logo next to your emails. You need DMARC at quarantine or reject, the logo in SVG Tiny PS and, for Gmail and Apple Mail, a certificate: a VMC, which requires a registered trademark, or a CMC, which requires 12 months of public use of the logo. Apple only accepts VMCs and Outlook does not display BIMI.
Is ARC going away?
In April 2026 the IETF proposed reclassifying ARC (RFC 8617) as Historic and is working on DKIM2 as its successor. In the meantime, Gmail, Microsoft 365 and Yahoo still validate ARC chains, so mailing lists, forwarders and gateways should keep sealing.
Does DMARC protect me from domains that look like mine?
No. A domain such as empresa-es.com belongs to someone else, who can authenticate it correctly. DMARC only protects the use of your own domain. Monitoring domain registrations, BIMI and training help against look-alike domains.
What changes with DMARCbis (RFC 9989)?
Published in May 2026, it makes DMARC an IETF standard, replaces the Public Suffix List with a DNS tree walk, removes pct, rf and ri, adds np, t and psd, and moves reporting to RFC 9990 and 9991. Existing v=DMARC1 records keep working.
Glossary
- Alignment
- A match between the From domain and the domain validated by SPF (the envelope one) or by DKIM (the signature’s d=). In relaxed mode, sharing the organisational domain is enough; in strict mode they must be identical.
- ARC
- Authenticated Received Chain (RFC 8617). A chain of seals added by intermediaries to vouch for the authentication results a message had when it reached them. In 2026 the IETF proposes declaring it Historic.
- BIMI
- Brand Indicators for Message Identification. A TXT record at default._bimi pointing to an SVG logo and a certificate; compatible mailboxes display it if the email passes DMARC with an enforced policy.
- CMC
- Common Mark Certificate. A BIMI certificate that requires 12 months of public use of the logo rather than a registered trademark. Gmail accepts it without showing the verification tick; Apple does not accept it.
- compauth
- Composite authentication result that Microsoft 365 adds to the headers, with a three-digit reason code (for example 000 for an explicit DMARC failure or 130 for a trusted ARC seal).
- DANE
- DNS-based Authentication of Named Entities (RFC 7672 for SMTP). Publishes a mail server’s certificate fingerprint in TLSA records, validated with DNSSEC.
- DKIM
- DomainKeys Identified Mail (RFC 6376). A cryptographic signature the outbound server adds to every message and the receiver verifies with the public key published in DNS.
- DKIM selector
- A name identifying a specific DKIM key; the public key is published at <selector>._domainkey.<domain>.
- DKIM2
- The successor to DKIM and ARC under development at the IETF: every server that handles the message adds its signature, forming a verifiable chain of custody.
- DMARC
- Domain-based Message Authentication, Reporting and Conformance (RFC 9989). A policy published at _dmarc that requires SPF or DKIM alignment with the From, says what to do with failures and requests reports.
- DMARCbis
- The working name for the revision of DMARC published in May 2026 as RFC 9989, 9990 and 9991.
- DNSSEC
- DNS security extensions that sign responses so they cannot be forged. A prerequisite for DANE.
- HELO / EHLO
- The greeting a server uses to identify itself when it opens an SMTP conversation.
- MAIL FROM
- The SMTP envelope address (RFC 5321) that bounces return to. It is recorded as Return-Path and is the one SPF checks.
- MDA
- Mail Delivery Agent. The program that places the message in the mailbox and applies filters.
- MSA
- Mail Submission Agent. The server that accepts mail from authenticated users, usually on port 587 or 465.
- MTA
- Mail Transfer Agent. A server that transfers mail between domains using SMTP.
- MTA-STS
- A mechanism (RFC 8461) by which a domain requires the mail it receives to arrive over TLS with a valid certificate.
- MUA
- Mail User Agent. The program a person uses to read and write email: Outlook, Gmail, Apple Mail, Thunderbird.
- MX
- A DNS record stating which servers receive a domain’s mail and with what preference.
- Null MX
- An MX record with the value “0 .” (RFC 7505) declaring that a domain does not accept mail.
- Organisational domain
- The domain DMARC uses for relaxed alignment and for policy inheritance. RFC 9989 determines it with a DNS tree walk instead of the Public Suffix List.
- Oversigning
- Signing a header with DKIM more times than it appears in the message, so nobody can add another copy without breaking the signature.
- PTR
- A reverse DNS record mapping an IP address to a name. Gmail and Yahoo require valid reverse DNS for the IPs that send them mail.
- Return-Path
- A header the receiving server adds with the MAIL FROM address.
- rua / ruf
- DMARC tags stating where to send aggregate reports (rua) and failure reports (ruf).
- SMTP
- Simple Mail Transfer Protocol (RFC 5321). The protocol used to send and transfer email.
- SPF
- Sender Policy Framework (RFC 7208). A TXT record listing the servers authorised to send email with a domain.
- STARTTLS
- An SMTP command that upgrades an unencrypted connection to one encrypted with TLS. On its own it is opportunistic and can be stripped by a man-in-the-middle attack.
- SVG Tiny PS
- A restricted SVG profile that BIMI requires for logos: no scripts and no external resources.
- TLS-RPT
- A mechanism (RFC 8460) by which a domain asks for reports on encrypted delivery failures.
- VMC
- Verified Mark Certificate. A BIMI certificate proving a registered trademark. With it Gmail shows a verification tick, and Apple Mail requires it.
Sources
Documentation checked on 29 September 2026. SPF lookup counts and the large mailbox providers’ DMARC policies were measured on the same day with public DNS queries.
IETF standardsRFC 5321 (SMTP) · RFC 5322 (message format) · RFC 6409 (submission) · RFC 8314 · RFC 7208 (SPF) · RFC 6376 (DKIM) · RFC 8301 · RFC 8463 (Ed25519) · RFC 9989 (DMARC) · RFC 9990 · RFC 9991 · RFC 8617 (ARC) · Draft moving ARC to Historic · DKIM2 draft · RFC 7505 (null MX) · RFC 8461 (MTA-STS) · RFC 8460 (TLS-RPT) · RFC 7672 (DANE SMTP) · RFC 8058 (one-click unsubscribe)
ProvidersGmail sender guidelines · Yahoo Sender Hub · Outlook.com requirements for high-volume senders · DKIM in Microsoft 365 · Microsoft 365 anti-spam headers · Reject Direct Send · Inbound DANE in Exchange Online · DKIM in Google Workspace · BIMI in Apple Mail · BIMI Group
Research and good practiceBreakSPF (NDSS 2024) · M3AAWG: DKIM key rotation
The provider notes describe how each service worked on the review date and may change; when in doubt, what the service’s own panel shows takes precedence.