Install
This is the repository archive. It installs, but the folder name will carry the branch suffix and updates will not flow.
Install straight from GitHub with WP-CLI:
wp plugin install https://github.com/bvankat/wp-ga4-author-category-tracking/archive/refs/heads/main.zipNo built-in updater. New versions won't appear under Dashboard → Updates. Install new releases yourself, or let Git Updater track the repository.
Wordpress Author and Category Tracking for Google Analytics (GA4)
Add custom dimensions to your GA4 instance to track post authors and post categories.
- In your GA4 instance, you'll need to add custom dimensions for "post_author" and "post_category." (Admin > Data Display > Custom definitions). For each dimension, set the Scope to "Event."
- Install and activate the plugin.
Plugin could pretty easily be expanded to include other WP variables beyond author and categories.