1. Web-and-CMS-Integrations
NexaGuard
  • Getting-Started
    • NexaGuard Developer Documentation
    • Quickstart (5 to 10 Minutes)
    • Documentation Overview
    • Concepts and Glossary
  • Compliance-and-Standards
    • Compliance Overview
    • IAB TCF v2.3 Support
    • Google Consent Mode v2 Validation
    • TCF API Validation
    • Audit Checklist (Pre-Launch)
  • Web-and-CMS-Integrations
    • NexaGuard CMP SDK – Web & GTM Setup
    • Integrate NexaGuard CMP with Webflow and Wix
    • Integrate NexaGuard CMP with WordPress
    • Integrate NexaGuard CMP with Drupal
    • Integrate NexaGuard CMP with Shopify
    • Google Tag Manager (GTM) Template Guide
  • Mobile-SDKs
    • NexaGuard CMP SDK - iOS Setup
    • iOS SDK API Reference
    • NexaGuard CMP SDK - Android Setup
    • Android SDK API Reference
    • App Attribution Partner (AAP) Integrations
  • Developer-Reference
    • Web JS API Reference
    • Consent Event Schema
    • Deployment and Environments
    • NexaGuard Debug Tool
    • Troubleshooting Playbook
    • Performance and Best Practices
    • Accessibility and UX Guidelines
    • Localization Workflow
    • Migration Guide
  • Security-and-Privacy
    • Security Overview
    • Privacy Architecture
    • Data and Logging Transparency
    • Subprocessors
    • CSP and Network Allowlist
  • Enterprise-and-Legal
    • DPA and Legal Pack
    • RFP Feature Matrix
    • Status and Reliability
    • Support and Escalation
    • NexaGuard CMP SDK – Commercial Licence
  • Operations
    • Changelog and Version Policy
  1. Web-and-CMS-Integrations

Google Tag Manager (GTM) Template Guide

Last updated: March 30, 2026
Use this page as the primary implementation guide for deploying NexaGuard CMP through the Google Tag Manager Community Template Gallery.

1. Ownership Model#

Typical production ownership:
Customer owns GTM container access, tag creation, trigger assignment, and publishing.
NexaGuard (CMP provider) owns template correctness, documentation, support path, and troubleshooting guidance.
Installing a template from Gallery does not create a live tag by itself. A tag instance must still be created and published in the customer container.

2. Prerequisites#

Before setup:
Active GTM web container.
Valid NexaGuard Settings ID.
No duplicate CMP loaders (avoid running direct script embed and GTM CMP tag at the same time unless intentionally designed).

3. Install from Community Template Gallery#

1.
In GTM, open Templates.
2.
Select Search Gallery.
3.
Add NexaGuard CMP.
4.
Confirm template status shows linked to Gallery.

4. Create the Live CMP Tag#

1.
Open Tags -> New.
2.
Choose tag type NexaGuard CMP.
3.
Configure required field:
Settings ID (required)
4.
Configure optional policy fields as needed:
Global Defaults (JSON)
Region Override List (CSV, optional)
Region Override Defaults (JSON, optional)
Wait for Update (ms) (minimum enforced at 500)
5.
Set trigger:
Consent Initialization - All Pages
6.
Save and publish.
Important template behavior:
Developer ID is locked by template and not customer-editable.
Loader endpoints are locked to NexaGuard domains and not customer-editable.
wait_for_update is clamped to a minimum of 500ms.

5. Required Google Consent Signals#

Ensure all four Consent Mode v2 keys are handled:
ad_storage
analytics_storage
ad_user_data
ad_personalization
Expected baseline default object:

6. Validation in Tag Assistant#

Run validation in a fresh preview session.
1.
Consent Initialization event
NexaGuard CMP must appear under Tags Fired.
Consent tab must show default values present (not "Consent not configured").
2.
Before user action
No user-action consent update event should appear.
3.
After explicit user action
gtag("consent","update", ...) should reflect mapped choice.
cmp_consent_update dataLayer event should appear after user action.
4.
Network
Confirm request to:
https://cmp.nexaguard.com/loader.js?...

7. Audit Evidence Pack (GTM Scope)#

Capture and archive:
Tag Assistant screenshot: Consent Initialization defaults.
Tag Assistant screenshot: post-action consent update.
Data Layer screenshot/log: cmp_consent_update.
Network screenshot/log: loader request.
Template version and commit reference used for rollout.

8. Common Failures and Fixes#

A) "No tags were evaluated in this container"#

Cause:
Template installed, but no live CMP tag instance with the correct trigger.
Fix:
Create NexaGuard CMP tag and trigger it on Consent Initialization - All Pages.

B) "Consent not configured"#

Cause:
CMP tag did not execute at Consent Initialization.
Fix:
Verify trigger, publish state, and that the tag is not paused.

C) Banner does not show#

Possible causes:
Tag did not fire.
Settings ID missing/invalid.
Existing consent state suppresses first-layer banner.
Duplicate implementation conflict (direct script + GTM tag).
Fix:
Verify tag fire at Consent Initialization, check Settings ID, and retest in incognito.

D) Duplicate or conflicting consent defaults#

Cause:
Multiple tools push consent defaults.
Fix:
Keep one clear owner for default writes, and document ordering.

9. Production Checklist#

Before release:
1.
Trigger is Consent Initialization - All Pages.
2.
Settings ID is present.
3.
Container is published (not only preview).
4.
Tag Assistant trace is captured.
5.
No duplicate CMP loaders or default writers.
6.
Support routing is documented for customer escalations.

10. Related Pages#

Web Setup
Google Consent Mode v2 Validation
Troubleshooting Playbook
Audit Checklist Pre-Launch
Support and Escalation
Previous
Integrate NexaGuard CMP with Shopify
Next
NexaGuard CMP SDK - iOS Setup