Google Tag Manager (GTM) integration allows you to manage all your tracking tags through your existing GTM container.
Google Tag Manager integration settings

Features

  • Tag Management: Deploy tags without code changes
  • Data Layer Integration: Access all FunnelFox events
  • Version Control: Test and rollback tag configurations
  • Debug Mode: Preview tags before publishing
  • Built-in Templates: Quick setup for common platforms
  • Custom Variables: Create complex tracking logic

Configuration

Prerequisites

  • Google Tag Manager account with container
  • GTM container ID (GTM-XXXXXXX)
  • FunnelFox project with funnels ready to publish

Setup Steps

1

Get GTM Container ID

  1. Log into Google Tag Manager
  2. Select your container
  3. Copy the Container ID (format: GTM-XXXXXXX)
  4. Note: It’s displayed in the top navigation bar
2

Configure in FunnelFox

  1. Go to Project SettingsIntegrationsAnalytics
  2. Toggle Google Tag Manager on
  3. Paste your GTM Container ID
  4. Click Save changes
3

Republish Funnels

Republish your funnels to activate GTM
4

Configure Tags in GTM

Set up your tags, triggers, and variables in GTM (detailed below)
When GTM is enabled, it can work alongside direct Google Analytics integration. Both use the data layer without conflict.

Data Layer Events

FunnelFox automatically pushes all events to the GTM data layer. Here’s what FunnelFox sends automatically:
// This is automatically pushed by FunnelFox when a page loads:
window.dataLayer.push({
  event: 'screen_presented',
  funnel_id: 'welcome-flow',
  funnel_alias: 'Welcome Flow',
  page_index: 0,
  page_id: 'intro',
  profile_id: 'abc123',
  session_id: 'xyz789',
  sandbox: false
});

Available Events

All standard events are available as triggers in GTM:
  • onboarding_started
  • screen_presented
  • screen_completed
  • purchase_completed_success
  • user_email_collected
  • And all other standard events

Common Tag Configurations

Google Analytics 4

1

Create GA4 Configuration Tag

  1. In GTM, click TagsNew
  2. Choose Google Analytics: GA4 Configuration
  3. Enter your Measurement ID
  4. Trigger on All Pages
2

Create Event Tags

For each event you want to track:
  1. Create new GA4 Event tag
  2. Use {{Event}} as event name
  3. Add event parameters from data layer variables
  4. Trigger on specific FunnelFox events

Facebook Pixel

1

Create Pixel Base Code

  1. Create Custom HTML tag
  2. Add Facebook Pixel base code
  3. Trigger on All Pages
2

Map Conversion Events

Create tags for key events:
  • user_email_collected → Lead event
  • purchase_completed_success → Purchase event
  • checkout_presented → InitiateCheckout event
Use the Facebook Pixel Helper Chrome Extension to verify pixel events are firing correctly.

Custom Platform Integration

<script>
  // Access data layer variables
  var eventName = {{Event}};
  var funnelId = {{DLV - funnel_id}};
  var userId = {{DLV - profile_id}};
  
  // Send to your platform
  if (eventName === 'purchase_completed_success') {
    yourPlatform.track('Purchase', {
      funnel: funnelId,
      user: userId,
      value: {{DLV - price}}
    });
  }
</script>

Variables Setup

Built-in Variables

Enable these in GTM:
  • Event: Access event names
  • Page URL: Current page location
  • Referrer: Traffic source

Data Layer Variables

Create variables for FunnelFox data:
Variable NameData Layer VariableType
DLV - funnel_idfunnel_idData Layer Variable
DLV - page_indexpage_indexData Layer Variable
DLV - profile_idprofile_idData Layer Variable
DLV - pricepriceData Layer Variable
DLV - product_idproduct_idData Layer Variable
DLV - sandboxsandboxData Layer Variable

Triggers

Event-Based Triggers

Create triggers for specific events:
  1. Purchase Trigger
    • Trigger Type: Custom Event
    • Event Name: purchase_completed_success
  2. Email Capture Trigger
    • Trigger Type: Custom Event
    • Event Name: user_email_collected
  3. Checkout Trigger
    • Trigger Type: Custom Event
    • Event Name: checkout_presented

Conditional Triggers

Add conditions to triggers:
  • Only fire on production: sandbox equals false
  • Specific funnel: funnel_id equals welcome-flow
  • Minimum page depth: page_index greater than 2

Debug Mode

Preview Container

  1. In GTM, click Preview
  2. Enter your funnel URL
  3. Navigate through your funnel
  4. See tags fire in real-time
  5. Verify variables are populated

Debug Tools

Install the Tag Assistant Companion Chrome Extension for enhanced debugging with GTM Preview mode.
  • Use Tag Assistant for detailed debugging
  • Check data layer in browser console: dataLayer
  • Verify tag firing order and timing
  • Test both preview and production modes

Server-Side Tagging

For improved performance and privacy:
  1. Set up GTM Server container
  2. Route tags through your domain
  3. Reduce client-side JavaScript
  4. Improve page load speed

Troubleshooting

Next Steps