Free SPF Record Generator
Build a valid SPF record in 60 seconds. Select your email providers, add custom IPs, choose your policy - copy the result directly into your DNS.
What Happens After You Generate Your SPF Record?
1. Publish it as a TXT record at your domain apex. In your DNS host's control panel (GoDaddy, Cloudflare, Namecheap, Route 53, and similar), add a TXT record whose host is @ - the root of your domain - and set its value to the SPF string this generator produced. A domain may publish only one SPF record, so if one already exists, merge the new mechanisms into it instead of creating a second. New to the protocol? Read what is SPF.
2. Verify it with our free SPF checker. After DNS propagation (typically 5-60 minutes), run a check to confirm the record is published correctly and the lookup count is under 10.
3. Monitor it over time. As you add new email services, the record needs updating - and every include:, a and mx mechanism it has to resolve counts against SPF's cap of 10 DNS lookups (an ip4:/ip6: mechanism costs zero). When you approach the 10-lookup limit and risk a PermError, use AutoSPF to flatten the record. With SPF in place, the next step is to create a DMARC record.
DNS Lookup Cost by Provider
| Provider | Include mechanism | Lookups |
|---|---|---|
| Google Workspace | include:_spf.google.com | 4 |
| Microsoft 365 | include:spf.protection.outlook.com | 2 |
| SendGrid | include:sendgrid.net | 5 |
| Mailchimp | include:servers.mcsv.net | 1 |
| Amazon SES | include:amazonses.com | 2 |
| Salesforce | include:_spf.salesforce.com | 2 |
| HubSpot | include:spf.hubspot.com | 2 |
| Brevo | include:spf.brevo.com | 2 |
| Mailgun | include:mailgun.org | 5 |
| Zoho Mail | include:zoho.com | 4 |
| Postmark | include:spf.mtasv.net | 1 |
| SparkPost | include:sparkpostmail.com | 1 |
| Custom IP (ip4/ip6) | ip4:x.x.x.x | 0 |
Lookup counts are approximate and may change when providers update their infrastructure. Use the SPF checker for live counts.
SPF Mechanisms and Qualifiers
An SPF record is a list of mechanisms that authorize senders, each preceded by an optional qualifier that decides what happens on a match. The generator assembles these for you - this is what each one means.
Mechanisms
ip4:/ip6:- authorize specific IP addresses or ranges. Zero DNS lookups.include:- pull in another domain's SPF record (one lookup, plus any it resolves).a/mx- authorize the domain's A record or its mail servers (one lookup each).redirect=- delegate the whole policy to another domain's SPF record.
Qualifiers (the all tag)
-all- fail: reject any sender not listed. The strongest setting.~all- softfail: accept but flag unlisted senders. Use while testing.?all- neutral: no assertion either way.+all- pass: authorizes everyone. Never use this.
SPF Record Generator FAQ
What is an SPF record generator?
An SPF record generator builds a valid Sender Policy Framework (SPF) TXT record string by letting you select your email providers and enter custom IP addresses. It outputs the correct syntax (starting with v=spf1, listing mechanisms such as include, a, mx and ip4/ip6, and ending with an all qualifier) so you can copy it directly into your DNS configuration.
Is this SPF generator free?
Yes - this SPF generator is completely free, with no signup required. It builds the record client-side in your browser, so nothing is sent to any server.
How do I know which include to use for my email provider?
Each email provider publishes a specific include mechanism. Common ones: Google Workspace uses include:_spf.google.com (4 lookups), Microsoft 365 uses include:spf.protection.outlook.com (2 lookups), SendGrid uses include:sendgrid.net (5 lookups). This generator handles the lookup automatically when you select a provider.
What is the difference between -all and ~all?
-all (hard fail or "fail") instructs receiving mail servers to reject mail from senders not listed in the record. ~all (softfail) tells them to accept the message but mark it as suspicious. ?all is neutral and +all authorizes everyone (never use it). Start with ~all while testing, then tighten to -all once every legitimate sender is listed.
Can I have more than one SPF record?
No. A domain must publish exactly one SPF record. Two or more SPF TXT records cause a PermError and receivers ignore all of them. To authorize several senders, combine their mechanisms into a single record rather than publishing separate SPF records.
What causes an SPF PermError?
The most common cause is exceeding SPF's limit of 10 DNS lookups. Every include, a, mx, ptr and redirect mechanism that must be resolved counts toward the cap; ip4 and ip6 mechanisms cost zero. When you cross 10 lookups the record returns PermError and fails authentication. SPF flattening with AutoSPF keeps you under the limit.
What is the redirect modifier?
The redirect= modifier hands SPF evaluation to another domain's SPF record instead of using an all qualifier. It is useful when many domains should share one centrally managed policy, but the target record still counts toward the 10-lookup limit.
Generated a record that exceeds 10 lookups?
Monitor your SPF, DKIM, and DMARC authentication across all your domains. Get actionable reports and move toward full DMARC enforcement.
Start Free TrialBuilt for IT Teams
Rated 4.8/5 on G2 · 469 verified reviews
Dave G.
Owner
"DMARC Report has been invaluable in fixing email deliverability issues for our clients"
DMARC Report dashboard allows us to see easily what is compliant and what isn't compliant so we can quickly fix issues.
Antoine L.
"Incredible Service for an affordable price"
The software is easy to use and has also an entry friendly free plan up to 1,000 mails per month.
Zunaid K.
Director
"Essential tool for email delivery"
This tool helps us to implement DMARC reporting for our domains in an easy to use manner.