How to make your Gmail SPFingly safe…

Gmail has started cracking down on spam and one of these measures is to introduce more strict SPF record checking. This is happening at the end of January.

Firstly, what is SPF? It stands for Sender Policy Framework. An SPF record is a very fancy term for identifying which mail servers and domains can send email on behalf of your domain. When a server receives your SPF record, they are checking and verifying that the messages received from you are in fact from you and your servers.

Having an SPF record is generally considered not only standard practice, but good practice. A surprising amount of hosts still don’t include them by default! It seems like the sensible thing to have in this day and age of cyber security.

About half of the email problems we solve for clients are caused by SPF misconfiguration. Often, this is due to the client changing mail servers but not updating the SPF record to include the new server.

If you see the following error when you try to email an @gmail.com account, then it will be an SPF problem.

Can't send email to gmail. SPF check for [mydomain] does not pass with ip - Web Server - CyberPanel Community

To create an SPF record, you will need to log in to your DNS (Domain Name System) management console. Once you are logged in, you will need to create a new TXT (Simple Text) record for your domain.

The following is a basic example of an SPF record:

v=spf1 mx a ~all
  • v=spf1 specifies the version of the SPF record.
  • mx includes all of the mail servers that are authorized to send email on your behalf, based on your MX records.
  • a includes the IP address of the domain itself.
  • ~all specifies that any other IP addresses that are not explicitly included in the SPF record are not authorized to send email on your behalf.

If you use any third-party services to send email on your behalf, such as a marketing automation platform or a newsletter service, you will need to add their IP addresses to your SPF record as well. You can do this using the include: directive.

For example, if you use MailChimp to send email on your behalf, you would add the following line to your SPF record:

include:servers.mcsv.net

You can also use the include: directive to include the SPF records of other domains. This is useful if you have multiple domains that you use to send emails from.

Once you have created your SPF record, you will need to publish it to DNS. This process will vary depending on your DNS provider.

Once your SPF record is published, it may take up to 48 hours for it to update through the DNS system.

Here are some additional tips for creating an SPF record:

  • Make sure that your SPF record is as simple as possible. Complex SPF records can be difficult for receiving servers to understand and verify.
  • Test your SPF record before you deploy it. You can use an online tool such as this one to test your SPF record.
  • Monitor your SPF record on a regular basis to make sure that it is still accurate and up-to-date.

If you have any trouble creating or managing your SPF record, you can contact Yellow Cherry. We promise we will make it even easier than applying that SPF 30 on your holidays!