How Ecommerce Tracking in GA4 is Different from UA
Collecting data on ecommerce activities in Universal Analytics (UA) was probably one of the more complicated Google Analytics implementations. First, was regular ecommerce, then “enhanced ecommerce” – They were definitely advanced implementations.
With GA4, tracking ecommerce interactions is less confusing and complex compared to UA. Nevertheless, careful and diligent effort is still needed, both for data layer pushes and analytics tagging.
GA4 is still an evolving product. As of now, you need to take note of ecommerce tracking changes in these 2 areas:
- Naming convention and event structure
- Some of the underlying variables sent in those events have changed
In UA, the tags for enhanced ecommerce events look like this in Google Tag Manager:
If the correct variables were set for enhanced ecommerce, event category and action names can be set independently. The variable contained a parameter that identified the type of ecommerce event. This was accompanied by ecommerce and custom product-scoped dimensions used to pass detailed information.
Google lists recommended terms in their UA ecommerce instructions but use of these recommended terms is not mandatory.
The GTM tag for GA4 ecommerce is much shorter and simpler:
That is because we specify only Event Name and some required, optional, and custom parameters. There is no special ecommerce data variable to configure.
GA4 supplies events for more activities compared to UA’s actions, helping isolate the user’s exact stage in the conversion journey.
The new GA4 ecommerce events are:
- view_cart – when a user views the cart
- add_payment_info, add_shipping_info – when a user has entered their payment and shipping information respectively
- earn_virtual_currency , spend_virtual_currency – let’s say we are a retailer with a rewards program. If your stores allow rewards to be used in place of currency, reward usage can now be tied directly with other ecommerce events with virtual currency events.
- begin_checkout – when a user has begun a checkout
- add_to_wishlist – when items are added to a wish list
- refund – when a user successfully requests a refund
There are also some other events that have equivalents in UA, but the names have changed.
Use the recommended event names and parameters to ensure data flows into GA4 ecommerce built-in reports smoothly.
Although you can use your own custom events to collect ecommerce data, data from your custom events won’t appear in the standard, built-in ecommerce reports.
Google Analytics 4 Has Different Variables and Names for Product Arrays
Firstly, GA4 has one main data variable array. Called the items object, this array works with all GA4 ecommerce events. There are also some new variables you can use in the items array that introduce new functionality in GA4.
- item_list_id
- UA had list names, but not a list id. In GA4, we have the added id which can be helpful if you have lots of lists to keep track of.
- item_category2 … up to item_category5
- Now, instead of cramming a complete product hierarchy with delineation symbols into one variable and then create complex segments in GA for drill downs, we can have five separate levels of product categories.
- discount
- Discounts used to only be at a transaction level. Now they can be tracked at an item level. This is especially useful if the discounts are dynamic or differ for various products.
- checkout_step
- The key variable we had in UA that doesn’t exist in GA4 is checkout_step, which was used when there were multiple steps in checkout. To be fair, multistep checkout tracking existed to track interactions like cart view, a shipping info step, and a payment info step.
- We now have specific events to use for them.
- This also reflects the new reality of GA4 where users will spend more time creating custom explorations rather than pre-set reports and funnels.
Wrapping Up
We covered the main differences between GA4 and UA when it comes to ecommerce. If you are ready to dive in, you can find the official documentation here.
While there’s still a lot of work involved in building an Ecommerce setup, it is a relatively clear-cut and less intimidating process in GA4 than we faced in UA.
If you run into any issues with your GA4 Ecommerce implementations, do drop us a comment below.
Got questions? Drop us a comment, and/or describe your biggest challenge or frustration.
Other posts in our 12 Days of Google Analytics 4 series:
1.GA4 “Configure” is Moving to Admin
2.How to Set Up Cross-Domain Tracking in Google Analytics 4
3.Get Your Hands on Real GA4 Data Today with the Google Analytics 4 Demo Account
4.What is Engagement Time in GA4?
5.Why your GA4 Looker Studio Report is Broken
6.Did your Looker Studio GA4 Numbers Increase After Applying Filters?
7.How is Engagement Time Reported in GA4?
8.How Ecommerce Tracking in GA4 is Different from UA
9.How to Create and Modify Events in GA4
10.When to Use GA4 Rollups & Subproperties
11.What in GA4 replaces Universal Analytics’ Views? Hint: It’s NOT GA4 Data Streams
12.Why am I seeing blank rows or (not set) in my GA4 Landing Page Report?