REMINDER
How to set up Google analytics IP anonymization
-
Hi guys,
due to GDPR reasons in Europe I have to setup Google Analytics with IP anonymization.
I could get GA up and running here:But how do I disable IP tracking? As far as I know I have to add some lines to existing code. But where do I find the source code for GA?
Thanks a lot!
Phil -
Hey Phil, this feature will activate the regular Google Analytics / Google tag manager code
For your use case you need more control, so I suggest you remove that config from your project settings then instead add your custom tracking code with this feature: https://changelog.appdrag.com/features/add-custom-html-code-on-your-entire-project
-
Thanks Joseph for your help!
For other user, that might be interested in this topic as well:
I have included following script at the very top of the global header section of my project (see Josephs link) :<!-- IP anonymization with gtag.js - Google Analytics --> <script async src="https://www.googletagmanager.com/gtag/js?id=G-xxxxxx"></script> <script> window.dataLayer = window.dataLayer || []; function gtag() { dataLayer.push(arguments); } gtag('js', new Date()); gtag('config', 'G-xxxxxx', { 'anonymize_ip': true }); </script>
Hope that works...