Google Tag Manager (GTM)

LeadCapture has a native Google Tag Manager integration that loads your GTM container on your funnel pages and pushes structured events to the dataLayer. This lets you fire any tags you have configured in GTM — Google Analytics, Google Ads, Facebook Pixel, LinkedIn, Hotjar, and more — without adding custom code.

What You Get

  • GTM container loading — all your configured tags, triggers, and variables load automatically on the funnel page.
  • Structured dataLayer events — LeadCapture pushes events at key moments so you can trigger tags when steps are viewed, completed, or when a lead is submitted.
  • Per-step custom events — assign any event name to individual steps for granular tracking.

Setting Up GTM

  1. Open your funnel in the builder.
  2. Go to the Funnel Settings tab (gear icon).
  3. Scroll to the Tracking & Analytics section.
  4. Find the Google Tag Manager card and toggle it to ON.
  5. Enter your Container ID. This starts with "GTM-" followed by 6 to 8 characters (for example, GTM-K66XPDM). You can find it in your Google Tag Manager account.
  6. Save the funnel.

Once enabled, the GTM container script loads automatically on your funnel page, both on LeadCapture-hosted pages and when embedded on external sites.

Automatic Events

LeadCapture pushes these events to the dataLayer automatically:

Event When It Fires
lc_form_view When the form first loads.
lc_step_view When a visitor views a new step.
lc_step_complete When a visitor completes a step and moves forward.
lc_generate_lead When the form is submitted and a lead is created.

Every event includes lc_funnel_id, lc_step_id, and lc_step_index so you can filter by funnel and step in your GTM triggers. The lc_generate_lead event also includes lc_lead_id.

Standard GA4 Event Names

By default, all event names use an lc_ prefix to avoid conflicts with other tags on the page. If you prefer standard GA4 event names (for example, generate_lead instead of lc_generate_lead), you can toggle this in the settings:

  1. In the GTM settings card, enable Use standard GA4 event names.
  2. Save the funnel.

This drops the lc_ prefix from event names, which makes them work out of the box with Google's built-in GA4 tag templates. The data keys (like lc_funnel_id) always keep the prefix regardless of this setting.

Per-Step Custom Events

You can assign a custom dataLayer event to any step in your funnel. This is useful for firing specific conversion tags when a visitor reaches a particular step.

  1. Select a step in the builder.
  2. In the Properties Panel on the right, find the GTM dataLayer Event field.
  3. Enter an event name (for example, generate_lead, purchase, or any custom name).
  4. Save the funnel.

When a visitor advances past that step, your custom event is pushed to the dataLayer alongside the automatic lc_step_complete event. You can use this custom event as a trigger in GTM to fire specific tags.

Using GTM Events in Your Container

To use LeadCapture events as triggers in GTM:

  1. Open your GTM container at tagmanager.google.com.
  2. Create a new Trigger with type "Custom Event".
  3. Set the event name to match the LeadCapture event (for example, lc_generate_lead).
  4. Attach this trigger to any tag you want to fire (GA4 event, Google Ads conversion, etc.).
  5. Publish your GTM container.

Testing Your Integration

  1. Open your browser's Developer Tools and go to the Console tab.
  2. Load your funnel page and type dataLayer in the console. You should see the lc_form_view and lc_step_view events.
  3. Navigate through the funnel steps and check for lc_step_complete and lc_step_view events.
  4. Submit a test lead and verify that lc_generate_lead appears with a lc_lead_id value.
  5. For a more visual debugging experience, use Google Tag Assistant. Connect it to your funnel URL and you can see every dataLayer push and which tags fire in real time.

Embedded Forms

GTM works on embedded forms just like hosted pages. If the page where your form is embedded already has the same GTM container loaded, LeadCapture detects this and reuses the existing container instead of loading it twice. The dataLayer events still fire normally.

Troubleshooting

Issue Solution
No events in dataLayer Verify that GTM is enabled in funnel settings and the Container ID is in the correct format (GTM-XXXXXXX).
GTM script not loading Check the Network tab in Developer Tools and filter by "gtm". The request to googletagmanager.com should return a 200 status.
Tags not firing Make sure your GTM triggers match the exact event names (including the lc_ prefix if you have not enabled standard names).
Duplicate GTM loading on embedded page LeadCapture checks for an existing GTM container before loading. If you see duplicates, verify that the Container ID matches exactly.
Custom step event not appearing Check that you entered the event name in the step's Properties Panel and saved the funnel.

Good to Know

  • GTM is configured at the funnel level. Different funnels can use different Container IDs.
  • GTM runs alongside Meta Pixel tracking without conflicts. You can enable both on the same funnel.
  • GTM tracking is included on all plans at no extra cost.
  • The GTM script loads asynchronously and does not affect your funnel's load time.
  • If a visitor has an ad blocker that blocks GTM, the funnel still works normally. Only the GTM tags will be missed.
  • You can also ask the AI Copilot to set up GTM for you. Just tell it your Container ID and it will configure everything.
Did this answer your question? Thanks for the feedback There was a problem submitting your feedback. Please try again later.