Free, more with Pro

Astro and Next.js analytics in WordPress

One script tag on an Astro, Next.js or any other front end sends pageviews back to Vireo in WordPress. A headless front end counts against your posts. A separate site, connected, gets its own numbers in the same dashboard.

Plan
Free, more connected sites with Pro
Install
A script tag before </body>
Single-page apps
Astro view transitions counted; data-spa="history" for others

Two ways to connect

  • Headless front end: a decoupled front end for this WordPress site. Pages are matched to posts by path, or by a vireo:post-id meta tag, so post stats work as usual. The free plugin allows one front end.
  • Connected site: another site, WordPress or not, with its own numbers. A selector on the Overview switches between sites. Free allows one. With Vireo Pro, each install can connect one plus one for every site your license has unused.
  • A connected site can add a second tag that collects Core Web Vitals. Its pages are listed by address, and per-post reports, Search Console and Pro's reports stay with the WordPress site.

Set it up

  1. For a headless front end, go to Vireo Analytics, Settings, Tracking, Headless front end. Enter the "Front-end site address" and click "Save settings".
  2. For a separate site, go to Settings, Tracking, Connected sites, enter a "Site name" and "Site address", and click "Connect site".
  3. Copy the tag Vireo shows and paste it before </body> on every page. Always copy it from the settings screen, because the endpoint depends on your host.
<script defer src="https://cms.example.com/wp-content/plugins/vireo-analytics/assets/js/tracker.js" data-endpoint="https://cms.example.com/..."></script>

Free or Pro

Free: one headless front end and one connected site. Vireo Pro adds one connected site for every site your license has unused. See pricing.

Worth knowing

  • Pageviews sent from any other address are refused, so the tag records nothing if it's pasted somewhere else.
  • Crawlers that read the front end never reach WordPress, so bot and AI crawler figures cover WordPress only.
  • Core Web Vitals aren't collected from a headless front end yet.
  • Even with Pro, there's one headless front end per WordPress site.

Docs

Related integrations

All integrations

Try Vireo on your own site

Vireo Analytics is a free WordPress plugin. It counts visits without cookies and keeps everything in your own database. Vireo Pro adds revenue, goals and the rest.

Get Vireo free on WordPress.org