SPF and DMARC record builder

Build correct SPF and DMARC records for your domain, ready to paste into your DNS. Includes a lock-down set for domains that never send mail.

Safe Runs offline
For
Anyone protecting their domain who can edit its DNS records, or has someone who can.
What you get
Records that fit your services, ready to paste, with the steps that still follow.
Terms
SPF A DNS record that lists which servers may send mail for a domain. The receiver uses it to check whether a message came from an allowed server. DKIM A digital signature on an e-mail. The receiver checks it with a key in the domain’s DNS, and so sees whether the message was changed on the way. DMARC A DNS record that ties SPF and DKIM to the sender address you see. It tells receivers what to do when that doesn’t match: nothing, the spam folder, or reject.
Does this domain send e-mail?
Which services send mail for this domain?

Include everything: your mailbox provider, newsletter tool, web shop and invoicing software.

Mailbox and office

Newsletters, web shop and sending services

Is your service not listed?
  • Search the service’s documentation for "SPF". You need the value after include:, such as _spf.example.net.
  • An SMTP server such as smtp.example.net is something else: you send through it, but SPF wants the service’s list of servers.
  • Does the service only ask for CNAME records, often for DKIM or its own return address? Then nothing goes in your SPF record. Do add those records to your DNS.
  • If your own server or your website sends mail itself, enter that server’s IP address.
Mail from other servers

With DMARC enforced, ~all is the usual choice. Use -all when you are sure the list is complete.

DMARC policy

Start at none with a report address, check the reports for a few weeks, then move to quarantine and reject.

How to use it

  1. Enter your domain and select every service that sends mail with your address: your mailbox provider, but also newsletter tools, web shops and invoicing software.
  2. Copy the records into your DNS, at your domain registrar or hosting provider. Replace an existing SPF record rather than adding a second one.
  3. Turn on DKIM in your mail provider’s admin panel. DKIM keys are generated by the provider, so this tool can’t create them.
  4. After an hour or so, check the result with the e-mail domain check.

Rolling out DMARC safely

Start with p=none and a report address. Receivers then send daily reports of who sends mail with your domain, without blocking anything. When the reports only show your own services, move to quarantine, and later to reject. Skipping straight to reject can stop legitimate mail from a service you forgot.

DMARC reports are XML files. A report address on your own domain is the simplest start; dedicated report services make them readable.

Domains that never send mail

Parked domains and old brand names are popular for spoofing, precisely because nobody watches them. For those, the tool produces a set that refuses all mail in your name: an SPF record that allows no server, DMARC on reject, and optionally a “null MX” record that tells senders the domain accepts no mail.

Background reading · 3 min read

Protecting your domain against forged e-mail

Anyone can send mail that appears to come from your domain, unless SPF, DKIM and DMARC are set up. What they do, and how to configure them in four steps.

Read more

← Back: Tools

IT-scan

Want this checked for your whole business?

The tools cover one topic each. The IT-scan looks at e-mail, accounts, backups, devices and your website together, with a report in plain language.