Skip to content

DUPLICATE SPF RECORD · DNS TXT / Multi-Vendor SPF

How to Fix Duplicate SPF Records & Invalid SPF Syntax

RFC 7208 Section 3.2 strictly forbids publishing more than one v=spf1 TXT record on the same hostname. When a marketing or IT team adds a second v=spf1 record for HubSpot, Klaviyo, Google Workspace, or Zendesk instead of editing the existing record, every receiving mail server immediately returns SPF PermError and rejects or spam-folders mail. Merging all active mechanisms into a single syntactically valid v=spf1 TXT entry (ending with one ~all or -all) resolves the outage as soon as DNS TTL expires.

Key facts
Strict RFC 7208 rule
Maximum ONE v=spf1 TXT record per domain or subdomain; 2+ records = instant PermError
Most frequent syntax bugs
Multiple "all" qualifiers, smart/curly quotes pasted from docs, missing spaces, or typos like "inlcude:"
String length trap
Single TXT strings over 255 characters must be split into concatenated quoted segments by your DNS provider
Instant check
Test your domain live in /inspector/ or /tools/spf-lookup-checker/

RFC & DNS Diagnostic Matrix

Governing standard: IETF RFC 7208 Section 3.2 (Single SPF Record Rule) · Typical turnaround: 1 hour to 1 business day ($1,500 Audit / $3,000 Repair).

RFC & DNS Diagnostic Matrix
Diagnostic Check Broken Signal Command / Tool Healthy Production State
Multiple v=spf1 TXT entries 2 or 3 separate TXT records starting with v=spf1 on apex domain dig +short TXT yourdomain.com | grep spf1 Exactly ONE v=spf1 TXT record returned
Multiple all / redirect qualifiers v=spf1 include:_spf.google.com ~all include:spf.hubspot.net -all Inspect raw TXT syntax left to right Strictly ONE qualifier (~all or -all) at the very end
Unrecognized tokens or capitalization bugs ptr:, ip4: with invalid CIDR, missing colon (include _spf.google.com), or stray spaces inside tokens Validate record in /tools/spf-lookup-checker/ Every mechanism valid per RFC 7208 ABNF grammar
Legacy DNS Type 99 SPF records Old RR Type 99 SPF entry disagreeing with Type 16 TXT record dig +short SPF yourdomain.com Deprecated Type 99 removed; TXT record only

Step-by-Step Recovery Checklist

  1. Query live DNS with dig +short TXT yourdomain.com (or our free /inspector/) to list every TXT record starting with v=spf1.
  2. Inventory each active mail sender inside those records and remove any retired ESP or sender that uses its own subdomain Return-Path.
  3. Combine the remaining required mechanisms into ONE single v=spf1 line with exactly one trailing ~all (recommended alongside DMARC) or -all.
  4. Verify the merged record stays at 8 or fewer recursive DNS lookups using /tools/spf-lookup-checker/.
  5. Update the primary TXT record in Cloudflare, Route 53, or GoDaddy and delete all duplicate v=spf1 TXT entries in the same change window.
  6. Re-query live DNS after TTL expiry and send test messages to Gmail and Outlook to confirm spf=pass in Authentication-Results.

DNS & Header Verification Example

# BROKEN (two separate TXT records -> instant RFC 7208 PermError):
"v=spf1 include:_spf.google.com ~all"
"v=spf1 include:spf.protection.outlook.com ~all"

# FIXED (single merged TXT record -> valid):
"v=spf1 include:_spf.google.com include:spf.protection.outlook.com ~all"

Need copy-paste DNS diffs and live header verification within 24 business hours (free if we miss the clock)? Start the $1,500 24-Hour Deliverability Audit (100% credited toward Technical Repair or Recovery Sprint) or preview a redacted sample audit report .

DUPLICATE SPF RECORD FAQ

Straight answers on pricing, timelines, and fit.

Can I have one SPF record on the root domain and another SPF record on a subdomain?

Yes. The one-record limit applies per hostname. Having one v=spf1 record on company.com and a separate v=spf1 record on mail.company.com is valid and recommended for traffic isolation.

Should my merged SPF record end with ~all (softfail) or -all (hardfail)?

When paired with an active DMARC policy (p=quarantine or p=reject), ~all is widely preferred because it prevents overly aggressive forwarding servers from bouncing legitimate forwarded email before DMARC evaluates DKIM.

Why did my DNS provider reject a long merged SPF record?

DNS TXT strings have a 255-character limit per string segment. Cloudflare and Route 53 let you split long SPF records into multiple adjacent quoted strings inside ONE TXT record (or better yet, shorten the record by moving ESPs to subdomains).

Start with a 24-hour Deliverability Audit.

We inspect your recursive SPF tree, raw sent headers, ESP settings, and Postmaster data and deliver exact copy-paste DNS/ESP fixes within 24 hours of read-only access (free if we miss the clock). Hire us for implementation within 30 days and the full $1,500 credits toward the project.

Prefer email? Send your domain and what broke directly to audit@deliverabilityrecovery.com .