Sitecore Experience Accelerator

Add a cookie warning message to your site

If you want to be General Data Protection Regulation (GDPR) and ePrivacy compliant, you must inform your users about collection and sharing of personal information. SXA lets you inform visitors that your site uses cookies. You can customize the message, select the warning type, and exclude pages from having cookie warnings.

To add a cookie warning to your pages:

  1. In the Content Editor, navigate to sitecore/Content/<tenant>/<site>/Settings/Privacy Warning.

  2. In the Privacy Warning Content section, fill in the following fields:

    Field

    Description

    Privacy Warning Content

    Enter your cookie warning statement.

    Privacy Warning Button Text

    Enter the button text. By default, it is set to Confirm.

    Privacy Warning Type

    Select the type of warning:

    • Hidden - hides the cookie notification.

    • Permissive - if the user does not give consent, log a warning and continue running as normal.

    • Restrictive - if the user does not give consent, the user cannot continue using the site.

    • Show Once - after consent, the alert will not display again.

    • Accept on Close - if the user closes the warning, it will be interpreted as consent.

    Pages on which privacy warning will not appear

    Click Edit, and in the Select items dialog box, select the pages that you do not want the privacy message to appear on.

    Learn More Button Target

    Enter a link to a privacy policy.