Skip to main content
All CollectionsSettings and Troubleshooting FAQ
How can website visitors opt-out of cookies and data collected and processed by Nosto ?
How can website visitors opt-out of cookies and data collected and processed by Nosto ?

In the context of GDPR or similar legislation, what should you do if a customer asks you to disable cookies and data processed by Nosto.

Lari Lehtonen avatar
Written by Lari Lehtonen
Updated over 3 years ago

Should there be a need, you can disable Nosto for a given customer if they don't give consent for data processing or if legal reasons such as COPPA requires to disable Nosto for an individual. 

This method disables the initialization of Nosto entirely, meaning that all associated Nosto features on your web store for that user are also disabled.

You will need to wrap the Nosto script in a conditional that activates only if the customer has accepted to activate Nosto. Below is an example that simply checks for the existence of a cookie called accepts_marketing but you should change the conditional to match your consent management implementation.

<script type="text/javascript">
if (document.cookie.indexOf('accepts_marketing') >= 0) {
  var head = document.getElementsByTagName('head')[0];
  var js = document.createElement("script");
  js.type = "text/javascript";
  js.src = "//connect.nosto.com/include/$accountID";
  head.appendChild(js);
}
</script>

Did this answer your question?