Heyflow integrations

Connect Your Funnel Builder With Google Tag Manager

12 min read
Connect your funnel builder with Google Tag Manager using Heyflow's native integration. Track every funnel step, improve ad signals, and choose between client-side GTM and server-side CAPI tracking.
Get started Pricing
G2 ratings 4.4 / 5.G2 ratings 4.4 / 5.OMR ratings 4.5 / 5.OMR ratings 4.5 / 5.Capterra ratings 4.7 / 5.Capterra ratings 4.7 / 5.

Trusted by 3,000+ marketers

AxaBCG Digital VenturesForbesSaas GroupRocket MortgageAllianzCiscoPernod Ricard

Most teams connecting a funnel builder with Google Tag Manager run into the same problem: the funnel's interactive events happen inside a JavaScript environment that ad platforms cannot see without explicit instrumentation. Getting GTM and your funnel builder to communicate cleanly requires understanding where client-side tracking breaks down, how embedded funnels change the architecture, and when server-side connections outperform browser-based pixels entirely.

Key takeaways

  • Embedding a Heyflow flow on your website requires connecting the same GTM container ID inside Heyflow, not just on the parent page.

  • Client-side GTM tracking loses an estimated 20 to 40 percent of conversion events to ad blockers and iOS privacy restrictions.

  • Heyflow's native server-side CAPI integrations for Meta, TikTok, and Bing require no GTM server container and carry no page speed penalty.

  • Running GTM and Heyflow's native CAPI together gives the highest conversion coverage, with automatic deduplication handled by Heyflow.

What Google Tag Manager Actually Does in a Funnel Context

Google Tag Manager is a tag management system that lets you deploy and update tracking codes without touching your funnel's source code. In a funnel context, GTM acts as the orchestration layer: it listens for events pushed to the dataLayer by your funnel builder, then routes those events to downstream platforms like GA4, Google Ads, Meta Pixel, LinkedIn Insight Tag, or any custom analytics tool you need.

The three core components are tags (the code fragments that send data to a platform), triggers (the conditions that determine when a tag fires), and variables (the dynamic values GTM needs to execute correctly, like a funnel screen index or a conversion value). GTM itself does not provide reports. It is purely a dispatch system. The reporting happens in the platforms it feeds.

For funnel builders specifically, GTM solves a critical problem: the funnel's interactive events (screen completions, button clicks, form submits) happen inside a JavaScript environment that ad platforms cannot see without explicit instrumentation. GTM bridges that gap, provided your funnel builder pushes structured events to the dataLayer in the first place.

How Heyflow Connects With Google Tag Manager

Heyflow has a native GTM integration that requires no custom code. You paste your GTM container ID (formatted as GTM-XXXXXXX) into Heyflow's integration settings, and Heyflow automatically pushes lifecycle events to the dataLayer as users move through your flow. This means you get structured, named events for screen views, step progressions, button clicks, and form submissions without writing a single line of JavaScript.

The full setup process, documented in Heyflow's GTM tracking guide, involves four steps: create a GTM web container and copy the container ID, connect it inside your Heyflow flow settings, download Heyflow's pre-built container configuration file, and import that file into your GTM workspace. Once imported, you publish the container, and your tags, triggers, and variables are live.

The pre-built container configuration is a meaningful time-saver. Instead of manually creating custom event triggers and data layer variables from scratch, Heyflow gives you a working GTM template that maps to its event taxonomy. You can then modify it to add your own GA4, Google Ads, or Meta Pixel tags on top.

One Container or Two: The Embedded Funnel Decision

If you embed a Heyflow flow on your website using the web component, you face a tracking architecture decision that trips up a lot of teams. The Heyflow web component uses its own Shadow DOM, which means a GTM container installed only on your parent page cannot see events happening inside the flow. You need to connect GTM within Heyflow itself as well.

The recommended approach is a single GTM container for both your website and the embedded flow. You install the GTM snippet on your parent page as normal, and you also connect the same container ID inside Heyflow. This way, events from both environments end up in the same GTM workspace, making tag management, reporting, and GA4 funnel analysis straightforward to maintain.

A separate container for the flow is technically possible, but creates unnecessary overhead. You would need two GA4 properties to consolidate data, and managing naming conventions and tag logic across two containers adds complexity without meaningful benefit for most teams. The single-container setup is cleaner and easier to audit.

Setting Up Funnel-Specific Events in GTM

The real value of the GTM integration is not just tracking the final form submission. It is tracking every meaningful step so you can identify where users drop off. Heyflow pushes per-screen events to the dataLayer, which means you can create custom event triggers in GTM that fire at each screen transition, not just at the end of the flow.

In GTM, you set up a Custom Event trigger for each Heyflow dataLayer event name, then attach tags to those triggers for whichever platforms you need. For GA4, you create a GA4 Event tag that fires on each screen view event, passing the screen index and funnel ID as event parameters. This feeds the GA4 funnel exploration report, which shows you exactly where your drop-off rates spike.

For Google Ads, you can map the final submit event to a primary conversion action for Smart Bidding, and map earlier screen completions (for example, completing the qualification questions) as secondary conversion actions. Secondary actions are observation-only and do not distort your bidding algorithm, but they give the Google Ads algorithm richer signals during low-volume periods when primary conversions are sparse.

Heyflow's built-in analytics dashboard also shows per-screen drop-off rates natively, without requiring GTM at all. GTM and GA4 add depth for cross-channel attribution and ad platform optimisation, but the core funnel performance data is already in Heyflow.

Where Client-Side GTM Tracking Falls Short

GTM web containers are entirely client-side. Every tag fires in the user's browser, which creates a set of structural vulnerabilities that matter significantly for performance marketing in 2025 and beyond.

Ad blockers affect more than half of consumers globally, and browser-based pixels lose an estimated 20 to 40 percent of conversion events to iOS privacy restrictions and ad blocker interference. When Meta or Google Ads receives an incomplete conversion signal, Smart Bidding optimises on a distorted dataset, CPLs rise, and delivery degrades. The algorithm is not wrong; it is working with the data it has. The problem is the data is incomplete.

There is also a page speed consideration. Client-side tracking pixels add measurable load time, and load time directly affects conversion rates. Pages loading in one second convert at roughly 9.6 percent, while pages loading in five seconds convert at around 3.3 percent. Every additional GTM tag that fires on page load is a small tax on your conversion rate. Heyflow's default mobile PageSpeed scores above 90 reflect an architecture built to avoid this problem.

When Native Server-Side Tracking Is the Better Choice

For the ad platforms where it matters most (Meta, TikTok, and Microsoft/Bing Ads), Heyflow offers native server-side Conversions API integrations that bypass the browser entirely. Instead of relying on a pixel firing in the user's browser, Heyflow sends conversion data directly from the server to the ad platform's API. Ad blockers, cookie restrictions, and browser privacy settings have no effect on server-side events.

The practical result is higher Event Match Quality scores in Meta Events Manager, more complete conversion data in TikTok Ads Manager, and better attribution in Microsoft Ads. Higher match quality means the ad platform can attribute more conversions to the right campaigns, which improves lookalike audience quality and Smart Bidding signals. For a detailed walkthrough of the Meta-specific setup, Heyflow's Meta CAPI documentation covers deduplication, custom event mapping, and the no-code configuration process.

The key distinction is that Heyflow's native CAPI integrations are not routed through GTM. They are direct server-to-server connections configured inside Heyflow's settings panel. This means you do not need a server-side GTM container, a Stape account, or any middleware to get server-side tracking working for Meta, TikTok, or Bing. You set it up once in Heyflow, and it runs automatically for every flow.

For a deeper look at how Heyflow's native CAPI compares to GTM-routed approaches and other funnel builders, the guide to the best funnel builders for Meta ads covers the tradeoffs in detail.

GTM vs. Native CAPI: Which to Use and When

Tracking Method

Ad Blocker Resilience

Signal Quality

Page Speed Impact

Setup Complexity

Best For

GTM Web Container (client-side)

Low

Partial (browser-dependent)

Moderate

Low to medium

GA4, Google Ads, LinkedIn, custom analytics

Native CAPI (Heyflow server-side)

High

High (server-direct)

None

Low (no-code in Heyflow)

Meta, TikTok, Microsoft/Bing Ads

Both combined

High

Highest (deduplicated)

Moderate

Medium

Full-funnel attribution across all platforms

The practical recommendation for most performance marketing setups: use Heyflow's native CAPI for Meta, TikTok, and Bing (where signal quality has the most direct impact on CPL), and use GTM for Google Ads conversion tracking, GA4 event tracking, and any other platforms that do not have a native Heyflow integration. The Heyflow integrations overview shows the full list of native connections available without GTM.

Running both in parallel on the same funnel requires deduplication. For Meta, Heyflow handles this automatically by passing a consistent event ID to both the browser Pixel and the CAPI. Meta uses the event ID to count the conversion once, not twice. Without deduplication, you will see inflated conversion counts in Meta Events Manager and distorted ROAS figures.

Debugging Your GTM Setup

GTM's built-in Preview and Debug mode is the right starting point. Click Preview in your GTM dashboard, enter your flow URL, and click through the flow as a real user would. The Tag Assistant panel shows every dataLayer push, every trigger that fired, and every tag that executed, with pass/fail status for each. If a tag is not firing, the trigger configuration is the first place to check: the custom event name in your trigger must exactly match the event name Heyflow pushes to the dataLayer, including capitalisation.

For GA4, open DebugView in your GA4 property while running GTM Preview mode. Events should appear in real time as you progress through the flow. If events appear in GTM Preview but not in GA4 DebugView, the issue is usually in the GA4 Event tag configuration or the Measurement ID. If events appear in neither, the GTM container is not loading on the flow at all, which usually means the container ID was entered incorrectly in Heyflow's settings.

For embedded flows specifically, remember that the parent page GTM container and the Heyflow-connected GTM container must be the same container ID. If you have connected different containers, events from inside the flow will go to a different workspace than your website events, which makes consolidated reporting impossible.

FAQ

Do I need to add GTM to both my website and inside Heyflow separately?

Yes, if you are embedding a Heyflow flow on your website. The Heyflow web component runs in a Shadow DOM that is isolated from your parent page, so a GTM container installed only on the parent page cannot see events inside the flow. You need to connect the same GTM container ID inside Heyflow's integration settings as well. Heyflow recommends using one shared container for both to keep all tags and triggers in one place.

What events does Heyflow push to the GTM dataLayer automatically?

Heyflow pushes lifecycle events including screen views, step progressions, button clicks, form submissions, and flow completions. These are structured dataLayer pushes with named event types and associated parameters like screen index and flow ID. You do not need custom JavaScript to generate these events; they fire automatically once the GTM container ID is connected in Heyflow's settings.

Can I use Heyflow's native Meta CAPI and a Meta Pixel through GTM at the same time?

Yes, and running both together gives you the highest conversion coverage. Heyflow's native CAPI captures conversions that the browser Pixel misses due to ad blockers or iOS restrictions, while the Pixel handles attribution for users whose browsers allow it. Heyflow automatically handles deduplication by passing a consistent event ID to both, so Meta counts each conversion once rather than twice.

Does adding GTM to my Heyflow funnel slow it down?

GTM itself is lightweight, but each tag you fire through it adds to the browser's workload. The more third-party scripts you load client-side, the more load time increases. For ad platform conversion tracking specifically, Heyflow's native server-side CAPI integrations for Meta, TikTok, and Bing send data from the server rather than the browser, so they carry no page speed penalty. Heyflow's mobile PageSpeed scores above 90 reflect this architecture.

How do I track individual funnel steps in GA4 using GTM?

Create a Custom Event trigger in GTM for each Heyflow screen view event, then attach a GA4 Event tag to each trigger that passes the screen index and funnel ID as event parameters. In GA4, you can then build a funnel exploration report using these events as steps. This gives you per-screen continuation rates and shows exactly which screen has the highest drop-off, which is the data you need to prioritise optimisation work.

Do I need a server-side GTM container to use server-side tracking with Heyflow?

No. Heyflow's native server-side integrations for Meta, TikTok, and Microsoft/Bing Ads are direct server-to-server connections configured inside Heyflow's settings panel, with no GTM server container required. Server-side GTM (sGTM) is a separate, more complex infrastructure setup that makes sense for custom or niche tracking scenarios, but for the major ad platforms, Heyflow's native CAPI integrations deliver the same signal quality benefits without the additional hosting and configuration overhead.

Back to top