Maintaining an SPF record is pretty easy, given that you use only one or two email services. But that’s not always the case. For most organizations, there are more than a handful of servers and third-party services that are used to send emails to their clients and prospects. These services include CRM platforms, marketing tools, and billing systems.
If your organization also operates on a similar infrastructure, we understand that managing SPF records can become a big challenge! It is not only about the hassle of adding each service to the record—it’s about staying within the strict 10 DNS lookup limit defined by the SPF protocol. Once you go over this limit, the real problem starts. Even if your SPF record is technically correct, exceeding this limit will hurt your deliverability and undermine the very protection SPF is meant to provide.

The most common workaround to this is SPF flattening. SPF flattening helps you stay within the 10-DNS-lookup limit by resolving all the ‘include:’ mechanisms and nested lookups into a flat list of IP addresses.
In this article, we’ll learn everything about SPF flattening and what makes it a reliable choice among security teams despite its pros and cons.
What is SPF flattening?
SPF flattening is basically the process of taking all those include entries in your SPF record—like the ones you add when using services such as Google Workspace or Mailchimp—and replacing them with the actual IP addresses they point to. Instead of relying on DNS lookups every time an email is sent, you’re giving the receiving mail server a ready-made list of allowed IPs, right there in the record. This way, you avoid hitting the 10 DNS lookup limit, and your SPF check passes faster and more reliably.

Why are some teams skeptical about SPF flattening?
There are some teams that are not fully convinced by the idea of flattening their SPF records— and that’s understandable!
Their apprehension usually comes from a few practical concerns.
First, flattened records need regular updates. Email service providers can change their sending IP addresses anytime, and they don’t always notify you when that happens. So, unless you’re actively keeping track, your flattened record can go out of date and cause problems.
Second, maintaining a long list of IP addresses manually can lead to errors—whether it’s a typo, a wrong IP range, or a formatting mistake. This can break your SPF record or make it unreliable. And sometimes, even after flattening, the list can still get so long that you need to split it up, which can bring back the same DNS lookup issues you were trying to solve.

How can SPF flattening help boost the performance of your emails?
While there are many benefits of email flattening, there are some that stand out and outweigh the challenges that most organizations face.
Meeting compliance requirements
While setting up SPF, you’re only allowed up to 10 DNS lookups. This isn’t an arbitrary limit; it is defined by IETF’s RFC specifications. So, when you flatten the SPF records, you change all the includes into IP addresses, helping you stay under the 10-lookup threshold. This keeps your entire setup compliant and builds trust with receiving mail servers, thereby making your emails more likely to pass authentication checks and reach the inbox instead of being flagged or rejected.

Improved email deliverability
When your SPF record goes over the lookup limit, some mail servers might see your emails as suspicious. They could block them or send them to spam—even if the email is completely legitimate. The worst part is that you might not even know it’s happening. Flattening helps fix this by keeping your SPF record within the limit. That means your emails are more likely to go through smoothly, land in inboxes, and keep your domain’s reputation strong.
SPF flattening works even better when you use it with DMARC. If your SPF record exceeds the limit and stops working, even your real emails can fail DMARC checks. That makes it easier for attackers to spoof your domain or send fake emails that look like they’re from you. Flattening helps keep your SPF working properly, so both SPF and DMARC do their job, making it much harder for anyone to misuse your domain.

Which side should you pick?
Just like any other security tool, SPF flattening has its own list of pros and cons. It improves email deliverability and security, but managing it manually can be a hassle. But the good news is that you don’t have to do it all manually!
AutoSPF’s SPF Flattening tool is here to save the day. Our tool automatically flattens and compresses all domains within the SPF so that you don’t have to go over each domain, and there is no room for human error.
To learn more about the tool, book a demo with us today!