MX records tell the internet where to deliver email for your domain; SPF records tell receiving mail servers which systems are allowed to send email for that domain. If your domain is example.com, MX records decide where messages sent to name@example.com should land. SPF records help prove that an outgoing message from example.com is not being faked by a random server.
TLDR: MX records handle incoming email routing, while SPF records handle outgoing email authorization. For example, a small shop using Google Workspace might point its MX records to Google, then add SPF to allow Google and its newsletter platform to send mail. In one common support scenario, fixing a missing MX record can restore inbound email within 30 to 60 minutes, while correcting SPF can reduce spoofing and improve delivery rates by several percentage points. You usually need both, not one or the other.
What Are MX Records?
MX stands for Mail Exchange. An MX record is a type of DNS record that tells other mail servers where to send email for a domain.
Think of DNS as the public instruction book for your domain. Your website may use an A record or CNAME record. Your email uses MX records to say, “Send messages for this domain to these mail servers.”
For example, if someone emails hello@example.com, the sending mail server checks DNS for the MX records of example.com. It may find something like this:
- Priority 10: aspmx.l.google.com
- Priority 20: alt1.aspmx.l.google.com
- Priority 30: alt2.aspmx.l.google.com
The lower the number, the higher the priority. So the sending server tries the priority 10 server first. If that fails, it tries the next one. This backup system is handy when one mail server is busy or unavailable.
Why MX Records Matter
If your MX records are wrong, email may bounce, vanish, or land with the wrong provider. That sounds obvious, yet it happens all the time during domain moves and email platform changes.
Honestly, it feels like every email migration has at least one tiny DNS typo waiting to ruin someone’s afternoon. A missing dot, an old provider left behind, or a priority value entered badly can stop mail cold. Then everyone blames the email app, even though DNS is the real culprit.
Common MX record issues include:
- No MX records: Other servers do not know where to deliver mail.
- Old MX records: Email may still go to a former provider.
- Wrong priority: Mail may try the wrong server first.
- Typing errors: A small spelling mistake can break delivery.
- Slow DNS propagation: Changes may take minutes or hours to appear everywhere.
What Are SPF Records?
SPF stands for Sender Policy Framework. It is also a DNS record, but it has a different job. SPF helps receiving mail servers check whether a sender is allowed to send email for a domain.
An SPF record is usually stored as a TXT record. It might look like this:
v=spf1 include:_spf.google.com include:sendgrid.net -all
This record says: “Google and SendGrid are allowed to send email for this domain. Other servers are not.”
SPF does not decide where your incoming email goes. That is the job of MX. SPF checks outgoing mail. It helps stop spoofing, where attackers forge your domain in the “From” address to send scams.
MX Records vs SPF Records
MX and SPF records both live in DNS, but they answer different questions.
- MX asks: Where should incoming email for this domain be delivered?
- SPF asks: Which servers are allowed to send email for this domain?
Here is the simplest way to remember it:
- MX = receiving mail
- SPF = sending mail authorization
A domain can receive email without SPF, though that is risky. A domain can publish SPF without MX if it only sends mail and never receives it. But most businesses need both.
A Practical Example
Imagine a company called Bright Bean Coffee. It uses Microsoft 365 for staff email and Mailchimp for newsletters.
Its MX records point to Microsoft. That means email sent to orders@brightbean.example lands in Microsoft 365 mailboxes.
Its SPF record allows Microsoft 365 and Mailchimp to send mail for the domain. That means receipts and newsletters have a better chance of passing sender checks.
If Bright Bean forgets to include Mailchimp in SPF, newsletters may still go out. But some inbox providers may treat them as suspicious. Open rates can drop. Spam placement can rise. A campaign that normally gets a 38% open rate might fall to 25% after authentication problems, especially with large mailing lists.
How MX and SPF Affect Deliverability
Email deliverability is not controlled by one setting. It is a mix of DNS, reputation, content, engagement, and authentication. Still, MX and SPF are part of the foundation.
MX records affect whether mail can reach you. If they break, customers may not be able to contact you. Support tickets vanish. Sales leads bounce. Password reset emails never arrive.
SPF affects whether your sent mail looks trustworthy. It helps receiving servers decide if your domain is being used properly. It is often checked alongside DKIM and DMARC, two other email authentication tools.
SPF alone is not perfect. Forwarded email can fail SPF checks because the forwarding server was not in the original SPF record. That is one reason DKIM and DMARC matter too. Still, SPF is one of the first records you should set when sending email from a domain.
Common DNS Setup Pattern
A typical business email DNS setup may include:
- MX records: Point inbound mail to Google Workspace, Microsoft 365, Zoho, or another provider.
- SPF record: Lists approved sending services.
- DKIM record: Adds a cryptographic signature to outgoing mail.
- DMARC record: Tells receivers what to do when SPF or DKIM checks fail.
It drives me crazy that some DNS panels hide TXT records three clicks deep, then cache old values long enough to make you question reality. Expect to wait anywhere from a few minutes to 48 hours for DNS changes to fully spread, though many updates appear much sooner.
How to Check Your MX and SPF Records
You can check records with online DNS lookup tools or command line tools.
For MX records, search for the domain’s MX entries. You should see the mail servers supplied by your email host.
For SPF, search for TXT records and look for one that starts with:
v=spf1
Watch for duplicate SPF records. A domain should normally have only one SPF record. If you publish two separate SPF records, some receivers may treat SPF as invalid. Instead, merge approved services into a single SPF string.
Best Practices for MX and SPF
- Use the exact MX records from your email provider. Do not guess server names.
- Remove old MX records after switching providers.
- Keep SPF short and clean. Too many includes can cause lookup limits.
- Update SPF when adding senders such as CRMs, help desks, invoice tools, or newsletter platforms.
- Add DKIM and DMARC for stronger protection against spoofing.
- Test before major launches. Check DNS before sending campaigns or moving mailboxes.
Final Takeaway
MX records and SPF records are not rivals. They solve different email DNS problems. MX records tell the world where to deliver mail for your domain. SPF records tell the world which servers may send mail on your domain’s behalf.
If you are troubleshooting email, start with the direction of the problem. Not receiving mail? Check MX first. Sent mail going to spam or failing authentication? Check SPF, then DKIM and DMARC. Get these basics right, and email becomes far less mysterious.