PolyCMS Plugin: Google Analytics
Last updated on May 15, 2026 11:21 PM
Overview
The Google Analytics plugin injects your tracking code into the PolyCMS frontend. It supports both GA4 (Google Analytics 4) and Universal Analytics (legacy).
Activation
- Navigate to Blog > Plugins.
- Find Google Analytics and click Activate.
- Click Settings to configure your tracking code.
Configuration
GA4 (Recommended)
Enter your GA4 Measurement ID (format: G-XXXXXXXXXX):
- Go to Google Analytics.
- Navigate to Admin > Data Streams > Web.
- Copy the Measurement ID.
- Paste into the plugin settings field.
Universal Analytics (Legacy)
Enter your UA Tracking ID (format: UA-XXXXXXXX-X).
Note: Google has sunset Universal Analytics. New implementations should use GA4.
Script Placement
Choose where the tracking script is injected:
| Placement | Description |
|---|---|
| Header | Loads in — ensures tracking fires before page content renders |
| Footer | Loads before — slightly faster page load, minimal tracking delay |
Recommendation: Use Header placement for accurate page view tracking.
What Gets Tracked
Once configured, Google Analytics automatically tracks:
- Page views across all frontend pages
- User sessions and bounce rates
- Traffic sources and referrers
- Geographic and device data
- Custom events (if configured in GA4)
Verification
After activation, verify tracking is working:
- Open your blog frontend in a browser.
- View page source and search for your Measurement ID.
- Check Google Analytics Realtime reports for active users.
Related Documentation
- Plugin Management — Activate and configure plugins.
- SEO Configuration — Complementary SEO settings.