SPF & DMARC Record Generator

Pick the mail services you use and get correct SPF and DMARC records. Load your current settings to check the 10-lookup limit too. No sign-up.

The records are built in this browser. Only when you press "Load current settings" is the domain name looked up on our server, to read its published SPF and DMARC records (the same lookup as the DMARC Check).

How to publish them

  1. Open the DNS settings where your domain's name servers are managed (your registrar or hosting company).
  2. Add a TXT record with the host, type (TXT) and value above. Some screens want the SPF host "@" left empty.
  3. If an SPF record already exists, edit it instead of adding another: two SPF records invalidate each other.
  4. Changes take minutes to hours to appear. Then check them with the DMARC Check.

Instructions for common DNS hosts

About this tool

The SPF & DMARC Record Generator builds the two DNS records that protect a domain against spoofing, by choosing from a list. Values for common senders such as Google Workspace, Microsoft 365, SendGrid and Japanese hosting companies are built in.

Enter a domain and press "Load current settings" to fill the form from its current SPF and DMARC records, with the SPF lookups measured per include, and to compare the current and new values.

How to use it

  1. (Optional) Enter your domain and press "Load current settings".
  2. SPF: select every service that sends your mail, and add your own mail servers' IP addresses.
  3. DMARC: choose a policy and a report address (rua). Start with p=none if you are new to DMARC.
  4. Copy the values under "Records to publish" and add them to your DNS as TXT records.

The SPF 10-lookup limit

SPF may make at most 10 DNS lookups per check (RFC 7208 §4.6.4). Every include counts, and so does everything below it, so adding services soon goes over. Past the limit SPF fails altogether, and legitimate mail fails authentication. This tool adds up measured values for a loaded record and catalog estimates for newly selected services. See the guide to the SPF lookup limit.

FAQ

Can I go straight to p=reject?

Not recommended. Any legitimate sender without SPF or DKIM set up would stop being delivered. Collect reports at p=none, confirm with the DMARC Report Analyzer that every legitimate source passes, then tighten step by step.

-all or ~all?

-all (reject) once every sender is listed. If you are not sure you have them all, ~all is fine to start with: under a DMARC reject policy, spoofed mail is still stopped.

Can it make DKIM records?

No: each sending service issues its own DKIM key. Turn on DKIM signing for your domain in each service and publish the record it shows. See the DKIM guide.

Is what I enter stored?

No. The records are built in your browser and not sent to us. Only "Load current settings" looks up the domain name on our server.

Related links