Skip to content

Help center

How to set up DMARC for your domain, step by step

Publish a DMARC record safely: start at p=none with reports, confirm SPF and DKIM align, then move to quarantine and reject without losing legitimate mail.

Updated 2026-11-23

Publish a DMARC record at _dmarc.yourdomain with p=none and a reporting address, read the reports to find every system that sends as your domain, fix its SPF and DKIM, then move the policy to quarantine and finally reject. Skipping the monitoring step is how people block their own mail.

What DMARC does

DMARC (RFC 7489) lets a domain tell receivers what to do when mail claiming to be from it fails authentication, and where to send reports. It passes when mail passes SPF or DKIM and the passing domain aligns with the visible From domain.

Steps

  1. Confirm SPF works. Check it with the SPF checker. See Check an SPF record.
  2. Confirm DKIM signs your mail. Find your selector and check the key. See Find a DKIM selector.
  3. Create a mailbox for reports, for example dmarc-reports@example.com.
  4. Publish the record. Add a TXT record at _dmarc.example.com:
v=DMARC1; p=none; rua=mailto:dmarc-reports@example.com
  1. Verify it. Check it with the DMARC checker, or:
bash
dig +short TXT _dmarc.example.com
  1. Read the aggregate reports for a few weeks. They list who sent mail as your domain and whether it passed. Fix every legitimate sender that fails: add it to SPF or enable DKIM signing for it.
  2. Raise the policy. Move to p=quarantine, optionally with pct=25 to apply it to a share of mail first, and increase pct as reports stay clean.
  3. Finish at p=reject once nothing legitimate fails.

The tags you will use

Tag Meaning
v=DMARC1 Version. Must come first.
p Policy for the domain: none, quarantine or reject.
sp Policy for subdomains. Defaults to p.
pct Percentage of mail the policy applies to.
rua Where aggregate reports go.
adkim, aspf Alignment mode: r relaxed, s strict.

Aggregate reports are XML files from receivers. Use a report reader or a mailbox you can search, since they arrive in volume.

With the API

The API cannot read your record. It reports whether a domain publishes one, as part of an email check:

bash
curl https://api.qelka.com/v1/email \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"email": "jane@example.com", "mode": "fast"}'

Read domain.dmarc: true when a DMARC record (RFC 7489) is published, null when not checked. It costs 1 credit. It does not tell you the policy or whether it is right, so use the free checker for that. See the email reference.

Common mistakes

  • Going straight to p=reject. A forgotten sender then fails silently. Start at none.
  • Two DMARC records. Receivers may ignore both. Keep one.
  • Putting the record on the wrong name. It must be at _dmarc.
  • Forgetting subdomains. Set sp if subdomains send mail.
  • Sending reports to a mailbox nobody reads. Without reports you are guessing.
  • Treating DMARC as a spam filter. It is about who may use your domain, not content.

Frequently asked questions

What should my first DMARC record be?
A monitoring record: v=DMARC1; p=none; rua=mailto:reports@example.com, published as a TXT record at _dmarc.example.com. It asks receivers to change nothing and send you aggregate reports. Read the reports for a few weeks to find every system that sends as your domain before you ask receivers to quarantine or reject failures.
What do the DMARC policies none, quarantine and reject do?
They tell receivers what to do with mail that fails DMARC. None asks for no action and only reporting. Quarantine asks to treat it as suspicious, typically the spam folder. Reject asks to refuse it. Receivers decide for themselves, but most follow the policy. Move up one step at a time.
Do I need SPF and DKIM before DMARC?
Yes. DMARC passes when mail passes SPF or DKIM and the passing domain aligns with the visible From domain. Without a working SPF record or DKIM signing, nothing can pass, and a strict policy would block your own mail. Set up and test at least one of them, preferably both, before you publish the record.

Put this check in your product

Get an API key in under a minute. 100 free credits every month, no card required.

  • 100 free credits a month
  • No card
  • Test keys spend nothing
  • Cancel any time