Revoke Hubspot cookies from external site

SOLVE
cmelojakob
Member

Hello, I have a question regarding the use of Hubspot cookies on our site. The site is not built on Hubspot but we do some Hubspot popups/chat. 

Right now, we are working on updating our cookie policy and giving site visitors/users the option to opt in / out of cookies. 

How/where are these cookies (such as hubspotuk and __hssrc) set, and can we give visitors the option to block them?

Users should be able to block all but essential cookies in order to be in line with privacy laws in our country. 

I did look here: https://knowledge.hubspot.com/reports/customize-your-cookie-tracking-settings-and-privacy-policy-ale...

But that page seems to only cover adding a privacy alert from Hubspot onto our site. we need a way to block the cookies from our side based on whether the customer opts in or out. 

I have also tried to follow the mentioned steps to place do not track cookie, however it didn't work.

These are the relevant cookies we are inquiring about: 

hubspotutk, __hssc, __hssrc, __hstc.

 

Similar question has been posted in this thread but no follow up.

0 Upvotes
2 Accepted solutions

Accepted Solutions
WendyGoh
Solution
HubSpot Employee

Hey @cmelojakob,

 

Thanks for the clarification! 

 

In this case, you're spot on. If the cookie banner isn't provided by HubSpot, your team wouldn't be able to use the remove cookies function. I'll have to check in with my team to see if there's a way to remove cookie from the HubSpot tracking code on your external banner. I'll keep you posted here!

View solution in original post

0 Upvotes
WendyGoh
Solution
HubSpot Employee

Hey @cmelojakob,

 

Here's an update from our internal team! 

 

I'd first like to say that, when we decided to separate the banner out from the tracking code we also made the decision to handle cookie removal etc in the banner code instead.

 

In this case, your team would have to remove the cookies by writing some javascript.

 

Here are the tracking cookies that the banner removes when we call revokeCookieConsent.

__hssc,
__hssrc,
__hs_do_not_track,
__hstc,
hubspotutk,
messagesUtk

 

Example script in which you can remove those cookiesJavaScript Cookie.

View solution in original post

0 Upvotes
6 Replies 6
WendyGoh
HubSpot Employee

Hey @cmelojakob,

 

These cookies: hubspotutk, __hssc, __hssrc, __hstc are known as consent banner cookies and when looking to remove these cookies, you would need to use the Remove cookies function. 

 

Hope this helps! 

cmelojakob
Member

I have tried using that:

_hsp.push(['revokeCookieConsent']);

However the cookies are not removed nor does the tracking stops being sent to Hubspot.

Should this piece of code actually work even if I am not using the cookie banner provided by Hubspot? As I said, I am managing consent from my site using a custom cookie banner.

0 Upvotes
WendyGoh
Solution
HubSpot Employee

Hey @cmelojakob,

 

Thanks for the clarification! 

 

In this case, you're spot on. If the cookie banner isn't provided by HubSpot, your team wouldn't be able to use the remove cookies function. I'll have to check in with my team to see if there's a way to remove cookie from the HubSpot tracking code on your external banner. I'll keep you posted here!

View solution in original post

0 Upvotes
cmelojakob
Member

Hi @WendyGoh,

 

Thank you for your quick reply. 

 

I will be waiting for a reply and will follow up soon if I don’t hear anything as so far this has not yet been resolved (not sure why it has been marked as an accepted solution).


It is important to give users the right to revoke consent at any time if they wish under the current law. Furthermore, considering the scripts and cookies can be initialized/placed from an external source (i.e. our own site, NOT built on Hubspot), should there not also be a mechanism to remove those cookies? In other words, Hubspot has provided a piece of code to allow us to use and add their cookies on our own site, but (so far), no way of removing those cookies.

 

Again, I will follow up on this post here, if I don’t hear from you (or your team) soon.

0 Upvotes
WendyGoh
Solution
HubSpot Employee

Hey @cmelojakob,

 

Here's an update from our internal team! 

 

I'd first like to say that, when we decided to separate the banner out from the tracking code we also made the decision to handle cookie removal etc in the banner code instead.

 

In this case, your team would have to remove the cookies by writing some javascript.

 

Here are the tracking cookies that the banner removes when we call revokeCookieConsent.

__hssc,
__hssrc,
__hs_do_not_track,
__hstc,
hubspotutk,
messagesUtk

 

Example script in which you can remove those cookiesJavaScript Cookie.

View solution in original post

0 Upvotes
AxelA
Member

I'm also experiencing issues with this toppic. Same cookies as mentioned above

 

We are using the CookieFirst script in combination with Google Tag manager to manage cookies. Please provide detailed documentation on how to remove those cookies

0 Upvotes