WvonR
WvonR

Reputation: 158

Google Tag Manager fire tags only when user accepts policy on cookies

In some countries you are allowed to collect basic tracking cookies that are used to improve site functionality but have to notify the user (e.g. with a Popup) when you are collecting cookies for marketing purposes.

Does anyone know if it is possible to use Google Tag Manager (GTM) to have the basic tracking tags fired on all pages and setup a trigger to fire the marketing tags only when the cookies are accepted. Either by having the confirmation result into a binary custom variable and build that into a trigger.

Love to hear your thoughts on this one!

Upvotes: 2

Views: 4334

Answers (3)

Jan Jankowski Janek
Jan Jankowski Janek

Reputation: 57

You can use custom variables on user level https://developers.google.com/analytics/devguides/collection/gajs/gaTrackingCustomVariables

I use this for log in feature. In GA report You can track users who accept or dont accept Your policy.

Upvotes: 0

ePetkov
ePetkov

Reputation: 422

You can create Lookup table to check if the cookies are accepted or no, and to fire custom event (like true and false). Afterwards just add Exception in your firing triggers for the event which is for declined policy or add firing rule for the accepted ones (doesn't matter which one).

The fun part of rejecting cookies policy is that you should accept cookie to hold your decision, or you'll get that popup every on pageview. That's why you should create a cookie too, to hold your event, otherwise your "forbidden" tags will fire on the second page-view.

Upvotes: 1

mrbubu
mrbubu

Reputation: 484

Yes, it is possible. For example, if user accepts policy by clicking on some button, then you can use this click in your triggers.

Upvotes: 0

Related Questions