[UA] Set up Ecommerce Tracking

Add Ecommerce Tracking to your website or app.

To see Ecommerce data in your Analytics reports, you need to:

  • Enable Ecommerce for each view in which you want to see data.
  • Add code to your site to collect the ecommerce data and send it to Analytics. To complete this task, you need to be comfortable editing HTML and coding in JavaScript, or have help from an experienced web developer.
In this article:

Enable Ecommerce for a view

You need to enable Ecommerce for each view in which you want to see the data.

  1. Sign in to Google Analytics.
  2. Click Admin, and navigate to the view you want.
  3. In the VIEW column, click Ecommerce Settings.
  4. Set Enable Ecommerce to ON.
  5. Click Save.

Tracking-code setup with Google Tag Manager

If you use Google Tag Manager to manage your tracking code, read the set-up guide for Ecommerce Tracking.

Tracking-code setup (web)

If you have not already set up basic page tracking, do this first.

If you use a third-party shopping cart, or track transactions across separate domains, you'll need to set up cross-domain tracking. If your shopping cart software is on the same domain as your ecommerce site, you don't need to implement cross-domain tracking.

To collect ecommerce data from a website, you need to add JavaScript to your site that sends Analytics the transaction and product data. Refer to the Ecommerce Tracking documentation.

Tracking-code setup (app)

To collect ecommerce data from a mobile app, use one of the Analytics SDKs.

To collect ecommerce data from an Internet-connected device (a point-of-sale device, for example, but not a website or mobile app), refer to Ecommerce Tracking or Enhanced Ecommerce Tracking in the Measurement Protocol developer guide.

Troubleshoot Ecommerce tracking and reporting

Use the Ecommerce tracking-and-reporting troubleshooter to identify and resolve problems.

Was this helpful?

How can we improve it?
true
Choose your own learning path

Check out google.com/analytics/learn, a new resource to help you get the most out of Google Analytics 4. The new website includes videos, articles, and guided flows, and provides links to the Google Analytics Discord, Blog, YouTube channel, and GitHub repository.

Start learning today!

Search
Clear search
Close search
Google apps
Main menu
15905530535587513632
true
Search Help Center
true
true
true
true
true
69256
false
false