Skip to content
Coming soon: a Shopify app and a WordPress plugin. One-click install, same monitoring.Tell us which one you need
consent mode v2

Why your Custom HTML pixels ignore consent, and how to gate them

Native GTM tag templates get Consent Mode handling built in. A pixel pasted into a Custom HTML tag gets none of it, and fires for visitors who said no. The audit corpus shows this fails on nearly every container that has one.

3 min readBy TagEasy
All posts

There are two ways to put an advertising pixel in Google Tag Manager. You can use the vendor's template from the gallery, or you can paste the vendor's script into a Custom HTML tag. They look identical in the container list and behave completely differently when a visitor declines tracking.

As of October 2026, the public audit corpus shows the Custom HTML consent check failing on every container it applies to. It is the single worst-performing check we run.

What native templates do for you

Google's own tags and the approved community templates declare which consent types they need. When Consent Mode is configured, a tag that requires ad_storage simply does not fire while that type is denied, with no trigger configuration on your part. It is a built-in consent check that runs before the tag.

What a Custom HTML tag does

Nothing. It runs the script you pasted whenever its trigger fires. If the trigger is All Pages, it fires on all pages, for everyone, including the visitor in Germany who clicked Reject. The tag has no idea consent exists.

This is not a bug in GTM. Custom HTML is a general-purpose escape hatch and it cannot know what the script inside it does.

Why it is so common

Vendors hand out install scripts, not GTM templates. Pasting the script is faster than finding a template. The tag works, the vendor's dashboard shows data, and nobody tests with consent denied.

Three ways to fix it, in order of preference

  1. Replace it with a template. Meta, TikTok, LinkedIn, Pinterest, Microsoft and most other vendors have gallery templates now. The template carries the consent declarations, and you remove a Custom HTML tag from the container.
  2. Add consent settings to the tag. Every tag in GTM has an Advanced Settings section with Consent Settings. Choose "Require additional consent for tag to fire" and list ad_storage (and ad_user_data and ad_personalization for advertising pixels). The tag now waits for consent like a native one.
  3. Gate the trigger. Fire the tag on a consent-update event rather than All Pages, with a condition on the consent state. This works but spreads the logic across triggers, which is harder to audit later.

Option two takes thirty seconds per tag and is the minimum.

How to test that it worked

Open the site in a private window, decline the banner, and check the network panel for the vendor's request. It should be absent. Then accept, and it should appear. Doing this once per tag after every container change is the only way to be sure; it is also exactly what a scheduled container audit automates.

FAQ

No. Consent Mode governs Google's own tags and templates that declare consent requirements. A Custom HTML tag has no declaration, so Consent Mode does not restrict it unless you add consent settings to the tag yourself.

For pixels that build audiences and attribute conversions: ad_storage, ad_user_data and ad_personalization. For an analytics-only script, analytics_storage.

How does the audit know a pixel is in a Custom HTML tag?

It reads the published container and lists each tag's type. A known advertising vendor loaded through a Custom HTML tag without consent settings is flagged. Run it on any URL at tageasy.io/check.

Keep reading

Related posts

See where your tracking stands

Run the same 17-check audit referenced in this post against any URL. No signup, results in seconds.