← RFC Reference

DMARC — Domain-based Message Authentication, Reporting and Conformance

Informational Email Authentication AuthenticationPolicy
ELI5: SPF checks the return address on the envelope. DKIM checks the wax seal on the letter. But neither one confirms that the name in the letterhead (the From: address the user sees) matches the verified identity. DMARC is the rule that says: “The name on the letterhead must match either the envelope return address or the wax seal — and if it doesn’t, here’s what to do with the letter.”

Why This RFC Exists

SPF and DKIM are powerful, but each has a critical gap. SPF validates the envelope sender domain, which users never see. DKIM validates whatever domain the signer chose, which may be an ESP's domain rather than the visible sender. Neither one, alone, prevents an attacker from spoofing the From: header that users actually read.

DMARC closes this gap by introducing two concepts:

  1. Identifier alignment: At least one of SPF or DKIM must both pass and have its authenticated domain align with the From: header domain.
  2. Domain owner policy: The domain owner publishes a DNS record declaring what receivers should do when alignment fails: monitor (p=none), quarantine (p=quarantine), or reject (p=reject).

DMARC also defines an aggregate reporting mechanism, allowing domain owners to receive daily XML reports showing how their domain is being used (and abused) across the internet.

How It Works

The DMARC Evaluation Flow

  1. A message arrives with From: user@example.com.
  2. The receiver checks SPF against the envelope sender domain. If SPF passes and the envelope domain matches example.com (or a subdomain, depending on alignment mode), SPF is "aligned."
  3. The receiver checks DKIM. If a valid signature has d=example.com (or a subdomain), DKIM is "aligned."
  4. If at least one of SPF or DKIM is both passing and aligned, DMARC passes.
  5. If DMARC fails, the receiver queries _dmarc.example.com for the policy and applies it.

DMARC DNS Record

_dmarc.example.com. IN TXT "v=DMARC1; p=reject; rua=mailto:dmarc-reports@example.com; ruf=mailto:dmarc-forensic@example.com; adkim=r; aspf=r; pct=100"

Alignment in Practice

# Message arrives:
# Envelope: MAIL FROM:<bounce@mail.example.com>
# Header: From: sales@example.com
# DKIM sig: d=example.com

# SPF check:
SPF domain: mail.example.com (from envelope)
From domain: example.com
SPF alignment (relaxed): mail.example.com <-> example.com = PASS (same org domain)

# DKIM check:
DKIM d= domain: example.com
From domain: example.com
DKIM alignment: example.com <-> example.com = PASS (exact match)

DMARC result: PASS (both SPF and DKIM aligned)

Key Technical Details

Policy Tags

Tag Values Description
v DMARC1 Version (required, must be first)
p none, quarantine, reject Policy for the domain (required)
sp none, quarantine, reject Policy for subdomains (defaults to p)
rua mailto: URI(s) Where to send aggregate reports (comma-separated)
ruf mailto: URI(s) Where to send forensic/failure reports
adkim r (relaxed), s (strict) DKIM alignment mode. Relaxed allows subdomains.
aspf r (relaxed), s (strict) SPF alignment mode. Relaxed allows subdomains.
pct 0–100 Percentage of failing mail to apply policy to (for gradual rollout)
fo 0, 1, d, s Failure reporting options

Alignment Modes

Relaxed alignment (default, adkim=r / aspf=r): The authenticated domain and the From: domain share the same organizational domain. For example, mail.example.com aligns with example.com.

Strict alignment (adkim=s / aspf=s): The authenticated domain must exactly match the From: domain. mail.example.com does not align with example.com.

Aggregate Reports (rua)

Receivers that support DMARC send daily aggregate reports in XML format to the rua address. These reports contain:

These reports are invaluable for discovering unauthorized senders, identifying misconfigured legitimate sources, and building confidence before tightening your policy from none to reject.

External Destination Verification

If your rua or ruf address is at a different domain (e.g., rua=mailto:reports@analytics.com), the receiving domain must publish a DNS record authorizing it:

example.com._report._dmarc.analytics.com. IN TXT "v=DMARC1"

Without this record, report senders will not deliver reports to the external address, as a protection against using DMARC reports as a denial-of-service vector.

Common Mistakes

Deliverability Impact

Related RFCs