Integration

WooCommerce tracking for Umami

See what your store sells in Umami: every add to cart, every checkout started and every order, with its revenue. One switch, no code.

Last updated

Short answer

To track WooCommerce in Umami, install Connect for Umami, open Settings → WPUmami → Store and switch on WooCommerce. The plugin then sends four events to Umami: add_to_cart, remove_from_cart, begin_checkout and purchase. Each purchase carries the order total as revenue and the currency, which is what Umami's Revenue report reads. Every order is sent once.

The WooCommerce events sent to Umami

Four events cover the path from product to paid order. They appear in Umami under Events, with the details below attached to each one.

EventWhen it is sentData sent with it
add_to_cartA product is added to the cart, or the quantity of a product already in the cart is increased.
product
Product name
product_id
Product or variation ID
sku
SKU, if the product has one
quantity
How many were added
price
Unit price as shown to the customer
value
Price times quantity
currency
Store currency, for example USD
remove_from_cartA line is removed from the cart, or its quantity is reduced.
product
Product name
product_id
Product or variation ID
sku
SKU, if the product has one
quantity
How many were removed
price
Unit price
value
Price times quantity
currency
Store currency
begin_checkoutThe checkout page is shown to a visitor who has items in the cart.
value
Cart total
currency
Store currency
items
Number of items in the cart
purchaseThe order confirmation page is shown for a new order. Sent once per order.
revenue
Order total. This is the figure Umami's Revenue report adds up.
currency
Order currency
order_id
Order number
items
Number of items in the order
tax
Tax total
shipping
Shipping total
discount
Discount total
coupon
Coupon codes used, comma separated
payment_method
Payment method, for example stripe or cod

How WooCommerce revenue reaches Umami

Umami builds its Revenue report from events that carry two properties: revenue and currency. Connect for Umami adds both to the purchase event, using the order total and the order's currency. Nothing else needs configuring in Umami. Revenue reporting needs Umami 2.14 or newer.

The purchase is reported from the order confirmation page, in the customer's own browser, through the Umami tracker that is already on the page. That keeps the sale in the same Umami session as the visit that led to it, so you can see which referrer, campaign or landing page the revenue came from.

Each order is counted once

When a purchase is reported, the plugin marks the order. If the customer reloads the confirmation page, or comes back to it later, the order is not sent a second time. Failed, canceled and refunded orders are not reported.

Which WooCommerce setups it works with

Part of WooCommerceSupportedNotes
Classic cart and checkout (shortcodes)YesIncluding the Add to cart form on product pages.
Block cart and checkoutYesQuantity changes in the block cart are reported as they happen.
Add to cart buttons on shop and category pagesYesAJAX and non-AJAX.
Store APIYesUsed by block themes and many page builders.
High-Performance Order Storage (HPOS)YesDeclared compatible.
Variable productsYesThe variation's own name, ID, SKU and price are sent.

How to turn on WooCommerce tracking

  1. Connect the site to Umami

    In WordPress, go to Settings → WPUmami → Tracking. Paste your Umami website ID and script URL, then save. The status panel at the top should say the tracking script is responding.

  2. Switch on WooCommerce

    Open the Store tab, tick WooCommerce and save.

  3. Place a test order

    In a private browser window, add a product to the cart and check out. Use a private window because logged-in administrators are not tracked by default.

  4. Check Umami

    In Umami, open your website and look at Events. You should see add_to_cart, begin_checkout and purchase. The order total appears in the Revenue report.

What is not sent

No customer names, email addresses, postal addresses or payment details leave your site. The events carry products, quantities, prices, the order number and the totals. That keeps your Umami data free of personal information, the way Umami is meant to be used.

Questions you can answer once it is on

  • Which referrers and campaigns bring visitors who actually buy.
  • Which products are added to carts most often, and which are removed again.
  • How many visitors start checkout compared with how many finish, using an Umami funnel from add_to_cart to begin_checkout to purchase.
  • Revenue by country, device or landing page, in Umami's Revenue report.

Frequently asked questions

Does Umami support WooCommerce revenue tracking?

Yes. Umami has a Revenue report that adds up any event carrying revenue and currency properties (Umami 2.14 or newer). Umami does not send those events from WooCommerce by itself. Connect for Umami sends them for you on every order.

Will an order be counted twice if the customer reloads the thank-you page?

No. The plugin marks each order when its purchase event is sent, so reloading or revisiting the order confirmation page does not send it again.

Does it work with the WooCommerce block checkout?

Yes. It works with the block cart and checkout, the classic shortcode cart and checkout, and the Store API.

Is any customer data sent to Umami?

No. Only products, quantities, prices, the order number, totals, coupon codes and the payment method name are sent. No names, emails, addresses or card details.

Why are my own test orders not showing up?

Logged-in administrators are excluded from tracking by default. Test in a private browser window, or untick "Exclude logged-in admins" on the Tracking tab while you test.

Do I need to add code to my theme or to the thank-you page?

No. Tick WooCommerce on the Store tab and save. The plugin handles the rest.

Connect WordPress to Umami in about two minutes

One plugin: the tracking script, events, store revenue and your stats inside WordPress. Plans start at $12 a year, with a 14-day money-back guarantee.

See pricing