Using a Cookie to Opt Out from Tracking

When you want to enable customers to opt out from tracking and personalization — based on your security policy, for example — you can set the _SI_DNT cookie to disable the SAS tag. When this cookie is set, the SAS tag does not send any events or present any personalized content. The resulting behavior would be similar to removing the SAS tag from the site for this individual user.

You can set a cookie with different methods. For example, to use JavaScript to set the opt-out cookie:

  1. Set up site logic to enable users to opt out of tracking and personalization.
  2. When a user chooses to opt out of tracking, you could use this JavaScript function to set the _SI_DNT cookie to 1 and send a message to the console:
    function createDntCookie() {
       document.cookie = "_SI_DNT=1";
       console.log('_SI_DNT cookie created');
    }
    Note: Make sure that the value of the _SI_DNT cookie is set to 1 and is not empty.

For more information about JavaScript cookies, see JavaScript Cookies (external) on w3schools.com.

Última actualización: 18 de febrero de 2026