Traffic Metrics

How Witnes counts Page Loads, Unique Visitors, Sessions, and Bounce Rate — and how they relate to each other.

The Traffic page shows three counts for any selected time range: Page Loads, Unique Visitors, and Sessions. They measure different things and are not interchangeable.

Page Loads

A Page Load is recorded every time a user navigates to a page — whether it's a full browser navigation or a client-side route change in a single-page app. Repeat visits by the same person each count as a separate Page Load.

This is the raw volume number: how many times your pages were actually loaded in the selected period.

Unique Visitors

A Unique Visitor is a distinct person. Witnes identifies visitors in two ways depending on whether your app calls identify():

  • Identified users — if your app calls Witnes.identify(userId), the user ID you provide is used directly. The same user on different devices or browsers is counted as one visitor as long as the same user ID is passed.
  • Guest visitors — if identify() is never called, Witnes generates a privacy-preserving fingerprint from the visitor's IP address, browser User-Agent, and your domain. This hash is re-salted every day, so the same browser visiting tomorrow gets a new ID. The domain is included in the hash to ensure visitors are never linked across different websites.

Because the daily salt rotates, guest visitor counts are approximate for periods longer than one day. The same real person may be counted more than once if they visit on different days. Identifying users with identify() gives you accurate long-term counts.

Sessions

A Session is a group of page views by the same visitor with no more than 2 hours of inactivity between them. Sessions are resolved at ingestion time — Witnes checks whether the incoming page load belongs to an existing session before creating a new one.

Rules for session continuity:

  • SPA navigations — client-side route changes always inherit the session from the parent full page load. They never start a new session on their own.
  • Full page loads with a same-domain referrer — if the previous page load by the same visitor was within the last 2 hours and came from the same domain, the session continues.
  • Everything else — a new session starts. This includes first visits, visits after a 2-hour gap, and visits arriving from an external referrer.

A single session can contain many Page Loads (the user visits multiple pages) but it is always attributed to one visitor.

Bounce Rate

Bounce Rate is the percentage of sessions where the visitor viewed only one page and then left. A session is a bounce regardless of how long the visitor stayed on that page — only whether they navigated to a second page matters.

Bounce rate = bounced sessions ÷ total sessions × 100

What counts as clearing a bounce (navigating to a second page):

  • Full page navigations — the visitor clicks a link and the browser loads a new URL within the same session.
  • SPA route changes — in single-page apps, client-side navigations (e.g. React Router, Next.js) are tracked the same as full page loads. A visitor who lands on / and then navigates to /pricing via a client-side link has cleared the bounce.

A high bounce rate isn't always bad. Blog posts, documentation pages, and support articles often have high bounce rates because visitors find what they need on the first page and leave satisfied. Use bounce rate in context — compare it against session duration and page type rather than treating any particular number as a target.

Visit Duration

Visit Duration is the time between the first event of a session and the last recorded activity in that session. It measures how long a visitor was actively engaged, not how long their browser tab was open.

Because there is no reliable "tab closed" event in browsers, visit duration is calculated from real activity: page loads, SPA navigations, and interactions that the tracker records. A session that ends without any further activity after the initial page load will have a duration close to zero, even if the visitor sat on the page for several minutes.

How they relate

The three metrics are always in this order: Page Loads ≥ Sessions ≥ Unique Visitors.

  • Multiple Page Loads can belong to the same Session (a visitor browsing through several pages in one sitting).
  • Multiple Sessions can belong to the same Unique Visitor (a visitor who returned on different days or after a 2-hour gap).

If Page Loads and Sessions are close in number, users are typically landing on a single page and leaving. If Sessions and Unique Visitors are close, users rarely return within the same period.