Install AlpiStats on Google Tag Manager
Allow five minutes for the basic step. First create your account and add your site: the installation screen gives you your personal code and confirms the first visit live.
- 1In the container, create a tag of type “Custom HTML”.
- 2Paste the AlpiStats code.
- 3Choose the “All Pages” trigger.
- 4Save, then publish the container.
If your consent manager controls Tag Manager, link it to AlpiStats: measurement only starts after the visitor’s consent.
The code to paste
It looks like this; yours contains your site’s identifier.
<script defer src="https://t.alpistats.ch/a.js" data-site="YOUR-IDENTIFIER" data-notice="true"></script>
Check
Open your site in another tab: the AlpiStats installation screen turns green as soon as the first visit is received. Nothing after two minutes? The “Test my site” button checks that the code is present and that the site’s security policy (CSP) allows it.