Quick answer
SPF lists the servers allowed to send for a domain. Update its existing TXT policy at your public DNS provider. Keep one policy beginning v=spf1 at each evaluated name.
1. Collect the sender requirements
- Identify public DNS and the message's envelope-sender domain, often shown as Return-Path. It can differ from the visible From address.
- Save the current policy and TTL. Preserve unrelated TXT records.
- List mailbox, website, newsletter, CRM and store senders. Get requirements from each administrator. Do not authorize unknown IPs from unsolicited messages or reports.
- For cPanel-sent mail, review Email > Email Deliverability > Manage. External mail services supply their own values. The website IP is not necessarily the sending IP.
2. Keep one valid policy
Combine approved IP mechanisms and provider-specified includes before the final qualifier. This is a fictional example, not a policy to copy:
v=spf1 ip4:192.0.2.10 include:_spf.example.net ~all
~all produces softfail and -all produces fail for unmatched senders. Receivers decide how to handle the message. Avoid +all, which authorizes everyone.
SPF permits at most ten DNS-querying mechanisms/modifiers, including nested lookups. Ten visible includes can exceed that limit. Ask the email administrator to check the complete policy. Avoid manually flattening changing vendor IP lists without a supported maintenance process.
3. Update public DNS
- cPanel DNS: use reviewed SPF customization in Email Deliverability > Manage, or edit the TXT through Domains > Zone Editor > Manage.
- Cloudflare: domain > DNS > Records > edit the existing
v=spf1TXT. Use Add record > TXT only if none exists. - Other providers: use the TXT editor and the provider paths in the overview below. Use
@only when the editor requires it. The obsolete separate SPF record type is unnecessary.
Read the saved record back. Keep MX and website records unchanged. A cPanel repair does not publish to external DNS.
4. Verify DNS and sending
nslookup -type=NS example.com nslookup -type=TXT example.com
Replace the example with the envelope-sender domain. Compare public and authoritative answers if needed, allowing for the previous TTL. Several quoted strings in one TXT record differ from duplicate SPF policies.
Test each sender. Check spf=, smtp.mailfrom= and DMARC alignment in the trusted receiver's headers. Valid DNS alone does not prove every sender works.
Troubleshooting
- Multiple SPF records / permerror: preserve the originals, then combine legitimate senders into one valid policy. Check syntax and nested DNS lookups.
- Fail / softfail: compare the real source and envelope domain with that sender's requirements. Unrelated website or Cloudflare IPs will not fix it.
- SPF passes, DMARC fails: check From-domain alignment or enable aligned DKIM.
- Forwarded mail fails: inspect the forwarding path and DKIM rather than authorizing broad networks.
- Temperror: resolve the DNS availability problem before retrying.
If a change breaks legitimate sending, compare later edits before restoring the saved policy. Fix the underlying sender setup.
Contact support
For cPanel or hosting questions, send the domain, sending service, exact error, time zone and redacted mail headers or bounce message. Keep passwords, cookies, private keys and tokens out of the ticket. Your external DNS or email administrator must supply that service's current records and access.
Related help
- SPF, DKIM, and DMARC
- Enable and verify DKIM signing
- Review DMARC alignment and policy
- Website form sender setup
- Find your active DNS provider
Official references
- SPF specification and DNS evaluation limits
- Google Workspace SPF sender inventory
- Microsoft 365 SPF setup
- cPanel SPF suggestion and customization
- Cloudflare mail-related records
Source review: Interactive Online, November 2, 2026. Controls vary by service, version and permissions.