Skip to main content
The Zeotap Web JS SDK (zeotap.js) is a lightweight client-side library that tracks page views, events, user identities, and user properties from your website. The data flows into your Zeotap CDP, where it powers segmentation, calculated attributes, profile lookups, and downstream activation.

How it works

The SDK ships as a small async snippet you paste into the <head> of your site. Once initialized with your Source’s write_key, the global window.zeotap object exposes tracking methods:
  • setPageProperties — page-level context attached to subsequent events on the page
  • setEventProperties — named events with arbitrary properties
  • setUserProperties — current snapshot of user attributes
  • setUserIdentities / unsetUserIdentities — identifiers used to stitch events to profiles
  • setConsent — user consent signals (track, cookie sync, brand consent)
The SDK also integrates with TCF 2.0 CMPs automatically when present.

Prerequisites

  • Access to a Zeotap CDP instance
  • A Web JS Source created in the CDP (it provides your write_key)
  • A CMP integration on your site if you’re not using the default opt-in consent strategy
See Create a Web JS Source for how to create the Source and obtain your write_key.

Explore the docs

Quick Start

Paste the snippet, initialize the SDK, and send your first event.

Configuration

All init() options — consent flags, hashing, cookie storage, retries, ID5, GA.

API Reference

Every tracking method, every parameter, every payload shape.

Consent Resolution

Default opt-in, GDPR TCF, and custom consent flows.

Examples

AMP support, identity patterns, GA capture, contextual data.

FAQ

Troubleshooting common implementation issues.
Last modified on June 22, 2026