If you’re not using Consent Manager to collect and manage visitor consents for being tracked, you can use the opt-out form that will give the visitor a choice to opt out of tracking. This mechanism is not compliant with the GDPR regulations, and if you run your website in countries regulated by the GDPR it’s better to use Consent Manager. In other cases, you can use the opt-out mechanism.
In this article, we’ll explain how to install the opt-out form on your website and how it affects tracking.
Here’s an example of an opt-out form on a privacy policy page.

Before you start
Here are some things to know before you add an opt-out form to your website:
- Visitors are opted-in by default. When they check the opt-out checkbox on the form, they will be opted out.
- You can adjust the code with an opt-out form to fit your website’s design.
- When you use an opt-out form, make sure that each tag has turned on the following option: Respect opt-out and DNT. When this option is turned on, the tag will not be fired for visitors who opted out. This option is turned on by default, but double-check that it hasn’t been changed in the meantime.
Add an opt-out form to your page
To install the opt-out form on your website, follow these steps:
Available from version 16.0.0. For versions below 16.0.0, go to Menu > Administration > Platform > Opt-out generator.
- Go to Menu > Administration.
- Navigate to Settings.
- On the left, click Opt-out form.
- Type the message you want to show to your visitors.
- Click Preview to see how the message will sound once installed on your website. The message will inherit your website’s CSS styles so it will look different from this preview.
- When you’re happy with how the form looks, copy the code and paste on your website.
- Now the opt-out form is on your page. To make sure it’s ready to use, you need to check if tags have turned on the following option: Respect opt-out and DNT.
- Go to Menu > Tag Manager.
- Navigate to Tags.
- On the left, click Piwik PRO.
- In Advanced tag settings, turn on Respect opt-out and DNT.
Note: If turned on, this tag won’t fire for visitors who opt out of tracking using our consent form. Make sure that all tags that you use to collect data have this option turned on.
- Click Save for the tag.
- Check other tags.
- You can also use debug mode to check how tags behave for opted-out visitors. In the top-right corner click Debug.
- Your website will open in a new tab with debug mode running.
- Toggle Simulate opt-out.
- You’ll see a note
Opted out
for each tag that has Respect opt-out and DNT turned on.
- When you’re happy with how the tags work, click Publish.