This is done by adding the sender’s IP address or domain in an SPF record published on the website’s Domain Name System (DNS), which tells the receiving system which domains are allowed to send emails.
This record includes the approved IP addresses of email senders, plus the IP addresses of the email service providers (ESPs) that send emails on behalf of the website.
Why do you need SPF?
SPF authentication is how receiving servers spot and stop phishing and other email-based threats from email addresses or domain spoofing.
So, a recipient server checks the SPF record to ensure the sender is genuinely entitled to use the domain and email address the email message is from. The SPF record proves that you’re a legitimate and trustworthy sender.
Let’s say you created an SPF and added it as a TXT record to your DNS. Anytime an email is sent from your domain, the receiving system checks for a valid SPF record.
If the IP sending the email is on the list, it gives the email a PASS tag (in which case the email is properly delivered).
If the IP address sending the email is not on the list, it gives a FAIL tag (in which case the email bounces or lands in the spam folder).
Creating a SPF record ensures safe deliverability, but it also helps protect your domain’s reputation.