3

I need to set up a SPF record to allow an alternative IP address to send our newsletter emails. The main IP hosting the site still needs to be allowed to send email also.

Would the following work?

v=spf1 mx ip4:_MAINSITE_ mx:mail._MAINSITEDOMAIN_ ip4:_ALTIP_ -all
1
3

I recently had to do something similar and I found a SPF record wizard hosted on microsoft.com but the resource got removed or moved. See the comment by vaer-k for an alternative.

1
  • The link in this answer is broken, but there are other wizards available, e.g. spfwizard.net – vaer-k Oct 1 '20 at 17:36
1

You don't need to specify the details of your mx records. The correct format would be:

v=spf1 mx ip4:_MAINSITE_ ip4:_ALTIP_ -all

This would allow mail from your two IPs and any mail servers in your mx records

1

Adding a ~all (SOFTFAIL) instead of -all (FAIL) may be useful if in the future, you change some of your IP, this way it will not fail if you don't change the SPF record at the same time with the IP.

Not the answer you're looking for? Browse other questions tagged or ask your own question.