Google Analytics
How to track Tito visits and purchases in your Google Analytics account.
Paul Campbell avatar
Written by Paul Campbell
Updated over a week ago

Using Google Analytics now requires V2 of our widget. Find out more here.

Note: We’re aware of the update to Google Analytics 4 and we are working with customers on a new plugin that is compatible with GA4 standalone or via Google Tag Manager. Please contact support if you'd like to try it.

Since Google’s universal analytics is nearing end of life, the following is now deprecated:

Tracking attribution and conversions is possible using JavaScript hooks on the V2 widget. For convenience, we've provided two plugins compatible with Google Analytics for getting you up and running quickly, one using Google's Global Site Tag, one using Google Tag Manager and another using Analytics.js.

Please note, that adding tracking tags on hosted Tito pages and domains is deprecated. In order to use Google Analytics, you will need to use V2 of our widget on your own site and your own domain. This gives you much more autonomy and control of what you track, as well as removing the limitations and privacy implications of cross-site tracking.

Prerequisites

Install the Google JS Snippet on your site

The V2 widget plugins assume that you have loaded either gtag.js, Google Tag Manager or analytics.js. It's highly likely that you will already have those installed on your site. See Google’s standard documentation for how to install those.

If you're using an older or custom implementation, you can use our gtag.js implementation as a starting point for how to set up your own listeners.

In addition, if you're using analytics.js, it's highly recommended to use the async version. If you're not using the async version, then don't load the Tito Widget async either.

Enable Enhanced eCommerce tracking

See Google’s documentation for full info on how to enable enhanced eCommerce.

In a nutshell, in your Google Analytics account, go to Admin, then under View for the property that you want to enable tracking for, choose eCommerce Settings. Make sure that both the Ecommerce and Enhanced Ecommerce settings are switched to on.

If you want to add a funnel step, there is only one: the credit card form. You can name this "Register form" for example so that it shows up as such in reports.

Set up Google Analytics in Tito

You don't need to do anything in Tito to enable analytics. The analytics code runs on your website, listening for events that the widget fires, so you don't need to switch anything on or provide Tito with any tracking IDs. All of the tracking code runs on your site, in the main content window.

Load the appropriate plugin

To load the Global Site Tag or Google Tag Manager plugins, just pass them in to the URL when you are loading the V2 widget:

For the Global Site Tag:

<script src='https://js.tito.io/v2/with/gtag' async></script>

For Google Tag Manager:

<script src='https://js.tito.io/v2/with/gtm' async></script>

You can track the following events with Google Tag Manager:

  • tito:checkout

  • tito:purchase

For Analytics.js:

<script src='https://js.tito.io/v2/with/google_analytics' async></script>

Remember, these plugins don't load Google Analytics for you, so you will still need to paste the Google-provided snippets to load those.

If you need to, you can also load the plugin asynchronously in code, as follows:

//create a `tito` function if the Tito widget hasn't yet loaded
window.tito=window.tito||function(){(tito.q=tito.q||[]).push(arguments)}

//for Google Tag Manager
tito("plugin.load","gtm",{})

// For Global Site Tag
tito("plugin.load","gtag",{})

// For analytics.js
tito("plugin.load","google_analytics",{})

______________________

Need help with something specific? Search our FAQs section to find instant answers. 

If you can’t see what you need, drop us a line at support@tito.io or chat with us in-app and we’ll get back to you as quickly as we can.

Did this answer your question?