Configuring Google Analytics

Configuring Google Analytics

UltraCart has the ability to automatically inject Google Analytics tracking code into your catalog and checkout screen branding. 

The following tutorial will walk you through configuring your Google Analytics account information within your UltraCart account.


Storefronts Integration

The configuration fields for Google Analytics are found in your Screen Branding configuration area.  This is also the same place for other supported and third party conversion and tracking configuration.

That being said, we need to navigate to:

Now scroll down to the Supported section. This section contains all of the different tracking systems that UltraCart has built in support for.

In this list you will find "Google Analytics Account Number - Default" as shown below.

Tracking Type

There are multiple tracking types supported by UltraCart. The table below describes the various types, the script Google uses, and whether they support asynchronous loading:

Account Number

Enter your "UA-*********" value into the Account Number field.

Domain Override

By default the system is using at the host to the checkout then the GA tracking is set to use that host. If you have a custom SSL then is passed to the tracking script as This field will provide advanced user the ability to override this on the Google analytics tracking script. 

Cross Domains

If you need cross domain tracking in Google Analytics, enter a comma separated list of domains here. Do not add any spaces.


Opt Into

Use the "Opt in to" setting to assign (Drop-down list: Statistics / Preferences / Marketing) required for (Drop-down list: All Customers / EEA Customers / Non-US Customers)

Custom Events

The Following custom events are trackable within the Ultracart Storefront configurations using a Storefront in a "Non-checkout only" configuration:

  • AddPaymentInfo
  • AddToCart
  • AddToWishlist
  • CompleteRegistration
  • InitiateCheckout
  • Lead
  • Search
  • ViewContent

Pricing Tiers

If you have pricing tiers configured on your account for wholesale customers then you can track them on a separate Google Analytics account if you would like. There will be an additional row in the configuration for each pricing tier on your store. If you leave these blank then UltraCart will use the default UA- account when tracking the customer even if they have a pricing tier.

Frequently Asked Questions

Q: I have Google Analytics configured and it's working fine for order placed from the website, but it's not being triggered for my auto orders?

A: The Google Analytic script is fired off based on cookies in the customer browser during the checkout. Since auto orders are generated without the additional involvement from the customer's browser, the GA script is not fired.

The following message from one of our merchants describes an *unofficial* (not directly supported by UltraCart basic support, troubleshooting only available through paid support $100/hr after review by Pro Service department) workaround that they have implemented to triggered the GA script using the XML Postback:

"Yes, I have been successfully tracking UC sales and refunds for the past few weeks through XML postback. I don't have a "template" I can send you, but this (link below) PHP code
will pretty much work out of the box if you just place your Google Analytics account ID in it. Note: the Google Analytics account must be the newer (Universal Analytics) type or else this won't work.

Refunds are recorded into GA with "ref-" appended to the transaction ID so that you can then separate them easily in reports. I also plan to append "auto-" to auto orders to separate them in reports as well but haven't done that yet.

A few things to note when implementing this. Make sure the time zone in the Google Analytics property matches UltraCart's server time zone, which I think is EST. Also, merchants that get sales 24/7 will notice that daily revenue from GA and UC sometimes won't match up. This is because, for example, if a customer orders something from UC at 11:57pm, the order may not get recorded into GA until 12:02am, which it is then the following day." 

Q: How do I support Google Analytics Display Network Tracking?

A: UltraCart supports Google Analytics Display Network tracking ( already. In the Tracking Type drop down select "Display Network".  This will automatically change the tracking code snippet to conform with Google's document Update Your Analytics Tracking Code to Support Display Advertising.

Q: Which "tracking Types" is the Universal Analytics?

A: Choose "E-Commerce" from the tracking type drop-down menu, which corresponds to the Universal Analytics (UA) with the e-commerce plugin.

Q: Are there any tools for testing my google analytics?

A: The Google Analytics Debugger tool can be used to test and troubleshoot your google analytics configuration. 

Q: How do I configure goals and funnels tracking?

A: The conversion page (screen) to use for the Google Analytics Goals and Funnels is:

(NOTE: For storefronts replace "" with the storefronts hostname.)

Please read and follow the Google Analytics Knowledge Base Article URL below) on integration with a 3rd party shopping cart.  It's critical to do the URL linking properly:

NOTE: If you utilize a custom SSL domain then you'll need to replace with your custom SSL domain (URL).

Related Resources

Introduction to Google Analytics in UltraCart

Custom Google Analytics Conversion Pixel

Upgrading to Asynchronous Google Analytics Tracking Code in a Catalog Template