Install with Google Tag Manager
Deploy XPmetric via a GTM Custom HTML tag triggered on all pages.
Use Google Tag Manager when you can't edit theme code directly or want tag management in one place.
Replace YOUR_SITE_TOKEN with your site token from Settings → Sites → Get Script.
Tracking snippet
<script defer data-site="YOUR_SITE_TOKEN" src="https://xpmetric.com/p.js"></script>Steps
- Open Google Tag Manager for your container.
- Click Tags → New.
- Tag type: Custom HTML.
- Paste the tracking snippet into the HTML field.
- Trigger: All Pages (or an equivalent init trigger).
- Save and Publish the container.
Verify
Use GTM Preview mode or visit your site after publish. Pageviews should appear in the XPmetric dashboard live feed.
CSP note
If your site sets a strict Content-Security-Policy, allow https://xpmetric.com in script-src and connect-src. See CSP troubleshooting.