Google Analytics 4 Integration

TicketingHub Google Analytics 4 Integration


Overview


This document describes how the TicketingHub V2 checkout widget integrates with and sends data to Google Analytics 4 (GA4). The V2 widget automatically sends e-commerce events to your GA4 property, enabling you to track how visitors interact with your checkout flow, analyze customer behavior, and measure conversion performance.


How to Install Google Analytics on Your Page



If you already have GA4 installed on your website, the TicketingHub widget will automatically detect and use your existing configuration. No additional setup required.


  1. In the TicketingHub Dashboard, go to Checkout Widget Settings
  2. Expand the Google Analytics section
  3. Enable "Enable Tracking"
  4. Select "Use existing tag" (this is the default)
  5. Save your changes


The widget will automatically detect any GA4 tag present on your page and send events to it.


Option 2: Use Custom Measurement ID


If you want to track widget events to a different GA4 property:


  1. Get your GA4 Measurement ID from Google Analytics:
  • Go to Google Analytics Admin > Data Streams
  • Select your web stream
  • Copy the Measurement ID (format: G-XXXXXXXXXX)


  1. In the TicketingHub Dashboard:
  • Go to Checkout Widget Settings
  • Expand the Google Analytics section
  • Enable "Enable Tracking"
  • Select "Use custom tag"
  • Enter your Measurement ID (e.g., G-XXXXXXXXXX)
  • Save your changes


Debug Mode


To verify events are being sent correctly:


  1. Enable "Debug Mode" in the Google Analytics section
  2. Open your browser's Developer Console (F12)
  3. Events will be logged to the console as they fire
  4. Use GA4's DebugView in real-time to see incoming events


Note: Some WordPress caching or optimization plugins can interfere with GA4. Try disabling them temporarily or add GA4 scripts to their exclusion list.


Important: Disable Ad Blockers When Testing


Ad blockers and privacy extensions (such as uBlock Origin, AdBlock Plus, Privacy Badger, Ghostery, etc.) commonly block Google Analytics tracking requests. When testing your GA4 setup:


  1. Temporarily disable any ad blocker or privacy extension in your browser
  2. Use an incognito/private window without extensions enabled
  3. Or whitelist your website and google-analytics.com in your ad blocker settings


If events are not appearing in GA4 DebugView, an ad blocker is often the cause.


Events Sent to Google Analytics 4


The TicketingHub widget sends the following GA4 events:


1. Page View Events (page_view)


Tracked whenever a customer navigates to different steps in the checkout flow.


Event Parameters:

page_title: string          // e.g., "Booking Success"
page_path: string // e.g., "success"
page_location: string // Host URL of the page
widget_id: string // Widget identifier
start_date: string // (date_and_time_selection only) ISO8601 format
selected_date: string // (date_and_time_selection only) ISO8601 format


2. Item Selection Events (select_item)


Triggered when a customer selects a product, variant, or merchandise item.


Trigger Points:

  • User selects a product from the sellable list
  • User selects a variant
  • User selects a gift card or merchandise item


Event Parameters:

item_list_id: string        // Product ID or widget ID
item_list_name: string // "Sellable List", "Variant List", etc.
items: [
{
item_id: string // Product/variant/merchandise ID
item_name: string // Product/variant name
item_category: string // "Product", "Variant", "Merchandise", "Package"
}
]


3. Purchase Events (purchase)


Triggered when an order is successfully completed. This is the main conversion event for e-commerce tracking.


Event Parameters:


transaction_id: string      // Order reference number
value: number // Order total (decimal)
currency: string // Currency code (e.g., "GBP", "USD", "EUR")
items: [
{
item_id: string // Ticket reference
item_name: string // Tier name
item_brand: string // Product name
item_category: string // Tier type
item_variant: string // Variant name (if applicable)
price: number // Individual ticket price (decimal)
quantity: number // Always 1 (one entry per ticket)
}
]



GA4 Reports You Can Use


With this integration, you can analyze:


  1. Funnel Analysis: Track drop-off at each checkout step using page_view events
  2. Product Performance: See which products/variants are selected most via select_item events
  3. Revenue Reports: Use the purchase event for e-commerce revenue tracking
  4. Conversion Rate: Compare visitors to successful purchases
  5. Real-time Monitoring: Use DebugView to test your integration


Troubleshooting


Events Not Appearing in GA4


  1. Check Debug Mode: Enable Debug Mode in widget settings and check browser console
  2. Verify Measurement ID: Ensure the ID matches your GA4 property
  3. Check DebugView: Use GA4 DebugView for real-time event monitoring
  4. Caching Plugins: WordPress caching or optimization plugins may interfere - add GA4 to exclusion lists
  5. Wait Time: Standard GA4 reports can take 24-48 hours; use Realtime reports for immediate verification

No Custom Measurement ID Working


If using "Use existing tag" option:

  • Ensure GA4 is properly installed on the parent page before the widget loads
  • The widget will only detect gtag.js implementations, not GTM-only setups without gtag




Looking for custom way of integrating with analytics?




Updated on: 29/01/2026

Was this article helpful?

Share your feedback

Cancel

Thank you!