HubSpot
HubSpot SPF record: set up DKIM and DMARC step by step
Your HubSpot SPF record comes from your own account. Add it with the two DKIM CNAMEs and a DMARC TXT record, then confirm the Authenticated status.
Check your current setup:
Your HubSpot SPF record is generated by your own account when you connect an email sending domain, so you copy it instead of typing it from a list. The same screen gives you the two HubSpot DKIM records and asks for a DMARC record. This guide goes through them in the order you publish them.
How HubSpot authenticates your mail
HubSpot marks a domain Authenticated only after three checks are verified. SPF (Sender Policy Framework) tells receivers which servers may send for the domain, and here that list comes from the include in your account. DKIM (DomainKeys Identified Mail) signs with a private key; HubSpot’s CNAMEs lead to the public verification key. DMARC checks whether one of those two results matches the domain in the visible From address. That match is called alignment.
Until you connect a domain, HubSpot sends marketing and transactional email through a domain it manages. A From address such as user@example.com becomes user=example.com@hs-domain.com. You must set up DKIM before your own domain can appear in the From line.
SPF is checked against the return-path, the hidden address that collects bounces. HubSpot already configures it for marketing email on its shared servers. It documents a custom return-path, available on Marketing Hub Enterprise, as the way to get SPF alignment. Dedicated IP accounts use a return-path subdomain of their own domain. On a standard shared setup, plan for DKIM to carry DMARC.
Before you start
- You need a Starter, Professional or Enterprise subscription of Marketing Hub, Sales Hub, Service Hub or Content Hub, plus Domain settings permissions.
- Choose a sending domain. For a site on
www.example.com, HubSpot recommends a subdomain such asnews.example.comfor shared senders. Your root domain also works if it does not host content. - The domain you connect should match the domain in your From address.
- Sending domains apply to marketing and transactional email. One-to-one emails use the inbox you connected to those tools.
Step 1: Connect the email sending domain
- Click the settings icon in the top navigation bar.
- In the left sidebar, go to Content > Domains & URLs.
- Open the Email Sending tab and click Connect sending domain.
- Enter an email address you use for marketing emails and click Next.
- Confirm the domain and click Next.
- Click Sign in with [provider] if HubSpot offers it for your DNS provider. Otherwise click No, I'll set it up manually.
- Copy each value from the Host and Required data columns into your DNS provider.
Step 2: Add the HubSpot DKIM records
HubSpot uses two CNAME records for DKIM. The first part of each host is the selector, the label receivers use to find the key. HubSpot's troubleshooting article gives hs1-123456._domainkey as an example host. It shows targets in the form example-com.hs[#]a.dkim.hubspotemail.net and example-com.hs[#]b.dkim.hubspotemail.net.
HubSpot generates these values per domain and publishes no fixed selector list. Copy them from your account. On alignment, the DKIM signature is tied to the domain you connected, so it aligns with a From address on that domain.
If you use Cloudflare, turn off domain-wide CNAME flattening and proxy settings for this domain, as HubSpot asks.
Step 3: Add the HubSpot SPF record
The Required data column holds the value for your account. HubSpot's examples use the form include:123456.spf03.hubspotemail.net. The number and the spf03 part vary, so copy yours from the setup screen.
A domain can publish only one SPF record. If you already have one, add the include to it. For a domain that also uses Google Workspace, the merged record looks like this, with your own include in place of the example:
v=spf1 include:_spf.google.com include:123456.spf03.hubspotemail.net ~all
- Keep
v=spf1and the closingallterm once each. - HubSpot’s
-allexample returns SPF fail for unlisted sources; it does not decide delivery.~allreturns softfail, which RFC 7208 says should not alone cause rejection. Inventory legitimate MAIL FROM senders before changing the ending. - Remove any HubSpot IP addresses you pasted in earlier. HubSpot says its record already covers the IPs your account uses.
- Watch the limit. SPF allows 10 DNS lookups in total across
include,a,mx,ptr,existsandredirect, counted through nested records. Check the total with the SPF checker.
Step 4: Publish DMARC
Check first whether your root domain already has a _dmarc TXT record. If it does, edit that record: add your reporting address to rua and keep its current policy. Do not add a second record, because receivers then discard both. If there is none, create a TXT record named _dmarc on your root domain and start in monitoring mode:
Use this starter value only if no DMARC policy exists at this name. Otherwise edit the existing record, preserving its p=, alignment settings and report addresses; add your monitored rua destination there. Never create a second policy record.
v=DMARC1; p=none; rua=mailto:dmarc@example.com
Replace the address with your DMARC Pulse reporting address, which receives the aggregate reports defined in RFC 9990. HubSpot recommends relaxed alignment. adkim and aspf default to r, so you can leave them out.
HubSpot Support does not manage your DNS or choose your DMARC policy. Your DNS administrator publishes this record.
A subdomain such as news.example.com inherits the record of its Organizational Domain, usually the domain you registered. Receivers find it with the DNS tree walk in RFC 9989. Use the sp tag if subdomains need a different policy.
Step 5: Check the status and enforce
Wait at least 20 minutes after you update DNS. Records usually update in 10 to 70 minutes and can take up to 48 hours. Then open the Email Sending tab and read the status:
- Not authenticated: none of the three methods are verified.
- Partially authenticated: DKIM is verified and SPF or DMARC still needs work.
- Authenticated: DKIM, SPF and DMARC are all verified.
Click Continue setup to review a record that has an issue. Send a test and read the headers with the email header analyzer. Confirm the DMARC record with the DMARC checker. Preserve existing policy, alignment and report destinations. For a first deployment, monitor at p=none; after all legitimate senders align, assess p=quarantine. p=reject is optional and needs a separate mailing-list/forwarding risk assessment. Receivers decide individual delivery.
Common problems
- The domain will not connect because it hosts a site. HubSpot returns an error for a domain already used to host content. Use a separate subdomain. A site on
wwwdoes not block the root domain. - The domain is duplicated in the DKIM host. Some DNS providers append your domain automatically, which produces
hs1-123456._domainkey.example.com.example.com. Enter the Host value without your root domain:hs1-123456._domainkeyfor a root domain. If you connected a subdomain such asnews.example.com, keep its label, as inhs1-123456._domainkey.news. - A
Typo,Missing recordorConflicting recordbanner appears. Compare the records at your DNS host with the values in HubSpot, then click Refresh or check again in the domain setup. TIME_1appears with Cloudflare. HubSpot says that this error after five hours generally means Cloudflare is blocking requests, rather than a propagation delay.- The lookup tip does not match your record. HubSpot's checklist tells you to look for
include:shared.hubspot.comand to use the selectorsmtpapi. Your setup screen can show other values, such as thespf03include andhs1-123456. Compare against what your account shows in Host and Required data. Invalid DMARC policyappears. Theporspvalue is invalid. Usenone,quarantineorrejectin lowercase.- There are two
_dmarcrecords. Receivers discard them, so your policy is not applied. Keep one record that begins withv=DMARC1. - HubSpot's articles still mention
pct. RFC 9989 removed that tag and addedtfor test mode. Roll out enforcement by moving fromnonetoquarantinetoreject. - The domain has a null MX. Some inbox providers reject mail from a domain that publishes
MX 0 ., and HubSpot recommends removing it. A sending-only domain can leave MX unset. - The From address shows
hs-domain.com. The domain is not connected or the address is not verified. You must own and have access to each domain you connect, so a domain you do not control cannot be authenticated.