Connecting WooCommerce to BigQuery
WooCommerce keeps the order in your own database, which is both the advantage and the reason nobody has wired it properly. BigQuery has no attribution model, no deduplication rules and no opinion about your data — which makes it the only destination on this site where every number is exactly as good as the query that produced it. The join between them succeeds or fails on one thing: whether whatever join key you decide on reaches the WooCommerce order before the conversion happens, because BigQuery can only match a conversion it can tie back to a click it recognizes.
Free30 minutesNo obligation
Specific to this pair
WooCommerce into BigQuery: HPOS tables, statuses and GA4 joins
Check whether the WooCommerce store uses High-Performance Order Storage, since order and meta tables differ and queries silently break after migration. Load orders with status, totals, currency and click-identifier meta plus line items, pulled incrementally on modified date and deduped on order ID. Pin the conversion status set, and match order numbers to GA4 transaction_id.
Before loading anything, check whether the store uses High-Performance Order Storage. With HPOS on, orders and their meta live in dedicated order tables; on older stores they live in the posts and postmeta tables. An extraction query written for one silently returns nothing, or stale data, after a migration to the other, and click identifiers you stored as order meta move with it.
Load orders with status, totals, currency and the order meta holding click identifiers, plus line items with product and variation IDs. Pin the status set in the query that defines a conversion, since processing, completed, on-hold and refunded orders all exist and each team will otherwise pick a different combination. If GA4's BigQuery export is on, the order number should match the ecommerce transaction_id in the export, which lets you see which purchases GA4 never recorded, usually those whose thank-you page was cached or blocked.
Pull incrementally on order modified date, not created date, so refunds and status changes reach the warehouse. Then dedupe on order ID keeping the latest version, because incremental loads repeat orders by design, and reconcile one closed month against WooCommerce's own reports.
WooCommerce → BigQuery · what breaks
Why this join usually fails — WooCommerce → BigQuery
- 01
Whatever join key you decide on never reaches WooCommerce
WooCommerce sites are usually the most heavily plugged-in of any platform. Caching plugins serve a static page to the visitor, optimization plugins defer or strip scripts, and consent plugins block them entirely. Any of the three will stop an identifier being captured, and they fail silently.
- 02
Caching and optimization plugins eat the tracking
The page the customer sees is not the page your code assumed. This is the most common cause of WooCommerce tracking that worked at launch and silently stopped after a plugin update.
- 03
The warehouse quietly disagreeing with every platform
This is not a bug — it is the point. Your warehouse counts orders; Google counts click-attributed conversions in its window; Meta counts differently again. When the four numbers differ, the warehouse is usually right about revenue and wrong about attribution, and knowing which question you are answering is the whole skill.
- 04
Nothing reconciles afterwards
BigQuery will not tell you anything is wrong. Verify by querying the table directly against your source system's own totals, and check for duplicate rows on the join key before trusting any aggregate.
WooCommerce → BigQuery · the fix
What working looks like — WooCommerce → BigQuery
Whatever join key you decide on on every order
Conversions arriving in BigQuery
The row lands in a table you own, joinable to every other table you own, with no window and no expiry.
Reconciled against the source
WooCommerce → BigQuery · architecture
How WooCommerce and BigQuery actually connect
- 1
WooCommerce holds the truth
You own the database, so the truth is exactly as good as the query you write against it. Pin the status set first — whether processing, completed, or both count as a conversion changes the number by a lot and is the source of most arguments.
- 2
BigQuery needs a click to match
BigQuery needs a schema and consistent types. The failure mode is not rejection, it is silent divergence: a column that arrives as a string in one load and an integer in the next, or a timestamp in the wrong zone, which produces answers that look plausible and are not.
- 3
The identifier is the bridge
Whatever join key you decide on, captured at the visit and carried into the WooCommerce order.
- 4
The event source decides reliability
Fire server-side from the PHP hook rather than from the thank-you page template. Page caching means the thank-you page cannot be relied on to execute anything, and on many stores it is served from cache to a paying customer.
- 5
Deduplication at the destination
Nothing deduplicates for you. Streaming inserts are at-least-once, so a retried load can create duplicate rows, and the only protection is a deduplication step you write and actually run.
WooCommerce → BigQuery · normal or broken
Working vs. broken, side by side — WooCommerce → BigQuery
Normal, not a fault
Whatever join key you decide on present on the order
Sent from the woocommerce_payment_complete hook
Deduplicated correctly
Nothing deduplicates for you. Streaming inserts are at-least-once, so a retried load can create duplicate rows, and the only protection is a deduplication step you write and actually run.
Reconciles with the source
Actually broken
Whatever join key you decide on missing on most records
WooCommerce sites are usually the most heavily plugged-in of any platform. Caching plugins serve a static page to the visitor, optimization plugins defer or strip scripts, and consent plugins block them entirely. Any of the three will stop an identifier being captured, and they fail silently.
Sent from the browser
The page the customer sees is not the page your code assumed. This is the most common cause of WooCommerce tracking that worked at launch and silently stopped after a plugin update.
Counted twice, or not at all
This is not a bug — it is the point. Your warehouse counts orders; Google counts click-attributed conversions in its window; Meta counts differently again. When the four numbers differ, the warehouse is usually right about revenue and wrong about attribution, and knowing which question you are answering is the whole skill.
Nobody has reconciled it
WooCommerce → BigQuery · diagnose
Diagnostic order — WooCommerce → BigQuery
- 01
Count orders carrying whatever join key you decide on
- 02
Follow one real conversion end to end
- 03
Check order meta on ten recent orders
Directly in the database or with a meta viewer. Then disable page caching for the checkout path and see whether coverage changes — if it does, caching is your cause.
- 04
Reconcile warehouse order counts against each platform for one closed window
The gaps localize the problem: a gap against all platforms is a collection issue, a gap against one is that platform's window or matching.
- 05
Read the match rate, not the success message
BigQuery will not tell you anything is wrong. Verify by querying the table directly against your source system's own totals, and check for duplicate rows on the join key before trusting any aggregate.
WooCommerce → BigQuery · prove
How it gets proven — WooCommerce → BigQuery
Source of truth
WooCommerce → Orders (or the wp_wc_order_stats table), for the same window and status set.
- Whatever join key you decide on confirmed present on a live order.
- Warehouse order counts and revenue reconciled against the source system for a fully closed window, with duplicates checked on the join key.
- Order meta confirmed present on orders placed while full page caching was active.
WooCommerce → BigQuery · free audit
What we check in the free audit
- Count orders carrying whatever join key you decide on
- Follow one real conversion end to end
- Check order meta on ten recent orders
- Reconcile warehouse order counts against each platform for one closed window
- Read the match rate, not the success message
Checked against
WooCommerce → Orders (or the wp_wc_order_stats table), for the same window and status set.
Free30 minutesNo obligation
WooCommerce → BigQuery · when not to buy
When you don't need this — WooCommerce → BigQuery
- Measure identifier coverage yourself first — pull your last hundred orders and count how many carry whatever join key you decide on.
- If you run a small store with no caching layer and a single free plugin already reporting accurately, leave it alone.
- If you have one store and one ad platform, a warehouse is infrastructure you will maintain for a reconciliation you could do in a spreadsheet.
WooCommerce → BigQuery · what we deliver
What gets built — WooCommerce → BigQuery
Identifier capture into WooCommerce
Capture the click identifier and persist it as order meta on the order object with a small snippet in the theme's functions or a purpose-built plugin. Order meta lives in your own database, so it survives caching, plugin conflicts and the customer's browser.
Event source: the woocommerce_payment_complete hook
Fire server-side from the PHP hook rather than from the thank-you page template. Page caching means the thank-you page cannot be relied on to execute anything, and on many stores it is served from cache to a paying customer.
Dispatch to BigQuery
Streaming inserts or scheduled batch loads from your order system, with the raw event retained alongside whatever you derive from it.
Reversals where they exist
The refund hooks carry the order ID, so reversals are straightforward once the identifier is on the order.
Written guarantee
95%+ tracking accuracy
Measured against WooCommerce → Orders (or the wp_wc_order_stats table), for the same window and status set.. Miss it and we keep working at no cost.
From $400 · See packages
FAQ
WooCommerce → BigQuery questions, answered
In the HPOS order tables if High-Performance Order Storage is enabled, otherwise in posts and postmeta. Check which before writing extraction queries.
Join WooCommerce order numbers to transaction_id in the GA4 BigQuery export. Orders with no match were never recorded by GA4.
Almost always because whatever join key you decide on never reached the WooCommerce order. WooCommerce sites are usually the most heavily plugged-in of any platform. Caching plugins serve a static page to the visitor, optimization plugins defer or strip scripts, and consent plugins block them entirely. Any of the three will stop an identifier being captured, and they fail silently. Measure coverage before debugging the dispatch.
There is no vendor identifier here. You choose the key — order ID, user ID, click identifier, hashed email — and you live with the consequences. That is the whole appeal and the whole risk: nothing is standardised for you and nothing is silently wrong in a vendor's favour either.
The woocommerce_payment_complete hook. Fire server-side from the PHP hook rather than from the thank-you page template. Page caching means the thank-you page cannot be relied on to execute anything, and on many stores it is served from cache to a paying customer.
BigQuery will not tell you anything is wrong. Verify by querying the table directly against your source system's own totals, and check for duplicate rows on the join key before trusting any aggregate.
More on WooCommerce → BigQuery
- WooCommerce Subscriptions → BigQueryConnecting WooCommerce Subscriptions to BigQuery
- WooCommerce → HubSpotConnecting WooCommerce to HubSpot
- WooCommerce → TikTokConnecting WooCommerce to TikTok Events API
RELATED GUIDES
Where WooCommerce → BigQuery fits in the rest of your tracking
- WooCommerce Subscriptions → BigQueryConnecting WooCommerce Subscriptions to BigQuery
- Shopify → BigQueryConnecting Shopify to BigQuery
- Ecwid → BigQueryConnecting Ecwid to BigQuery
- WooCommerce → SnowflakeConnecting WooCommerce to Snowflake
- WooCommerce → SegmentConnecting WooCommerce to Segment
- Furniture ecommerceConversion tracking for furniture ecommerce, measured after delivery
- Medusa → BigQueryConnecting Medusa to BigQuery
- SureCart → BigQueryConnecting SureCart to BigQuery
Free · 30 min
Get WooCommerce and BigQuery joined properly
Free30 minutesNo obligation
