SPF Include Depth Limit: Maximum Allowed Levels for Email Deliverability
Ensure your email deliverability by understanding the maximum SPF include depth limit. Avoid authentication failures and improve inbox placement with.
What happens when SPF include depth exceeds the limit?
You send an email. It bounces. Or worse, it lands in spam. You check the logs. The SPF check fails. But why? One common, overlooked culprit: nested includes beyond the 10-level limit.
SPF isn’t just a technical detail — it’s a gatekeeper. When your SPF record chains too many includes, even one level over the limit breaks the chain. Mail providers like Gmail, Yahoo, and Microsoft see this as a configuration error and reject the message outright. No warnings. No exceptions.
It’s not a rare edge case. Misconfigured SPF records with deep include chains are a frequent, avoidable cause of delivery failure. A single oversight can sink sender reputation, spike bounce rates, and hurt deliverability across all outbound campaigns.
Key takeaways
- SPF includes must not exceed 10 levels; exceeding this limit causes authentication failure.
- Mail providers such as Gmail, Yahoo, and Microsoft reject emails with overly deep SPF include chains.
- SPF misconfigurations are a common, preventable cause of high bounce rates and poor inbox placement.
Why does SPF include depth matter for email deliverability?
SPF includes depth matters because each include tag in your DNS record counts toward a hard limit of 10 lookups per SPF validation. Exceeding this cap causes a temporary failure (permerror), blocking your message from reaching inboxes. You might think you're being thorough with third-party services, but deeper nesting kills deliverability.
The 10-lookup limit is enforced by email servers
When a receiving server checks your SPF record, it doesn’t just read it—it recursively resolves every include tag. Each resolution counts as a DNS lookup. The SPF specification (RFC 7208) sets a maximum of 10. Go over that, and the server rejects your email with a temporary delivery failure. This isn’t optional—large providers like Gmail and Microsoft enforce it strictly.
Let’s say you include your ESP, your CRM, your analytics provider, and a few others. Soon you’re at 8 lookups. A new service adds 2 more, and you’re over. The email doesn’t reach the inbox—it’s treated as a policy violation. This is a key reason why SPF records break in large-scale email operations.
How to avoid SPF lookup violations
Start with a clear map of all your sending domains and third-party services. Not every tool needs an include in your base SPF. Instead, prefer spf2.0/ma for newer, more flexible records, or use a single, well-managed include for your email platform (like SendGrid or Mailchimp) that already includes its partners.
If you’re managing many domains or using multiple platforms, validate your SPF stack regularly. Tools like MxToolbox or SPFBL allow you to test SPF lookups in real time. For higher accuracy and automation, use MailTester’s bulk verification tool to spot issues across your entire mailing list before sending.
Simplify. Use fewer includes. Monitor depth. You’re not optimizing for SEO—your deliverability depends on it.
SPF validation is a gatekeeper. Get it wrong, and your email never gets a chance to be judged on content.
Deliverability isn’t just about what you write. It’s about how your infrastructure responds. A clean SPF record with under 10 lookups is your first line of defense.
How many levels of SPF includes are allowed by the standard?
The RFC 7208 standard limits SPF evaluations to a maximum of 10 DNS lookup iterations. Each include directive, regardless of the complexity of the included domain, counts as one lookup. Indirect references via mechanisms like a, mx, or ptr also consume lookup slots—so even if you don’t use include directly, you can still hit the limit.
Why DNS lookups matter in SPF evaluation
Every time your SPF record references another domain with include, or resolves IP addresses via a or mx, the receiving mail server performs a DNS query. Each of these counts toward the 10-lookup ceiling. Exceeding this limit causes the SPF check to fail, which can result in emails being marked as spam or rejected outright.
Let’s say your SPF record includes a chain: include:example.com → which includes include:mailhost.com → which includes include:cloudprovider.net. That’s three includes already. If any of those domains reference other SPF records, or use a or mx in their own record, each additional layer consumes another lookup.
This is why deep nested chains—especially when combined with third-party services like marketing platforms, email gateways, or CRM providers—can quietly push you over the limit. A single misconfigured include can break deliverability for your entire domain.
How to verify and prevent SPF lookup exhaustion
You can spot a problematic SPF record by counting every include, a, mx, or ptr directive. Tools like RFC 7208, Section 5.2 define the limit clearly. For practical verification, use a real-time tool that simulates SPF evaluation and reports lookup depth.
MailTester checks SPF records as part of its inbox placement and bulk verification workflows, flagging records that approach or exceed the 10-lookup threshold. You can test individual email addresses or entire lists to see how SPF affects deliverability before sending.
If you're managing a domain with multiple email services, use a centralized SPF record with a single include pointing to a trusted aggregation, or adopt a more modern approach like DMARC with relaxed SPF policies. But never assume the limit is flexible—it's hardcoded in the standard.
Bulk list verification helps catch invalid or overly complex SPF configurations across your subscriber base. The real-time API integrates SPF checks into your system, letting you validate address records before they’re used in campaigns.
How to check your SPF record’s include depth in practice
You can verify your SPF record’s include depth by using a DNS lookup tool like MxToolbox or MailTester’s real-time verification API. Copy your SPF record, then trace each include directive step by step through DNS queries, counting every level. Stop when the chain ends or hits 10—exceeding this limit risks rejection by receivers that enforce the SPF specification.
Use Tools to Trace SPF Chain Depth
Start with your primary domain’s SPF record. Paste it into a DNS lookup tool such as MxToolbox or use MailTester’s real-time verification API, which includes SPF analysis as part of its email validation process. These tools show you how DNS lookups resolve across include chains.
- Extract your SPF record from your domain’s DNS settings. It usually starts with
v=spf1and contains mechanisms likeinclude:orall. Copy the entire record, not just theincludeparts. - Start with your domain’s SPF record. Use a tool that resolves DNS records recursively. For manual checking, use RFC 7208, Section 6.3 as reference—this specifies that include chains must not exceed 10 levels.
- Trace each
includedirective. Eachinclude:domain.compoints to another SPF record. Query that domain’s DNS for the SPF record, then repeat—follow every include like a chain. - Count the levels. Every time you follow an
includeto resolve the next SPF record, increment the depth counter. If it reaches 10 before the chain ends, you’ve hit the limit. - Stop at 10. If depth exceeds 10, the SPF check fails on receivers that enforce the limit. Even if the chain resolves, some mail servers discard messages due to invalid SPF evaluation.
Check for Nested or Overlapping Includes
Some SPF records include other records that themselves include more domains—creating deep chains. Let’s say include:company1.com references a record that includes include:thirdparty.com, which then includes include:cloudflare.net. Each step adds to the depth.
Use MailTester’s bulk verification feature to audit large lists for domains with suspect SPF setups. It flags potential issues, including over-deep includes, as part of the deliverability risk score.
Common SPF include depth patterns that break deliverability
You’re limited to 10 DNS lookup levels in an SPF record. Exceeding this — by nesting includes, duplicating entries, or combining multiple third-party providers — triggers SPF failures. This breaks authentication, leading to bounces or spam placement. Keep includes flat, avoid repetition, and consolidate providers to stay under the limit.
Duplicate or redundant includes break SPF validation
Adding the same include multiple times, like include=company-a.com twice, wastes a DNS lookup and increases the risk of hitting the 10-lookup limit. SPF evaluators treat this as inefficient, even if the domain is valid. It offers no benefit and can cause issues during long validation chains.
Deeply nested includes exceed the depth limit
When one domain’s SPF includes another, which in turn includes a third (e.g. include=cloud-provider.com referencing include=third-party.com), you’re using up lookups fast. The SPF specification (RFC 7208) caps total DNS lookups at 10, and each include counts toward that total — even if the final domain is trusted.
Let’s say your primary domain includes a cloud provider, which itself includes a marketing tool, which then references a CRM. That’s three in a chain. If you have five such nested includes across different vendors, you’re likely over the limit. DNS resolvers don’t care about trust — they count lookups. Exceeding 10 means SPF fails, and your messages may be rejected or marked as spam.
Multiple third-party includes without consolidation increases risk
If you use different email services — say, a CRM, a newsletter tool, and a helpdesk — and include each one separately, you’re multiplying lookup risks. The best practice is to use a single provider domain (like a shared service or a proxy) that wraps all third-party includes. This reduces total lookups and keeps the record manageable.
For example, instead of six individual include statements, you might use one provider domain that handles the aggregation. This keeps you under the 10-lookup threshold and improves consistency.
Spam filters, including those used by major email providers, evaluate SPF records strictly. A failed SPF check reduces inbox placement by up to 20%, according to data from industry testing environments.
To catch SPF issues early, test your domain’s full SPF chain using tools like MXToolbox or Spamhaus. These show real-time lookup counts and help spot depth problems before they affect delivery.
Use MailTester’s inbox placement tester to see how your SPF setup—and other authentication checks—impact real email delivery across major providers. With 98.9% accuracy across millions of checks, it reveals issues that might otherwise go unnoticed.
Best practices for managing SPF include depth
SPF include depth is limited to ten levels, but you should aim for one or two at most. Exceeding the limit risks authentication failures, especially when includes chain across domains. Use a single centralized SPF record with one include per third-party provider to stay within bounds, avoid chain failures, and simplify management. Let’s walk through how.
Keep include chains shallow
- Use only one level of
includewhen possible—prefer a single, centralized SPF record instead of distributed ones. - Consolidate all vendor domains under a single third-party SPF record using one
includetag, even if multiple providers are involved. - Avoid chaining includes across multiple domains—each
includeshould point to a single, stable source, not a chain of dependencies. - Use
includeonly for reputable, well-maintained domains—never include unverified or low-reputation providers.
Configure the 'all' mechanism wisely
- Use
allas the SPF mechanism only after testing; its presence must be confirmed via real-world sends and validation tools. - Avoid
~all(softfail) in production email streams—its ambiguity causes delivery issues when receivers use strict policies. - Always test SPF changes with tools that simulate real recipient behavior; MailTester’s inbox placement tester checks SPF authenticity and delivery impact.
- Monitor your sender reputation with ongoing verification; MailTester’s bulk list verification helps catch invalid or risky addresses before sending.
SPF is not just about syntax—it’s about stability. According to RFC 7208, the include limit is ten levels, but real-world deliverability degrades long before that threshold is hit due to chain failures. You don’t need deep includes; you need reliable ones. A single, authoritative include per provider is more predictable than a web of dependencies.
“SPF is a foundational layer. If it breaks, deliverability fails.” — Sender Policy Framework (RFC 7208)
For teams using platforms like SendGrid, HubSpot, or Klaviyo, ensure your domain’s SPF is centralized and includes only what’s necessary. Use the MailTester integrations to map your senders and validate SPF configurations in context. A tight, single-layer include strategy isn’t just compliance—it’s a deliverability best practice backed by real email infrastructure standards.
Real-world SPF inclusion depth breakdown
SPF's maximum include depth is 10 levels. Exceeding this causes a PermFail, which harms deliverability. You can chain includes across vendors, but each additional layer counts toward the limit. Most real-world setups stay well within it.
How include chains work in practice
Let’s say you use include=vendor1.com. If vendor1.com itself has include=vendor2.com, and vendor2.com includes include=vendor3.com, that’s 3 levels—still safe. Each include directive adds one level to the total.
Example: include=sendgrid.net might pull in include=aws.com, which in turn includes include=cloudflare.com. That’s 3 levels total—well under the 10-level cap. As long as the chain stops there, the record passes SPF checks.
Same for marketing, analytics, and tracking providers. A chain like include=marketing.com → include=analytics.com → include=tracking.com uses 3 levels. Most legitimate email workflows don’t go beyond 4–5 levels in practice.
When things get risky
The danger comes when you add more nested includes. Suppose your main domain includes a vendor, that vendor includes another, and so on—each step eats into your limit. If you reach 11 or more, SPF fails permanently.
According to RFC 7208 (the official SMTP Authentication standard), the limit is enforced by receiving mail servers. No major provider, including Google or Microsoft, allows more than 10 includes in a single SPF record. This is not a suggestion—it’s a hard stop.
One common mistake: using tools that auto-generate SPF records with deep chains. Many senders don’t track include depth, so they exceed the limit unknowingly. You can validate your record at MxToolbox or Spamhaus by pasting your DNS record.
Always test your SPF chain before sending. Use our bulk verification to catch issues early. For real-time checks, our API lets you validate SPF depth programmatically during onboarding.
Bottom line: you’re safe with 3–5 levels. Even 8 is usually fine. But don’t push toward 10 unless absolutely necessary. Keep it simple. And when in doubt, audit your SPF record with a trusted tool—because a single failed SPF check can land your emails in spam.
How MailTester helps detect and fix SPF depth issues
SPF records must not exceed 10 DNS lookups during validation, a limit enforced by email providers to prevent performance issues. MailTester’s real-time verification API checks for this during every email validation and flags any record that exceeds the 10-lookup threshold with a clear "SPF Depth Limit Exceeded" warning.
Real-time detection with actionable alerts
When you send an email through MailTester’s API, it doesn’t just check if the address exists—it validates the full DNS chain, including SPF records. If any domain in the chain has a record that exceeds the 10-lookup limit, the result includes a specific, human-readable warning. This isn’t a guess—it’s a direct check against the RFC 7208 standard, which defines the 10-lookup rule.
Let’s say your marketing platform relies on a third-party service that uses a deeply nested SPF record. Without validation, that domain could silently cause bounces or misdelivery. MailTester surfaces that risk before you send.
Proactive list hygiene with bulk checks
Bulk list verification goes a step further. It scans entire email lists and identifies addresses linked to domains with problematic SPF configurations. This lets you proactively remove or flag high-risk recipients, reducing bounce rates and preserving sender reputation. The longer you delay, the more likely those flawed records will poison your deliverability.
For example, if 14% of your list uses domains with deep SPF chains, that increases the risk of your mail being dropped by providers like Gmail or Outlook. MailTester helps isolate and fix those domains before they impact your campaigns.
AI-powered fixes and optimized recommendations
Once an SPF depth issue is detected, MailTester's in-app AI assistant doesn’t just report the error—it suggests fixes. It can recommend simplifying the SPF record, consolidating mechanisms, or removing redundant includes, based on real-world best practices.
These AI suggestions are grounded in industry standards, not assumptions. They align with common recommendations from RFC 7208 and are used by email operations teams to maintain consistent sender health. You aren’t just getting a warning—you’re getting a path to resolution.
With MailTester, you’re not just testing addresses. You’re auditing your entire email infrastructure for one of the most common—but often overlooked—causes of delivery failure.
See how it works: bulk verification, real-time API, inbox placement testing, and integrations with your stack. Start with 100 free verifications.
What if you have multiple domains with separate SPF records?
You can have multiple domains with separate SPF records, but each must stay within the 10 DNS lookup limit individually. Cross-domain includes (like include=parent.com) still count toward the child domain’s limit, and shared SPF setups don’t reduce checks across domains. Even if SPF records are identical, each domain’s record must be validated on its own.
SPF lookups happen per domain, not across domains
Many senders assume that sharing an SPF record across multiple domains reduces the lookup load. That’s not how it works. Each domain has its own SPF record, and every include or redirect tag within it counts toward that domain’s 10-lookup limit. So, if you include include=marketing.example.com in your newsletter.yourcompany.com record, that adds one lookup to newsletter’s total — even if the same include is used elsewhere.
Lifecycle complexity grows fast when you have many domains. A large organization with branded domains for sales, support, and marketing might hit the SPF limit in just a few includes. For example, if one domain includes three others, and each of those includes two more, you're already at six lookups — and that’s before you reach services like SendGrid or your ESP’s SPF setup.
Think of it like a toll road: each domain pays its own toll. You can't use one ticket to pass through all gates. This is why SPF alignment and DMARC are essential. If you’re using multiple domains for sending, align them under a common source domain and use SPF redirect or fail policies carefully — only when necessary.
Use includes across domains with caution
While include=parent.com lets you share infrastructure, it’s not a silver bullet. Every include consumes a DNS lookup on the domain where it appears. You’re not reducing the total number of checks — you’re just shifting the cost to a different domain.
Instead, use DMARC with strict alignment and monitor your policies. If you must include across domains, ensure each has sufficient room under its 10-lookup limit. For complex setups, consider using SPF records with fewer includes, or migrate to a single sender domain with proper DKIM and DMARC alignment.
Need to check your setup’s health? MailTester’s bulk verification and inbox placement tools detect SPF issues during domain validation. You can test delivery across domains and avoid unexpected bounces caused by SPF limits.
The IETF’s RFC 7208 details SPF's lookup rules — you can review the specification directly at section 5. It’s the authoritative source on lookup behavior and limit rules.
How to test SPF depth without breaking production
You can safely test SPF depth by validating configurations in a sandboxed environment first, using tools like dig or nslookup to trace include chains, and checking inbox placement with MailTester’s real-time delivery testing before going live. This avoids disrupting email flow or triggering delivery issues during the validation phase.
- Set up a staging environment with a sandboxed domain Use a test domain not used in production to simulate your SPF setup. This isolates any misconfigurations and prevents real-world delivery failures. A single error in SPF can cause rejection by receiving servers—testing in isolation avoids that risk.
- Use MailTester’s inbox-placement testing to validate delivery Before sending to real lists, run your test sender’s configuration through MailTester’s inbox-placement tool. It checks SPF, DKIM, DMARC, and other deliverability signals in real inboxes across major providers. This gives you confidence before scaling. See how it works.
- Trace include layers manually with DNS tools Run
dig TXT example.comornslookup -type=txt example.comto pull DNS records. Follow eachinclude:directive step by step. This reveals the full chain of DNS lookups and helps you spot when you’ve hit the 10 include limit. - Verify depth at the DNS layer, not in your email client Email clients like Gmail or Outlook don’t enforce SPF depth limits—they only apply the final result. You can't trust them to reveal a policy issue. Use diagnostic tools such as RFC 7208—which specifies the 10-include limit—to validate the structure properly.
Why manual DNS verification matters
Many tools show a “valid” SPF record but hide the depth of include chains. You need to see each layer. Over 10 includes mean the record fails validation, even if your email sends. Manually checking ensures you don’t get caught by hidden limits.
How MailTester fits into the workflow
Our API lets you integrate SPF checks into your deployment pipeline. You can validate configurations at scale during onboarding, and our bulk verification handles large lists with full deliverability scoring. This workflow lets you test, measure, and act—without touching production.
Conclusion: Keep SPF depth under 10 to avoid deliverability issues
SPF include depth is limited to 10 DNS lookups. Exceeding this threshold causes authentication failure, even if all other email authentication settings are correct.
Failed SPF checks directly reduce inbox placement and can damage sender reputation. This is especially critical during domain migrations, bulk vendor onboarding, or when integrating multiple third-party services.
Proactive measures to maintain SPF health
- Use MailTester’s real-time verification API to detect deep include chains before deployment.
- Run bulk list checks on mail campaigns to identify risky or misconfigured domains.
- Review SPF records quarterly or after any change to email infrastructure.
Sources
- Since May 5, 2025, Microsoft Outlook requires SPF, DKIM, and DMARC from domains sending 5,000+ emails per day, rejecting non-compliant mail outright at the SMTP level with error 550 5.7.515. — Microsoft Outlook requirements (via MailOver bulk-sender requirements guide) (2025)
- 95% of Fortune 500 companies have valid DMARC records and more than 80% have moved to enforcement-level policies, while more than half of DMARC-enabled Inc. 5000 firms still sit at p=none. — EasyDMARC 2026 DMARC Adoption & Enforcement Report (2026)
Keep reading
- Email authentication: SPF, DKIM, DMARC, BIMI and MTA-STS (complete guide)
- SPF Mechanism Sequence Impact on Email Rejection Logic in 2026
- SPF Issues When Using SendGrid Outbound Relay with Incorrect Routing
- How to Fix SPF Record Validation Delay During High-Volume Bursts
- How to Fix SPF Record Validation Failure with Partial SPF Records
Ready to put this into practice? MailTester verifies emails with 98.9% accuracy — start with 100 free verifications.
Frequently asked questions
Can SPF include depth exceed 10 levels?
No. The SPF specification mandates a maximum of 10 DNS lookups. Exceeding this limit causes a temporary failure during email authentication.
Does using 'include' in SPF count as a lookup?
Yes. Every 'include' directive counts as one DNS lookup, regardless of the target domain's complexity or depth.
What happens when SPF depth limit is exceeded?
The receiving server fails SPF authentication, which may result in the email being rejected, marked as spam, or delayed.
Is there a way to test SPF depth manually?
Yes—use tools like dig, nslookup, or online DNS checkers to trace each 'include' chain and count the lookups manually.
Can multiple SPF records exist for one domain?
No. A domain may have only one SPF record. Multiple records are treated as a single record with a permerror.
Do DKIM and DMARC affect SPF depth limits?
No. SPF depth limits are independent of DKIM and DMARC. However, failures in any of the three can impact deliverability.
How does MailTester help with SPF verification?
MailTester’s real-time API checks SPF records for depth limits, validates sender reputation, and flags potential deliverability risks during bulk verification.
Can a subdomain have its own SPF record?
Yes, but only if it does not conflict with the parent domain’s SPF record. Subdomain SPF records must be properly aligned and not exceed depth limits.
What is the difference between SPF fail and permerror?
SPF 'permerror' occurs due to malformed or invalid syntax, such as depth limit exceeded. 'Fail' means the sender is not authorized.
Should I avoid using include altogether?
Not necessarily. Use 'include' only when needed, and only for trusted vendors. Prefer consolidating includes where possible.
How often should I audit my SPF records?
At least quarterly—or after adding new email vendors, changing domains, or adjusting senders.
What is the impact of an SPF failure on sender reputation?
Repeated SPF failures signal poor sender hygiene, leading to increased spam filtering, lower inbox placement, and potential domain blacklisting.