Skip to main content
All CollectionsTroubleshooting & Support
How to Resolve ‘SPF Too Many Included Lookups’ Error
How to Resolve ‘SPF Too Many Included Lookups’ Error

Learn how to fix the "SPF Too Many Included Lookups" error to ensure smooth email delivery and compliance. 🚀

Updated over a week ago

Uh-oh! You’re setting up your SPF record, and suddenly, you hit a roadblock: 'SPF Too Many Included Lookups' error 😱. If your emails are failing authentication because of this, don’t worry—we’ve got you covered! Let’s break it down and fix it step by step.


🚀 What Does This Error Mean?

SPF (Sender Policy Framework) allows you to specify which mail servers are authorized to send emails on behalf of your domain. However, SPF has a limit of 10 DNS lookups (due to security and performance reasons). If your record includes too many third-party services, you’ll exceed this limit, triggering the error.

A frustrated IT professional sitting at a desk, looking at a computer screen displaying an SPF configuration error message. The screen shows the text 'SPF Too Many Included Lookups' in red. The background has a tech-themed office setup with network cables and a whiteboard with email security notes.

🔍 Why Does This Happen?

Your SPF record contains multiple "include:" mechanisms for third-party services (like Google, Microsoft, Mailchimp, etc.). Each "include:" triggers a separate DNS lookup. When you have too many, BOOM—you hit the limit!

📌 Example of a problematic SPF record:

v=spf1 include:_spf.google.com include:spf.protection.outlook.com include:_spf.mailchimp.com include:spf.sendgrid.net ~all

Each "include:" above triggers a separate DNS lookup. If the total exceeds 10, SPF validation fails.


🛠️ How to Fix It

1️⃣ Use SPF Flattening

Instead of multiple "include:", replace them with direct IP addresses. Use tools like SPF Flattening Services to convert includes into a single list of IPs.

📌 Optimized SPF record:

v=spf1 ip4:192.168.1.1 ip4:203.0.113.2 ip6:2001:db8::1 -all

👉 This removes unnecessary DNS lookups while keeping your SPF valid!

2️⃣ Use Fewer Third-Party Services

If possible, reduce the number of email service providers. Stick to one or two and ensure they handle all your email needs.

3️⃣ Check for Nested Includes

Some services have SPF records that contain further "includes", leading to hidden extra lookups. Use an SPF record checker to inspect nested includes and remove unnecessary ones.

4️⃣ Use Subdomains for Different Providers

Instead of stacking all providers in one SPF record, create subdomains for different services:

  • marketing.yourdomain.com → Mailchimp

  • sales.yourdomain.com → Salesforce

  • support.yourdomain.com → Zendesk

Each subdomain can have its own SPF record, reducing lookup overload on your main domain.

5️⃣ Consider DKIM & DMARC for Extra Protection

SPF alone isn’t enough! Combine it with DKIM (DomainKeys Identified Mail) and DMARC (Domain-based Message Authentication, Reporting & Conformance) to improve email security and deliverability.


🎯 Final Thoughts

The 'SPF Too Many Included Lookups' error can be frustrating, but it's fixable! Keep your SPF lean, flatten unnecessary lookups, and use subdomains strategically. By optimizing your record, you'll boost email deliverability and keep your emails out of spam folders.

Need help setting up your SPF, DKIM, or DMARC? YourDMARC has got your back! 🚀


💡 Pro Tip: Use an SPF checker tool to verify your record after making changes.

Got questions? Drop them below! 👇

Did this answer your question?