dl.js tracking tag — there is no separate container script to install.
How It Works
Yourdl.js tag (the single DATALYR snippet) runs the Container on load: it fetches your configured tags from /container-scripts and executes them based on their triggers and conditions. On by default.
Traditional tracking — every pixel hardcoded, each change a deploy:
dl.js tag loads your Meta/Google/TikTok pixels and custom scripts from the dashboard — no extra tags, no code changes.
What You Can Manage
Tracking Pixels Add Meta Pixel, TikTok Pixel, Google Tag, and other tracking pixels with automatic configuration. Custom JavaScript Run custom JavaScript code on specific pages or events without editing your site. Third-Party Scripts Load external scripts (analytics, chat widgets, heatmaps) with trigger control. Event Tracking Track custom events, button clicks, form submissions, and more with conditional logic.Key Features
GTM-Like Triggers
Fire tags based on events:- Page Load: Execute on initial page load
- DOM Ready: Wait for DOM to be ready
- History Change: Fire on SPA navigation (React, Vue, Next.js)
- Scroll: Trigger when user scrolls past threshold
- Visibility Change: Fire when tab becomes visible
Conditional Loading
Control when tags fire with conditions:- URL Path: Match specific pages or patterns
- Query Parameters: Check for UTM parameters or custom params
- Referrer: Target traffic from specific sources
- Device Type: Mobile, tablet, or desktop only
- Custom JavaScript: Write custom logic
Firing Frequency
Control how often tags execute:- Always: Fire every time trigger occurs
- Once per Page: Fire only once per page load
- Once per Session: Fire once per browser session
Built-In Variables
Use dynamic variables in your scripts:{{Page URL}}: Current page URL{{Page Path}}: URL path only{{Page Title}}: Document title{{Referrer}}: Document referrer{{UTM Source}}: utm_source parameter{{UTM Medium}}: utm_medium parameter{{UTM Campaign}}: utm_campaign parameter{{Query String}}: Full query string{{User Agent}}: Browser user agent{{Timestamp}}: Current timestamp
Use Cases
Manage Ad Pixels Add Meta Pixel, TikTok Pixel, and Google Tag from your dashboard. Update pixel IDs without deploying code. A/B Testing Load different scripts for different user segments using conditions. Gradual Rollouts Test new tracking on specific pages before rolling out site-wide. Event Tracking Track button clicks, form submissions, and custom interactions without code changes. Third-Party Integrations Add chat widgets, analytics tools, and heatmaps with conditional loading. SPA Support Automatically handle navigation changes in React, Vue, and Next.js apps.Performance
The Container system is optimized for performance: No extra request for the tag The Container ships insidedl.js — there’s no separate script to download. The only added work is one cached /container-scripts fetch.
Caching
Scripts are cached for 30 minutes on the client and server.
Async Loading
External scripts load asynchronously without blocking page render.
Conditional Execution
Tags only load when conditions are met, reducing unnecessary requests.
SPA Optimized
Detects navigation changes without polling or heavy listeners.
Security
URL Validation All external scripts and pixels are validated for safe URLs (https:// only in production). CSP Support Supports Content Security Policy with nonce attributes. Sandbox Execution Custom JavaScript runs in sandboxed environments when possible. No eval() Inline scripts execute via Function constructor or CSP-nonce injection (no eval).Limitations
Client-side only The Container runs in the browser. For server-rendered pixels, hardcode them and rundl.js in tracking-only mode (enableContainer: false).
Browser Only
Not available for mobile apps (use native SDKs instead).
Delayed Loading
Tags load after the container script fetches configurations (typically 50-200ms).
100 Script Limit
Maximum 100 active container scripts per workspace.
Container mode vs tracking-only
Both use the samedl.js tag — the only difference is whether it manages your pixels:
| Container mode (default) | Tracking-only (enableContainer: false) | |
|---|---|---|
| Pixel changes | instant, from the dashboard | code change + deploy |
| Conditional loading | built-in | you code it |
| Best for | most sites | hardcoded / server-rendered pixels |
Next Steps
Install
Install dl.js — the Container is built in
Managing Tags
Create and configure tags
Container vs Tracking-Only
When to let dl.js manage your pixels
Integrations
Connect ad platforms