GTM Triggers: The Complete Guide to Firing Your Tags at the Right Moment

Master Google Tag Manager triggers. Clicks, forms, scroll, timers, dataLayer events and custom triggers: everything you need to fire your tags precisely.

In Google Tag Manager, a trigger defines when and where a tag should fire. Without a trigger, no tag ever runs. Choosing the right trigger is essential for precise tracking. This guide details every type of GTM trigger.

Why triggers are critical

A poorly chosen trigger can corrupt all your data. Imagine a conversion tag that fires on a simple button click instead of on the order confirmation page — you'd be counting phantom conversions.

Conversely, a trigger that's too restrictive can cause you to miss real conversions.

Trigger precision determines data quality.

GTM trigger types

Pageview triggers

Page View (pageview) — Fires when the DOM loads. This is the trigger used for most configuration tags (GA4, pixels...).

DOM Ready — Fires when the DOM is fully loaded but before complete rendering. Useful when your tag needs to access page elements.

Window Loaded — Fires after the page fully loads (images, scripts...). Useful for measuring load performance.

Filtering by URL: for each pageview trigger type, you can add conditions. For example: "fire only if URL contains /confirmation".

Click triggers

All Elements — Fires on any click anywhere on the page.

Just Links — Fires only on clicks on <a> tags. Ideal for tracking outbound link clicks or downloads.

Advanced options for clicks:

  • Wait for tags: delays navigation until your tags have fired
  • Check validation: ensures the form is valid before firing

To target a specific button, use conditions on click variables:

  • Click ID: the id attribute of the clicked element
  • Click Classes: the CSS classes of the clicked element
  • Click Text: the button text
  • Click URL: the link URL

Form submission triggers

The Form trigger fires when a user submits a form. It's one of the most commonly used in lead generation.

Targeting conditions:

  • By form ID
  • By CSS class of the form
  • By page URL

Warning: GTM can't always detect AJAX form submissions (Single Page Applications). In that case, prefer a dataLayer event-based trigger pushed by your developer.

Element visibility triggers

This trigger fires when a specific element becomes visible in the user's viewport.

Common uses:

  • Fire an event when a page section is seen
  • Measure visibility of a CTA block
  • Track the display of a promotional banner

Key settings:

  • Select the element by CSS ID or CSS selector
  • Define the minimum visibility percentage (50%, 100%...)
  • Fire once per page or every time

Scroll depth trigger

Fires when the user scrolls to a certain vertical percentage of the page.

Example: fire a scroll_depth event at 25%, 50%, 75% and 100%.

Available variables:

  • Scroll Depth Threshold: the percentage reached
  • Scroll Direction: vertical or horizontal

Timer trigger

Fires after a user has spent a certain amount of time on the page.

Settings:

  • Interval: in milliseconds (e.g. 30000 = 30 seconds)
  • Limit: maximum number of fires per page

Useful for measuring user engagement (e.g. reading a long article).

History change trigger (SPA)

For Single Page Applications (React, Vue, Angular...), the URL changes without a full page reload. The History Change trigger detects these "page" changes.

This is essential for correctly tracking modern e-commerce sites or web applications.

Custom event trigger (dataLayer)

This is the most powerful and reliable trigger. It fires when your developer pushes a specific event into the dataLayer.

dataLayer.push({
  'event': 'purchase_completed',
  'orderId': '12345',
  'orderValue': 149.90
});

In GTM, you create a "Custom Event" trigger and enter the name purchase_completed. This trigger will activate your tag only when that event is pushed.

Advantages:

  • Maximum precision — you control exactly when the event fires
  • Rich data — you can pass contextual information
  • Reliability — doesn't depend on DOM structure (which can change)

Combining multiple triggers

A tag can have multiple triggers and multiple exceptions.

Example: track clicks on a CTA button everywhere on the site, except on the confirmation page.

  • Trigger 1: Click on #btn-cta
  • Exception: Page URL contains /confirmation

Exceptions let you fine-tune your firing conditions precisely.

Best practices for your triggers

Always test in Preview mode before publishing. GTM Preview mode shows you exactly which triggers fired and why.

Prefer dataLayer triggers for your critical conversions. They're more reliable than click or form-based triggers.

Name your triggers clearly: [Click] - CTA Homepage - Book a Call is far clearer than Trigger 1.

Document your conditions: note why you added each condition. Your future self (or colleague) will thank you.

Conclusion

Triggers are the conditional logic of your tracking. Choosing and configuring them correctly makes the difference between a reliable analytics setup and unusable data.

When in doubt, always opt for dataLayer event-based triggers: they give you maximum control over your tracking precision.

Book a free 30-minute consultation to review your setup.

Need help with your analytics?

← Back to Google Tag Manager