Unused Data Layer Variables

This container defines Data Layer Variables that no tag or trigger references. They exist in Workspace → Variables but are never read at runtime. The variables themselves cost nothing, but they are usually a signal that something was abandoned half-implemented, and they make audits harder by adding noise to the variable list.

CL
By Christopher LandaverdeCreator of AdLint · ad-tech tracking specialistUpdated

Why It Matters

Unused Data Layer Variables typically have three origin stories. (1) A migration left them behind. The old tag was removed but the variable that fed it was not. (2) An implementation was started but never finished. Variables were created in anticipation of tags that were never built. (3) A copy-paste from a sample container or another GTM workspace included variables that this site does not actually push to the dataLayer. None of these are runtime problems, but each one is a small audit-friction tax. The check is info-level because the impact is operational, not behavioural. But ignoring it long enough produces a container where finding the relevant variable means scrolling past 40 abandoned ones.

How To Fix It

  1. In GTM, open Workspace → Variables → User-Defined Variables and identify each Data Layer Variable in the audit's unused list.
  2. For each one, use "Find references". Confirm GTM truly has no references.
  3. Decide per variable: archive if no longer needed, or note in the variable description if it is being kept for a known-future use.
  4. Archive (do not delete). Archiving preserves audit history and is reversible.
  5. Re-run AdLint after the next publish to confirm the count clears.

Example

Configuration
DLV - oldRevenue → ecommerce.revenue
References: 0 tags, 0 triggers
Action: archive after confirming no upcoming work depends on it.
For Your Client Report

Data Layer Variables defined in this container that are not referenced by any tag or trigger. While unused variables do not affect runtime behaviour, they are an operational indicator of incomplete migrations or abandoned implementations and add friction to every audit cycle. Fix: confirm each variable is truly unused, then archive (not delete) to preserve audit history. Source: support.google.com/tagmanager/answer/6164391.

Drop this paragraph into your client deliverable. Sources back to the canonical platform documentation linked below.

References

Audit your own files for this check

AdLint runs this check (and 177 others) against your GTM, Google Ads, Meta, TikTok, LinkedIn, Pinterest, Twitter/X, and Snapchat exports. Everything stays in your browser. No uploads, no accounts.

Run a free audit