Email Authentication Explained: SPF, DKIM and DMARC – Complete Guide for 2026

Email authentication is no longer optional. Major mailbox providers enforce authentication standards at SMTP level, and domains without proper protection remain vulnerable to impersonation attacks. This guide explains SPF, DKIM, and DMARC-how they work individually, how they work together, and how to implement them correctly.

TL;DR

  • Email spoofing is the primary vector for phishing attacks, costing businesses over 3 € billion in 2025 (FBI IC3 data). SPF, DKIM, and DMARC are the three protocols that prevent attackers from impersonating your domain.
  • SPF (Sender Policy Framework) tells receiving mail servers which IP addresses are authorised to send email on behalf of your domain. It is the first line of defence but only covers the envelope sender (Return-Path), not the header “From” address.
  • DKIM (DomainKeys Identified Mail) adds a cryptographic digital signature to each email, allowing recipients to verify that the message has not been tampered with in transit and that it genuinely came from your domain.
  • DMARC (Domain‑based Message Authentication, Reporting & Conformance) connects SPF and DKIM, telling receiving servers what to do when an email fails authentication-monitor, quarantine, or reject. It also provides reporting on who is sending email using your domain.
  • Only 10.7% of domains globally have DMARC enforcement (p=quarantine or p=reject), leaving the vast majority vulnerable to impersonation attacks. Major mailbox providers now reject non‑compliant messages at SMTP level.

Why Email Authentication Matters

What Happens When Someone Spoofs Your Domain

SMTP, the protocol that powers email, was designed in an era when security was not a primary concern. It lacks built‑in authentication, meaning anyone with a mail server can send an email claiming to be from your domain.

The technical distinction is critical:

  • Envelope sender (Return‑Path): The address used by mail servers during delivery. SPF checks this.
  • Header “From”: The address users see in their email client. DMARC checks alignment with this.

Attackers exploit this gap. They send emails with a legitimate‑looking header From address while using a different Return‑Path. Without proper authentication, receiving servers cannot tell the difference.

Attacker → SMTP server → email with spoofed From: yourdomain.com

Business Impact

ImpactDetail
Financial lossesBEC scams accounted for 3.046 € billion in reported losses in 2025** across 24,768 incidents-an average of **123,000 € per case. AI‑assisted BEC scams cost businesses over 30 € million in 2025 alone.
Brand reputation damageWhen customers receive spoofed emails that appear to come from you, your brand’s trustworthiness suffers.
Customer trust erosionPhishing attacks using your domain erode the trust you have built with your customers and partners.
Deliverability problemsWithout proper authentication, your legitimate emails are more likely to be flagged as spam or rejected outright.

The Three Protocols Overview

ProtocolWhat It DoesHow It Works
SPFAuthorises sending IPsDNS TXT record listing IP addresses
DKIMCryptographic signingDNS TXT record with public key
DMARCPolicy enforcementDNS TXT record with policy and reporting

SPF: Sender Policy Framework

What SPF Proves

SPF tells receiving mail servers which IP addresses are authorised to send email on behalf of your domain. When a server receives an email, it checks the Return‑Path domain against the SPF record published in DNS.

What SPF Does Not Prove

  • The header “From” address (the one users see)
  • SPF does not prevent display name spoofing
  • SPF breaks with email forwarding

SPF Record Syntax

v=spf1 ip4:192.0.2.0/24 include:_spf.google.com ~all
ComponentMeaning
v=spf1Version identifier
ip4:192.0.2.0/24Authorised IPv4 range
include:_spf.google.comInclude Google’s SPF record
~allSoft fail (other sending is not explicitly authorised)

SPF Mechanisms

MechanismMeaningRecommendation
+ (pass)Explicitly authorisedDefault
? (neutral)No statementAvoid
~ (soft fail)Not authorised but acceptRecommended initial setting
- (hard fail)Not authorised, rejectFinal setting after verification

SPF Limitations

  • 10 DNS lookup limit – exceeding this causes permanent SPF failure
  • Only checks the envelope sender, not the header From
  • Breaks with email forwarding – forwarding breaks SPF because the Return‑Path changes

DKIM: DomainKeys Identified Mail

How Cryptographic Signing Works

DKIM adds a digital signature to each outgoing email. The sending server signs the email using a private key, and the receiving server retrieves the corresponding public key from DNS to verify the signature.

How DKIM cryptographic signing works. The sender signs the email with a private key, the recipient retrieves the public key from DNS, and uses it to verify the signature.

DKIM Record Syntax

v=DKIM1; k=rsa; p=MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQC...
ComponentMeaning
v=DKIM1Version
k=rsaKey type (RSA)
p=...Public key (base64 encoded)

DKIM Headers in Email

DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=example.com;
 s=selector1; t=1690000000; bh=...; h=from:to:subject;
 b=...
Header FieldMeaning
v=1DKIM version
a=rsa-sha256Signing algorithm
d=example.comSigning domain
s=selector1Selector (points to DNS record)
bh=Body hash
h=Headers included in signature
b=Digital signature

DKIM Benefits

  • Proves message integrity – confirms the email was not tampered with in transit
  • Works through forwarding – the signature travels with the email
  • Strong cryptographic verification – uses public‑key cryptography

DMARC: Domain‑based Message Authentication, Reporting & Conformance

How DMARC Connects SPF and DKIM

DMARC verifies that either SPF or DKIM passes and that the domain in the header From aligns with the domain in the authenticated identifier.

Alignment requirements:

  • SPF alignment: The domain in the Return‑Path must match the domain in the header From.
  • DKIM alignment: The domain in the DKIM signature (d=) must match the domain in the header From.

DMARC Policy Options

PolicyEffectRisk
p=noneMonitor only – reports sent, no actionNo protection, only visibility
p=quarantineFlag suspicious emails (spam folder)Some protection, limited enforcement
p=rejectBlock all unauthenticated emailsFull protection, risk of blocking legitimate email if misconfigured

DMARC Record Syntax

v=DMARC1; p=reject; rua=mailto:dmarc-reports@example.com; ruf=mailto:dmarc-forensic@example.com; pct=100
FieldMeaning
v=DMARC1Version
p=rejectPolicy (none/quarantine/reject)
rua=mailto:...Aggregate report destination
ruf=mailto:...Forensic report destination
pct=100Percentage of messages subject to the policy

SPF and DKIM Alignment Requirements

SPF and DKIM must pass and align for DMARC authentication. If at least one passes, the receiving server applies the configured DMARC policy: none, quarantine, or reject.

How SPF, DKIM and DMARC Work Together

The Complete Email Authentication Flow

The complete email authentication flow. SPF and DKIM checks are followed by DMARC alignment, which determines whether authentication passes or the configured DMARC policy is applied.

Real‑World Example

ScenarioSPFDKIMDMARCResult
Legitimate email from your serverPassPassPassDelivered
Spoofed email from unauthorised serverFailFailFailBlocked (with p=reject)
Forwarded email (SPF fails, DKIM passes)FailPassPass (if DKIM aligns)Delivered

Common Configuration Mistakes

MistakeWhy It’s a ProblemFix
SPF includes too many lookupsExceeds 10 DNS lookup limit; SPF will permanently failConsolidate includes, use flattening services
Using ~all (softfail) instead of -allGives attackers a way to still passUse -all once fully implemented
Missing alignment (DMARC)SPF/DKIM pass but don’t align with header FromConfigure both to use the same domain
DMARC p=none indefinitelyNo enforcement – attackers still succeedMove to p=quarantine then p=reject
Not using subdomain policiesAttackers can spoof subdomainsSet sp=reject for subdomains
Not monitoring reportsNo visibility into who is sending using your domainSet up RUA and RUF reporting

Provider Enforcement Requirements (2026)

In February 2024, Google and Yahoo introduced mandatory authentication standards for bulk email senders (over 5,000 messages per day). Microsoft followed in early 2025. In late 2025, Gmail began strict SMTP‑level enforcement.

In 2026, non‑compliant messages are rejected at SMTP level.

This affects:

  • Marketing campaign deliverability
  • Transactional email reliability
  • CRM and automation email workflows
  • Third‑party sending tools (HubSpot, Salesforce, Mailchimp, etc.)

Practical Implementation Checklist

Phase 1: SPF

  • Create SPF record listing all authorised sending sources
  • Include all email marketing, transactional, and business email services
  • Test with ~all first, then move to -all

Phase 2: DKIM

  • Generate DKIM key pair for each sending domain
  • Publish public key in DNS
  • Configure email servers to sign outgoing emails
  • Test with multiple selectors for rotation

Phase 3: DMARC

  • Start with p=none to collect data
  • Monitor aggregate reports for 30‑60 days
  • Identify all legitimate sending sources
  • Move to p=quarantine after verifying all legitimate sources are authenticated
  • Move to p=reject after 90+ days of no issues
  • Set pct=100 and configure sp=reject for subdomains

Phase 4: Ongoing

  • Monitor DMARC reports monthly
  • Rotate DKIM keys periodically
  • Update SPF records when adding new sending services
  • Review and update policies as your email infrastructure evolves

How to Test Whether Your Domain Is Protected

Online Tools

ToolPurpose
MXToolboxSPF, DKIM, DMARC record lookup
dmarcian DMARC CheckComplete DMARC validation
Google Admin ToolboxEmail header analyser
DMARC AnalyzerMonitor DMARC reports

Testing Commands

# Check SPF
dig TXT example.com | grep spf
# Check DKIM
dig TXT selector1._domainkey.example.com
# Check DMARC
dig TXT _dmarc.example.com

Email Header Inspection

Authentication-Results: spf=pass smtp.mailfrom=example.com;
 dkim=pass header.d=example.com;
 dmarc=pass header.from=example.com

What “Pass” Looks Like

SPF: pass
DKIM: pass
DMARC: pass (header.from matches authenticated domain)

What BIMI Adds After DMARC

BIMI (Brand Indicators for Message Identification) displays brand logos in supported email clients (Gmail, Yahoo, Apple Mail).

Requirements:

  • DMARC enforcement (p=quarantine or p=reject)
  • Verified logo (SVG format)
  • Verified Mark Certificate (VMC) for some providers

Implementation:

default._bimi.example.com TXT
"v=BIMI1; l=https://example.com/logo.svg; a=https://example.com/vmc.pem"

BIMI builds on DMARC and provides visual verification for recipients, adding a layer of brand trust and recognition.

Key Takeaways

  • Email authentication is no longer optional. Major mailbox providers (Google, Yahoo, Microsoft) enforce DMARC for bulk senders, rejecting non‑compliant messages at SMTP level.
  • SPF, DKIM and DMARC work together as a system. SPF authorises sending IPs, DKIM provides cryptographic signing, and DMARC connects them with enforcement policies.
  • Only 10.7% of domains have DMARC enforcement (p=reject or p=quarantine). The vast majority remain vulnerable to spoofing and impersonation attacks.
  • Start with DMARC p=none to collect data. Monitor for 30‑60 days before moving to enforcement. Identify all legitimate sending sources first.
  • Use p=reject for full protection. Once properly configured, DMARC p=reject blocks all unauthenticated emails, preventing spoofing entirely.
  • BIMI builds on DMARC to display brand logos in supported email clients, adding visual trust signals for recipients.

Conclusion

Email authentication through SPF, DKIM, and DMARC is a business necessity in 2026. The threat landscape has shifted-major mailbox providers enforce authentication standards, and non‑compliant messages are rejected before they reach recipients.

The three protocols work together as a system. SPF tells receiving servers which IPs are authorised to send. DKIM provides cryptographic verification that a message has not been tampered with. DMARC connects them, defines enforcement policies, and provides reporting on who is sending email using your domain.

Implementation follows a clear progression: start with SPF, add DKIM, then deploy DMARC in monitoring mode. After verifying all legitimate sending sources, move to enforcement with p=quarantine, then p=reject. BIMI can then be added for visual brand recognition.

The cost of non‑compliance is significant: BEC losses approach 3 € billion annually, and domains without protection remain vulnerable to impersonation attacks. By implementing SPF, DKIM, and DMARC, you protect your brand, your customers, and your business.

Resources

Need help setting up email authentication for your domain? Playful Sparkle has been engineering digital products since 2004, offering Web Development, App Development, and security consulting services. Our team can help you configure SPF, DKIM, DMARC, and BIMI for your domain. Contact us to discuss how we can help you secure your email.

Was this helpful - Post
Zsolt Oroszlány

Zsolt Oroszlány

Founder & Chief Creative Officer of Playful Sparkle since 2004, combining business leadership, digital strategy, design, and software engineering to help organizations build effective digital solutions. Regularly publishes insights on web development, SEO, design, and emerging technologies.