Skip to content

GA4 & Audits8 min read

WooCommerce GA4 Purchase Tracking: How the Google Analytics Extension Works and Where Sales Go Missing

The Google Analytics for WooCommerce extension sends purchases and shopping events to GA4, but only under certain conditions. This guide explains how it works from WooCommerce's own documentation, why some sales never reach GA4, and how we close the gaps.

Sakib Hossain, Founder & Lead Tracking Engineer
Founder & Lead Tracking Engineer
All Articles
In shortWooCommerce stores usually start GA4 tracking with Google Analytics for WooCommerce, the free extension WooCommerce maintains. It handles the basics well, but store owners often find that GA4 shows fewer purchases than WooCommerce. Most of the gap comes from a few documented conditions: how the payment gateway returns the buyer, consent, and duplicate tags. This guide walks through them using WooCommerce's documentation and the plugin's changelog.

What the extension tracks

WooCommerce's documentation lists purchase transactions, add to cart and remove from cart, product impressions and clicks from listing pages, product detail views, checkout started, and 404 errors. The plugin's changelog names GA4 events such as add_to_cart, view_item, view_item_list, add_shipping_info and purchase.

You connect it under WooCommerce, then Settings, then Integration, then Google Analytics, by entering your GA4 Measurement ID, which starts with G-. The documentation says the field accepts one ID and that it can take up to 48 hours for the connection to start working.

Related: WooCommerce: Google Analytics for WooCommerce

Why some purchases never reach GA4

The most important line in WooCommerce's documentation is about purchases: tracking them requires a payment gateway that redirects to the thank you or order received page after payment. The purchase event fires in the buyer's browser on that page. If the gateway doesn't send the buyer back, or the buyer closes the tab before it loads, GA4 never hears about the sale.

The plugin's changelog for version 2.4.4 adds a related fix: it stops sending the purchase event for failed and cancelled orders, so a later successful payment for the same order is still tracked. Keep the extension updated, because fixes like this change your numbers.

tip: Compare GA4 purchases with WooCommerce orders by payment method. If one gateway shows far fewer purchases in GA4, check whether it returns buyers to the order received page.

Related: Plugin changelog (readme)

Consent decides what GA4 can see

WooCommerce's documentation says users in the EEA, UK and Switzerland must grant cookie consent before analytics tracking is activated. The extension doesn't include a cookie banner. It works with the WP Consent API, so you need a consent plugin that supports it.

Developers can change the default consent values sent to Google with the woocommerce_ga_gtag_consent_modes filter. The changelog for version 2.4.2 says the plugin now sends an explicit denied state for undecided visitors on opt-in sites. Expect fewer GA4 purchases than orders wherever visitors decline or ignore the banner; that gap is consent working as intended, not a bug.

Duplicate tags double the numbers

The plugin's FAQ warns that duplicate Google Analytics code causes a conflict in tracking and tells you to remove other Google Analytics plugins or code. WooCommerce's documentation also notes that multiple tracking code instances on the same page can cause issues.

In audits we usually find the second copy in a theme setting, an SEO plugin, a page builder or a Google Tag Manager container that also sends GA4 ecommerce events. Pick one source for GA4 ecommerce data and remove the rest.

What to do
  • Open the order received page with Tag Assistant and count how many purchase events fire for one order.
  • Check theme settings, SEO plugins and GTM for another GA4 configuration with the same Measurement ID.
  • Keep one source of GA4 ecommerce events, then test a full order again.

Things that confuse testing

WooCommerce's documentation says pageviews are not tracked for logged-in admin users, so test in a private window as a customer. It also asks you to confirm that no browser extension or ad blocker is blocking tracking while you test.

The product identification setting lets you send the Product ID or the SKU, with the ID as a fallback. Choose one and keep it, because changing it splits your product reports in GA4.

When the extension isn't enough

The extension sends events from the browser, so it can't record a sale when the buyer never reaches the order received page, and the WooCommerce pages we checked don't describe a server-side option. Stores with off-site payments, high-value orders or Google Ads and Meta campaigns that bid on purchases usually need more: a purchase sent from the server when the order is paid, using the same transaction ID so it can be matched and deduplicated.

Google's GA4 event reference requires transaction_id on the purchase event and says it helps you avoid duplicate events for a purchase. Use the WooCommerce order number for it everywhere: in GA4, in your Google Ads conversion and in your Meta event ID.

Related: GA4: purchase event reference · Our guide: GA4 and Google Ads conversions not matching · Our guide: Meta Pixel not tracking purchases

Sources

The features, settings and conditions above come from WooCommerce's documentation and the plugin's listing and changelog (version 2.4.5), checked on 30 November 2026.

Related: Google Analytics for WooCommerce documentation · Plugin page on WordPress.org · Plugin readme and changelog · GA4 purchase event reference

Problems and fixes

1GA4 shows fewer purchases than WooCommerce

Symptom
Orders are higher in WooCommerce than purchases in GA4.
Cause
The gateway doesn't return buyers to the order received page, visitors decline consent, or an ad blocker stops the tag.
Fix
Compare by payment method, fix gateway redirects where possible, and send purchases from the server for gateways that can't redirect.

2Purchases counted twice

Symptom
GA4 shows about double the revenue for some days.
Cause
Two GA4 setups send purchase events, for example the extension and a GTM container.
Fix
Keep one source of GA4 ecommerce events and remove the other.

3Nothing tracked after setup

Symptom
No data in GA4 a few hours after connecting.
Cause
WooCommerce says the connection can take up to 48 hours, and admin pageviews aren't tracked.
Fix
Wait, then test as a logged-out customer in a private window without an ad blocker.

4No data from European visitors

Symptom
Traffic from the EEA, UK or Switzerland is missing.
Cause
Tracking waits for consent, and no consent plugin is passing the choice through the WP Consent API.
Fix
Install a consent plugin that supports the WP Consent API and test accept and reject.

Implementation Checklist

Verify each milestone before deploying changes to live production ad accounts.

  • ✓GA4 Measurement ID entered once, under WooCommerce Integration settings
  • ✓Payment gateways return buyers to the order received page
  • ✓Only one GA4 ecommerce setup on the site
  • ✓Consent plugin supports the WP Consent API
  • ✓Extension kept up to date
  • ✓Test order placed as a logged-out customer
  • ✓Order number used as transaction_id everywhere
Tags:WooCommerceGA4Purchase trackingEcommerce trackingConsentWordPress
The takeawayGoogle Analytics for WooCommerce is a sound starting point when buyers return to the order received page and only one GA4 setup runs on the site. Check those two things first, add a consent plugin that speaks the WP Consent API, and test as a customer. If your gateways send buyers elsewhere or your ads bid on purchases, add a server-side purchase with the order number as the transaction ID.

Frequently asked questions

Does Google Analytics for WooCommerce track purchases?

Yes, when the payment gateway redirects the buyer to the thank you or order received page after payment. WooCommerce's documentation states that requirement.

Does the extension include a cookie banner?

No. WooCommerce says it doesn't provide a banner and integrates with the WP Consent API, so you need a consent plugin that supports it.

Can I use the extension and Google Tag Manager together?

Only if they don't both send GA4 ecommerce events. The plugin's FAQ warns that duplicate Google Analytics code causes conflicts.

Why don't I see my own test visits?

WooCommerce says pageviews aren't tracked for logged-in admin users. Test as a logged-out customer.

How long does it take for data to appear?

WooCommerce says the connection can take up to 48 hours to start working.

Want us to set this up for you?

This is the kind of work we do for clients every week. Tell us about your setup and we'll take it from there.