0 min left
SPF SoftFail (~all) vs HardFail (-all) - Which Should You Use?

SPF SoftFail (~all) vs HardFail (-all) - Which Should You Use?

BulkEmailSetup
BulkEmailSetup Team
July 27, 2026
3 min read

~all (softfail) tells receivers "mail from other IPs is probably illegitimate, be suspicious," while -all (hardfail) says "no other IP is authorized, reject it." In practice, big receivers treat both as an SPF fail and let DMARC decide the outcome, so for domains with DMARC at enforcement, ~all is the safer recommendation: it avoids edge cases where forwarded legitimate mail gets rejected at SMTP time before DKIM can rescue it. Reserve -all for domains that never send mail at all.

What the qualifiers mean

The all mechanism matches every IP not matched earlier in the record. Its qualifier sets the result for those IPs:

Record endingSPF resultRFC meaning
+allPassEveryone is authorized, never use
?allNeutralNo assertion either way
~allSoftFailProbably not authorized; don't reject solely on this
-allFailNot authorized; rejection is appropriate
v=spf1 ip4:203.0.113.10 include:_spf.google.com ~all
v=spf1 ip4:203.0.113.10 include:_spf.google.com -all

What receivers actually do

The RFC text and receiver behavior diverged years ago:

Receiver behaviorSoftFail (~all)HardFail (-all)
GmailSignal into filtering; DMARC decides dispositionSame, fail feeds DMARC, rarely rejected on SPF alone
Microsoft 365Marks as spam-suspicious (configurable)Historically junked or rejected more aggressively
Smaller MTAs / on-premUsually accept, score in filterSome reject at SMTP time (550 SPF check failed)
DMARC evaluationSPF fail, alignment cannot passSPF fail, identical to softfail

The last row is the one that matters: DMARC treats softfail and hardfail identically. Neither passes. The qualifier only changes what happens at receivers that act on raw SPF before or without DMARC.

The forwarding problem is why ~all wins

When someone forwards your mail (university address → Gmail, a distribution alias, an old domain redirect), the forwarder's IP isn't in your SPF record. SPF fails by design, forwarding always breaks SPF.

With ~all, the message survives to be evaluated on DKIM, which travels intact through forwarders, and DMARC passes via aligned DKIM. With -all, an old-school receiving MTA may slam the door at SMTP time, 550, and DKIM never gets a vote. You lose legitimate forwarded mail and gain nothing, because spoofing protection was already DMARC's job.

This is also why "set -all for maximum security" advice from generic checklists misfires: the enforcement layer with teeth is your DMARC policy, not the SPF qualifier.

Decision table

SituationPublishWhy
Sending domain, DMARC at quarantine/reject~allDMARC enforces; softfail avoids forwarding casualties
Sending domain, DMARC still at p=none~all, and finish the DMARC rollout-all without DMARC is partial protection with real downside
Domain that never sends mail-allNothing legitimate to lose; strongest assertion correct
Migrating mail systems this week~allDon't combine a cutover with hard rejection
Any situationnever +all, avoid ?allOne is an open relay declaration, the other is a shrug

For a parked, non-sending domain, lock down all three:

yourdomain.com.              TXT  "v=spf1 -all"
*._domainkey.yourdomain.com. TXT  "v=DKIM1; p="
_dmarc.yourdomain.com.       TXT  "v=DMARC1; p=reject"

Check what you're publishing now

dig +short TXT yourdomain.com | grep spf1

While you're in there, confirm there's exactly one SPF record, duplicates cause PermError, and that you're under the 10-DNS-lookup limit. A PermError makes the ~all/-all question moot, since evaluation never reaches the all mechanism.

If SPF, DKIM, or DMARC isn't fully set up yet, start with the complete email authentication guide, qualifier tuning is the last 5% of the job.

How BulkEmailSetup helps

Dedicated SMTP servers from BulkEmailSetup ship with a single-IP SPF record, aligned DKIM, and a managed DMARC rollout, so the softfail/hardfail question is answered correctly for your exact mail flows, not by a generic checklist. See pricing.

Frequently asked questions

What is the difference between ~all and -all in SPF?

~all (softfail) tells receivers that non-listed IPs are probably not legitimate, treat with suspicion but don't reject on SPF alone. -all (hardfail) asserts that no other IP is authorized, inviting outright rejection.

Does -all guarantee spoofed mail gets rejected?

No. Most large receivers, including Gmail, treat SPF fail as one signal among many and rely on DMARC for the actual disposition decision. Some smaller servers do reject on -all at SMTP time.

Which should I use with DMARC?

With DMARC at enforcement, ~all is the safer choice: both qualifiers count as SPF fail for DMARC, but -all can get forwarded legitimate mail rejected before DKIM and DMARC are even evaluated.

Is ?all or +all ever acceptable?

?all (neutral) provides no protection and reads as an unfinished setup. +all explicitly authorizes the entire internet to send as your domain, never publish it; some filters treat it as a spam signal by itself.

What should a non-sending domain publish?

v=spf1 -all, plus an empty DKIM policy and DMARC p=reject. A domain that never sends mail has no forwarding traffic to protect, so the strictest assertion is correct.

Tags

SPFsoftfailhardfail~all-allemail authenticationDMARC
BulkEmailSetup

Written by BulkEmailSetup Team

We help businesses set up their own bulk email infrastructure, dedicated SMTP servers, IP rotation, and full deliverability control. One-time setup, no monthly platform fees.

Ready to set up your email infrastructure?

Get dedicated SMTP servers, IP rotation, and expert support to scale your email sending.

View Pricing