DMARC - How To Merge Multiple SFP Records

Merging SPF Records

If you're trying to update email sending policies to ensure HubSpot Emails are hitting inboxes and not being auto-tagged as spam by Gmail / Yahoo, you'll have to add a DMARC / SPF Record.  However, an SPF record still may exist in your DNS Settings.  

Your DNS Manager may not allow for multiple SPF records or HubSpot may not allow for multiple records.  

If this is the case, you'll need to merge the pre-existing SPF record and new SPF record for HubSpot into one record.  

We have the following two sample SPF records - the first being a pre-existing record and the second being a record from HubSpot.

v=spf1 a mx include:_spf.elasticemail.com ~all
v=spf1 include:12345678.spf04.hubspotemail.net ~all

 

To merge the SPF values, include all the parts into one single record without repeating any mechanisms.

  • If one of the records (or both) has an “a” mechanism, it should only be included once at the beginning.
  • If one of the records (or both) consists of an “mx” mechanism, it should also be included once.
  • The “include” mechanism is added to specify the mail servers from both SPF records.
  • The last part has to be “?all”, “-all”, or “~all”. It is impossible to have more than one qualifier, so it is your decision to choose which declaration of “all” your domains will use.

The merged SPF record will be:

v=spf1 a mx include:_spf.elasticemail.com include:12345678.spf04.hubspotemail.net -all

 

Reference: 

https://support.cloudways.com/en/articles/5241822-how-to-merge-multiple-spf-records