Install on Ghost
Add XPmetric to a Ghost publication through Settings → Code injection → Site header.
Ghost has a built-in place for site-wide scripts, on Ghost(Pro) and self-hosted installs alike.
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 Ghost admin and go to Settings → Code injection.
- Paste the tracking snippet into Site header.
- Click Save.
Verify
Open your published site in a browser, then check the XPmetric dashboard. The first pageview shows up within a few seconds.
The snippet covers every post and page. Member-only pages are counted like any other page.
If nothing arrives, check the CSP troubleshooting guide or reply to your welcome email and we will look at it with you.