WordPress plugin intelligence profile

AG Data for PostHog

PostHog Analytics for WooCommerce. Server-side event tracking, marketing attribution engine, identity stitching, and LTV enrichment.

WP PlugIndex snapshot

Current directory snapshot

Tested up to WordPress 7.0
Current version1.6.2
WordPress coverageTested up to WordPress 7.0
Minimum stackWP 5.8 · PHP 7.4
Directory statusactive
Last directory update31 Aug 20262mo ago
Active installationsNewAdoption metric — not a quality score
WordPress.org ratingNo WordPress.org ratings yet
Official packageDirect from WordPress.org

Repository metrics are context, not quality scores. Active installations measure adoption and can strongly reflect a plugin’s age and historical popularity. Ratings, recent updates and “Tested up to” metadata also do not guarantee modern code, error-free operation, security, feature completeness or suitability for a particular site. Why active installs don’t tell the whole story →

WP PlugIndex currently records AG Data for PostHog version 1.6.2 as active, updated 2mo ago and tested up to WordPress 7.0.

Overview

About this plugin

AG Data for PostHog connects your WooCommerce store to PostHog — the open-source product analytics platform. Track the complete customer journey from first click to lifetime value, all within PostHog.

Why AG Data?

Most WooCommerce analytics plugins give you pageviews and basic events. AG Data gives you a full marketing attribution engine — first-touch/last-touch UTM tracking, ad click ID capture (Google, Meta, TikTok, Microsoft, LinkedIn), server-side first-party cookies that survive Safari ITP, and automatic LTV enrichment on every person profile.

Key Features

Server-Side Event Tracking

  • Order Completed, Order Refunded, Order Status Changed
  • Product Added — tracked on the server, so it covers every add-to-cart: AJAX buttons on archives, single product pages that post their form, and variable, bundled or optioned products
  • Deduplication prevents double-counting
  • Blocking API calls ensure delivery before marking as tracked
  • Works with all payment gateways and checkout flows
  • apha_event_properties filter attaches your own properties to every server-side event

Frontend Event Tracking

  • Product Viewed, Product List Viewed, Products Searched
  • Product Removed (classic and block-based carts)
  • Cart Viewed, Checkout Started
  • Product Clicked, Coupon Applied / Removed, Payment Info Entered
  • Works without jQuery — block themes fully supported

Marketing Attribution Engine

  • Captures UTM parameters and ad click IDs (gclid, fbclid, ttclid, msclkid, li_fat_id)
  • Server-side first-party cookies bypass Safari ITP 24-hour restriction
  • First-touch and last-touch attribution persisted to every order
  • Days-to-conversion and session count tracking
  • Falls back to WooCommerce 8.5+ native attribution when cookies are unavailable
  • Attribution data included in all PostHog order events

Identity Stitching

  • Reads PostHog JS SDK cookie server-side for seamless funnel connection
  • Browser posthog.identify() for logged-in users
  • Server-side $identify with $anon_distinct_id merges anonymous and known profiles
  • PostHog funnels work end-to-end: Landing Page → Checkout Started → Order Completed

LTV Person Enrichment

  • total_orders, lifetime_value, avg_order_value, last_order_date updated on every purchase
  • first_order_date, acquisition_source, acquisition_medium, acquisition_campaign set once via $set_once
  • Build PostHog cohorts like “Customers with LTV > $500 acquired from Google Ads”

GDPR / Consent Management

  • Optional consent mode: starts PostHog opted-out with memory-only persistence
  • Exposes aphaOptIn() / aphaOptOut() JavaScript functions
  • Built-in support for CookieYes and Complianz consent management platforms

WooCommerce Compatibility

  • HPOS (High-Performance Order Storage) compatible
  • Cart and Checkout Blocks compatible
  • Classic and block checkout flows supported
  • Reverse proxy support for first-party tracking domains

Requirements

  • WordPress 5.8+
  • WooCommerce 7.0+
  • PHP 7.4+
  • A PostHog account (free tier available at posthog.com)

External services

This plugin connects to PostHog, a third-party product analytics service, to send your store’s analytics and e-commerce event data. This connection is required for the plugin to work — its entire purpose is to record analytics in PostHog. No data is sent until you enter a PostHog Project API key in the plugin settings.

What PostHog is used for:

  • Receiving server-side e-commerce events (Order Completed, Order Refunded, Order Status Changed).
  • Receiving frontend browsing events (Product Viewed, Cart Viewed, Checkout Started, and similar) via the PostHog JavaScript SDK, which is loaded on your site’s pages from your configured PostHog host.
  • Storing person profiles enriched with order/LTV data and marketing attribution data.

What data is sent, and when:

  • While a visitor browses your store, the PostHog JavaScript SDK captures pageviews and browsing events. This includes page URLs, referrer, UTM parameters, ad click IDs (gclid, fbclid, ttclid, msclkid, li_fat_id), and a PostHog-generated anonymous identifier.
  • When an order is placed, refunded, or changes status, the plugin sends order data from your server — order ID, totals, currency, line items, payment and shipping method, and billing/shipping country. For logged-in users, a WordPress-based identifier and the customer email may also be sent so anonymous and known profiles can be merged.
  • Requests are sent to the PostHog host you configure in the settings (PostHog US Cloud, PostHog EU Cloud, or your own self-hosted/proxy URL).

Service provider: PostHog Inc.

com/terms

com/privacy

WordPress.org metadata

Plugin tags

Topics listed for this plugin in the WordPress.org directory.

  • analytics
  • attribution
  • ecommerce
  • posthog
  • woocommerce
Compatibility & maintenance

Compatibility & maintenance

Tested up to WordPress 7.0

Not yet marked as tested with WordPress 7.1. WordPress.org currently lists Tested up to 7.0.

Current WordPress releaseWordPress 7.1
WordPress.org Tested up to7.0
Minimum requirementsWordPress 5.8 · PHP 7.4
Update activity31 Aug 20262mo ago

“Tested up to” is directory metadata supplied by the plugin author. WP PlugIndex does not turn an older declaration into a claim that the plugin is incompatible.

Changes recorded by WP PlugIndex

Recent tracked changes

No tracked version or compatibility changes have been recorded by WP PlugIndex yet.

Tracking & source

WP PlugIndex tracks public WordPress.org directory metadata and records selected version, compatibility and availability changes as they are detected.

Plugin watchlist

Watch this plugin

Sign in to your WP PlugIndex account or create a free account. Free accounts can watch up to 5 plugins and see what changed.

Watch limit

Watchlist limit reached

You have reached your current active watch limit.