Background:
Chrome and other browsers have made recent changes to how “3rd party” cookies are handled, when content is embedded via an iframe:
Specifically, browsers now require 3rd party cookies to set the “SameSite=None; Secure” attributes.
Our case:
We use Hubspot to build our marketing website. We embed some of the pages from our website in our application, using an iframe. In this case, any cookies created by the website are considered to be “3rd party”, if they do not have the same domain as the parent app. But unfortunately, Hubspot websites don’t appear to create cookies which are compatible with the new browser policy.
The result:
When users visit our website content (usually blog articles, etc.), again which are displayed within an iframe, they get asked to approve our tracking policies. But since the cookies used to track their response cannot be stored, they re repeatedly asked to approve after each view of the same content.
Th “idea”:
Set the “SameSite=None; Secure” attributes on all cookies set by Hubspot website pages.
Hello @KKauper, were you able to find a workaround to this issue?
I’m running into the same issue with HubSpot cookies while trying to make user of the HubSpot Survey Forms. I opened a post here: https://community.hubspot.com/t5/APIs-Integrations/Enable-SameSite-None-Secure-on-hubspotutk-cookie/m-p/604799#M52001
Any updates from the HubSpot team on this issue?
Hi @shayanjalil ,
No, unfortunately I have not had any feedback on this.
-K
@KKauper
Running into this issue myself. Our website gets embedded in native ads. There is an iFrame inside that iFrame for form submission, which quickly goes wrong.
It took me way too long to figure out that the untracked users were being embedded. Indeed this should be the fix:
SameSite=None; Secure
You can modify the tracking script and make this setting yourself. You can see I also have fixed the “secure” setting, although you could rely on that from the tracking settings dashboard itself.
this._set(t, i.alreadyEncoded ? e : hstc.utils.encodeParam(e, !0), {
expires: s ? ";expires=" + r : "",
expiresTime: s ? n : null,
path: ";path=" + (i.path ? i.path : "/"),
domain: !this.cookiesToSubdomain && this.currentDomain ? ";domain=" + this.currentDomain : "",
secure: ";secure", //this.secureCookie || i.secure ? ";secure" : "",
sameSite: ";SameSite=None" //override
})
Yet for Safari this setting is not making any change as Safari by default blocks all 3rd party cookies. An embedded iFrame setting a cookie for itself is seen as 3rd party, alas.
Even if someone has visited your site before and
SameSite=None; secure
cookie has been set, then Safari still won’t submit it on embedded iFrames.