Skip to content

Privacy and consent

What the browser SDK collects and what it never does, URL redaction, waiting for your users' consent, redacting more at ingest, and sampling.

Updated View as Markdown

The SDK collects what performance and error monitoring need, and nothing that identifies a person unless you add it. Every field is listed in the data reference.

What’s collected

Category What
Performance Page-load phases, route changes, interactions, request timings, Web Vitals and long-task counts
URLs The path and the query string, with sensitive parameters redacted. Fragments (#…) and user info are dropped
Browser The browser, its version, the operating system, the device type (desktop, mobile or tablet) and the User-Agent string
Location The approximate location: country, region and city
Session A random session ID
Errors The error’s type, message and stack trace
Breadcrumbs The last 50 events before an error: views, action names, requests (method, redacted URL, status, duration), and console errors and warnings truncated to 256 characters
User A user ID, only if you call setUser({ id })

What isn’t

  • IP addresses. EZGH looks up the location when data arrives, then discards the address. It’s never stored.
  • Cookies. The SDK sets none. The session lives in localStorage, under the key ezgh_rum_s.
  • Form values and page text. Action names come only from a data-ezgh-action attribute or aria-label, else the element’s tag and ID: never its text.
  • Email addresses or names. There’s no field for them. setUser takes only an ID; use an opaque one.

URLs

The values of these query parameters are replaced with REDACTED in the browser, before anything is sent: token, access_token, id_token, code, state, password, passwd, secret, key, api_key, apikey, session, sessionid, auth, signature and sig. redactQueryParams adds names to the list:

init({ token: "ezgh_ct_…", release, redactQueryParams: ["invite", "reset_token"] });

To remove path segments, such as an account number in /accounts/123456, use beforeSend.

To wait for your users’ consent:

import { init, consent } from "@ezghcloud/rum";

init({ token: "ezgh_ct_…", release, trackingConsent: "pending" });
// later, when the user accepts:
consent.grant();
// and if they withdraw it:
consent.revoke(); // stops sending and clears the session

With "pending", nothing is collected, stored or sent until consent.grant(). Call init with trackingConsent: "granted" (the default) on later visits when you already have consent.

Redact more at ingest

Transform rules apply to browser data as to any other, before it’s stored. For example, to drop user.id from an environment’s browser logs and spans:

logs · statementstxt
delete_key(log.attributes, "user.id")
traces · statementstxt
delete_key(span.attributes, "user.id")

Sampling

sessionSampleRate records a percentage of sessions, decided once per session: with 25, a quarter of your users’ sessions are recorded, completely, and the rest send nothing.

Location data

IP geolocation by DB-IP, licensed under CC BY 4.0.

Navigation

Type to search…

↑↓ navigate↵ selectEsc close