This document outlines how to use Google Tag Manager (GTM) with FunnelKit's Funnel Builder for tracking events on your WooCommerce store. It provides two approaches for integrating GTM with Funnel Builder to track sitewide events, including purchase events, and offers guidance on the potential limitations and how to handle them.
Solution 1: Using FunnelKit’s Built-in Event Tracking
FunnelKit’s event tracking is designed to work independently of Google Tag Manager (GTM), meaning there is no need to add a GTM tag ID to FunnelKit. FunnelKit provides comprehensive event tracking features without the need for a third-party plugin.
Key Points:
- FunnelKit Event Tracking: FunnelKit's settings allow you to track all sitewide events, including purchases, without requiring GTM.
- No GTM for Purchase Events on Offer Pages: GTM does not track purchase events on offer pages. If a user leaves the offer page before reaching the Thank You page, the purchase event will not be tracked.
- Recommended: For seamless event tracking, we highly recommend using FunnelKit's native event tracking settings instead of relying on GTM.
FunnelKit Event Tracking for Popular Platforms:
- Facebook: FunnelKit WooCommerce Facebook Pixel Integration
- Google Analytics: FunnelKit WooCommerce Google Analytics Integration
- Google Ads: FunnelKit WooCommerce Google Ads Conversion Tracking
- Pinterest: FunnelKit WooCommerce Pinterest Integration
- TikTok: FunnelKit WooCommerce TikTok Pixel Integration
- Snapchat: FunnelKit WooCommerce Snapchat Pixel Integration
Solution 2: Using GTM to Track Events
If you prefer to use Google Tag Manager (GTM) to track all events on your site, you can continue using your existing GTM setup. However, you will need to make some adjustments to ensure that the purchase event is properly tracked.
Key Points:
- GTM Limitation: GTM does not track purchase events on offer pages by default. If a user leaves the offer page without reaching the Thank You page, the purchase event will not be captured.
Steps for GTM Integration:
- Track Purchase Events on Offer Pages:
- Use the following script to send the purchase event data to the GTM data layer: Purchase Event Data Layer Script
- This snippet sends the data layer for the main order on the upsell page. If the offer is accepted, the data layer will be sent on the next step (either the offer page or Thank You page).
- Even if the user leaves the upsell page, the purchase event data will still be sent.
- Use the following script to send the purchase event data to the GTM data layer: Purchase Event Data Layer Script
- Disable FunnelKit Purchase Event Tracking:
- To prevent double tracking, disable the purchase event tracking in FunnelKit’s settings. All events, including purchase events, will be tracked via GTM.
- To prevent double tracking, disable the purchase event tracking in FunnelKit’s settings. All events, including purchase events, will be tracked via GTM.
- Disable Other Purchase Event Data Layers:
- If you are using any other plugin or script that sends purchase event data to the data layer, disable that functionality to avoid conflicts.
- If you are using any other plugin or script that sends purchase event data to the data layer, disable that functionality to avoid conflicts.
- No Changes to GTM Triggers:
- There is no need to modify or remove the purchase event triggers in GTM. All events, including purchase events, will now be tracked exclusively through GTM.
- There is no need to modify or remove the purchase event triggers in GTM. All events, including purchase events, will now be tracked exclusively through GTM.
Summary
You have two main options for tracking events using FunnelKit and Google Tag Manager:
- Use FunnelKit’s Built-in Tracking: This is the easiest and recommended approach for most users. FunnelKit tracks all events sitewide, including purchases, without the need for GTM.
- Use GTM for Event Tracking: If you prefer using GTM, you can implement custom scripts to send purchase event data through GTM. However, GTM has limitations in tracking purchase events on offer pages, which can be resolved with the provided script.
By choosing the appropriate solution based on your preferences, you can ensure accurate tracking for all events on your site.