Ecommerce tools without consent
Custom HTML tags containing ecommerce marketing tools are configured with consent NOT_NEEDED or NOT_SET. These tools collect commercial behavioral data and require explicit user consent under GDPR/CCPA.
Summary
- rule_id —
ecommerce-tool-consent - purpose — Detect ecommerce marketing tools deployed via Custom HTML without GTM consent configured
- effect — Tools fire regardless of visitor cookie choice; behavioral and commercial data collected without consent
- layer — container
- reversibility — non-destructive
What fires this
The rule checks active Custom HTML tags for ecommerce marketing tool patterns using two methods: parser-side codeAnalysis flags (set per tool) and regex matching against the raw tag code. Both share the same tool list as the sibling rule ecommerce-tool-custom-html. For each matched tag, the rule checks t.consent. If the value is NOT_NEEDED or NOT_SET, the tag is flagged. Paused tags are excluded. Covered tools include Klaviyo, Segment, Braze, Iterable, mParticle, Omnisend, Drip, and Attentive.
Why it matters
Custom HTML tags have no built-in consent enforcement in GTM (Google Tag Manager). A native Template Gallery tag can be wired to GTM's consent framework; a Custom HTML tag with raw initialization code cannot. It fires on every page load, regardless of what the visitor selected in the cookie banner, unless a CMP (consent management platform) blocks it at the page level. These tools collect commercial behavioral data — product views, purchase history, email addresses — for marketing automation. That collection requires explicit user consent under GDPR and must honor opt-out signals under CCPA/CPRA. Regulatory: GDPR Art. 6 (lawful basis), CCPA/CPRA.
Before / after
{
"name": "Klaviyo - Init",
"type": "html",
"consent": "NOT_SET",
"code": "<script>var _learnq = _learnq || [];\n_learnq.push(['account', 'XXXXXX']);</script>\n<script async src='/static.klaviyo.com/onsite/js/klaviyo.js'></script>"
}
{
"name": "Klaviyo - Init",
"type": "html",
"consent": "NEEDED",
"consentTypes": ["analytics_storage", "ad_storage"],
"code": "<script>var _learnq = _learnq || [];\n_learnq.push(['account', 'XXXXXX']);</script>\n<script async src='/static.klaviyo.com/onsite/js/klaviyo.js'></script>"
}
Remediation
- Open each flagged Custom HTML tag in GTM.
- Set "Additional Consent Status" to "NEEDED."
- Add the appropriate consent type:
ad_storagefor behavioral targeting,analytics_storagefor analytics-only use. - If consent is managed at the page level via a CMP, verify the CMP's blocking list includes each tool's script domain (e.g.,
static.klaviyo.com,cdn.segment.com,js.braze.com). - Add any missing domains to the CMP's blocking configuration.
- Test in "deny all" mode and confirm the tools do not initialize.
- Check whether a Community Template Gallery version exists for each tool — native templates handle consent automatically.
Metadata
- Severity
- high
- Tier
- optimization
- Category
- ecommerce
- Layer
- container
- Version
- 1
- Effort
15min(about 15 minutes)- Reversibility
- non-destructive
- Regulatory
- GDPR Art. 6 (lawful basis), CCPA/CPRA
See also
- Ecommerce tool in custom HTML — sibling rule that flags these tools regardless of consent status
- Health score — how this rule contributes to the score
- Rules catalog — browse all rules
Examples
curl https://developer.tagmanifest.com/v1/evaluate-rule \
-H "Authorization: Bearer $TM_API_KEY" \
-H "Content-Type: application/json" \
-d '{"rule_id":"ecommerce-tool-consent","url":"https://example.com"}'
User: Run ecommerce-tool-consent on https://example.com
# Tool call
{
"tool": "evaluate_rule",
"arguments": {
"rule_id": "ecommerce-tool-consent",
"url": "https://example.com"
}
}