Google Analytics is the most widely used web analytics platform that tracks website traffic and user behavior. It provides comprehensive…
Full ReviewThe WooCommerce and Google Analytics integration enables ecommerce tracking for your WordPress store, giving you detailed insights into product performance, shopping behavior, checkout funnel drop-off, and revenue attribution by traffic source. Google Analytics 4 (GA4) is the current version, and WooCommerce supports it through official and third-party plugins that send enhanced ecommerce events automatically.
Once configured, Google Analytics tracks the entire customer journey: which products visitors view, what they add to cart, where they drop off in checkout, and what they ultimately purchase. You can see which marketing channels drive the most revenue, which products have the highest conversion rates, and what your average order value is across different customer segments. This data is essential for making informed decisions about marketing spend and store optimization.
The integration uses GA4's enhanced ecommerce measurement, which sends structured event data for product impressions, product clicks, add-to-cart actions, checkout steps, purchases, and refunds. This is far more detailed than basic page view tracking and is critical for any WooCommerce store serious about data-driven growth.
Go to analytics.google.com and sign in. Click Admin (gear icon), then click Create Property. Enter your property name, select your time zone and currency, and click Next. Choose your business category and size, then click Create. Set up a Web data stream by entering your store URL and stream name. Copy the Measurement ID (G-XXXXXXXXXX) — you will need this for the plugin configuration.
In WordPress, go to Plugins > Add New. The recommended options are: the official Google Analytics for WooCommerce plugin (by WooCommerce, free), or MonsterInsights (freemium, more user-friendly), or GTM4WP (if you prefer Google Tag Manager). Search for your chosen plugin, click Install Now, then Activate.
If using the official WooCommerce plugin: go to WooCommerce > Settings > Integration > Google Analytics. Paste your GA4 Measurement ID in the designated field. If using MonsterInsights: go to Insights > Settings and follow the setup wizard to connect your Google Analytics account via OAuth authentication.
In the plugin settings, enable Enhanced Ecommerce tracking (sometimes labeled "ecommerce events" or "detailed ecommerce tracking"). This enables the following GA4 events: view_item, add_to_cart, begin_checkout, add_payment_info, add_shipping_info, purchase, and refund. Make sure all relevant event types are toggled on.
In Google Analytics 4, go to Reports > Monetization. If you do not see the Monetization reports, click Library at the bottom of the left navigation, find Monetization, and click the three-dot menu to publish the collection. The key reports are: Ecommerce purchases (product performance), Purchase journey (funnel visualization), and Checkout journey (step-by-step checkout analysis).
Use GA4's Realtime report to verify events are firing. Open your store in a browser, view a product, add it to cart, and begin checkout. In GA4's Realtime report, you should see the corresponding events (view_item, add_to_cart, begin_checkout) appear within seconds. Also use the DebugView in GA4 (under Admin > DebugView) for more detailed event inspection.
In GA4, go to Admin > Events and find the purchase event. Click the toggle to mark it as a conversion (in newer GA4 versions, this is under Admin > Key Events). This ensures purchases are tracked as key conversion events and appear in attribution reports, audience reports, and advertising integrations.
Most WooCommerce GA4 plugins let you configure: whether to track logged-in user IDs (useful for cross-device tracking), whether to exclude admin and shop manager visits from tracking, which product attributes to send as custom dimensions (brand, category, SKU), and whether to track refund events. You can also configure content grouping to categorize pages by type (product pages, category pages, checkout, blog) for cleaner reporting.
| Data | Direction | Frequency |
|---|---|---|
| Product view events | WooCommerce to GA4 | Real-time |
| Add-to-cart events | WooCommerce to GA4 | Real-time |
| Checkout step events | WooCommerce to GA4 | Real-time |
| Purchase events (with revenue) | WooCommerce to GA4 | Real-time |
| Refund events | WooCommerce to GA4 | On refund processing |
| Product data (name, category, price) | WooCommerce to GA4 | Per event |
The purchase event fires on the WooCommerce "thank you" page. If customers are redirected to a payment gateway (like PayPal) and do not return to the thank you page, the purchase event will not fire. Configure your payment gateway to return customers to your site after payment. Also check for caching plugins that might serve a cached thank you page without the tracking code.
If customers refresh the thank you page, the purchase event can fire again. Most WooCommerce GA4 plugins include duplicate transaction prevention — verify this is enabled in the plugin settings. The plugin should store the order ID and skip re-firing for already-tracked orders.
Slight discrepancies are normal due to timing differences, blocked tracking scripts (ad blockers), and refund handling. GA4 may underreport revenue by 5-15% compared to WooCommerce's actual orders because some visitors block JavaScript tracking. Use WooCommerce as the source of truth for financial reporting and GA4 for behavioral and attribution analysis.
For the most flexible setup, use Google Tag Manager (GTM) with the GTM4WP plugin. This approach pushes WooCommerce ecommerce data to the GTM data layer, where you can configure GA4 tags with custom event parameters, send data to multiple analytics platforms simultaneously, and implement server-side tagging for more reliable tracking. Server-side GTM (using a server container) can also help capture purchase events even when client-side JavaScript is blocked by ad blockers.
Google Analytics Full Review » | All WooCommerce Tools »