Published on 2025-06-22T09:51:51Z
What Is Time on Site? Examples for Time on Site
Time on Site measures the average duration that users spend on your website during a single session. It’s a key engagement metric in web analytics: high values often indicate that visitors find your content valuable, while low values may signal usability issues or irrelevant content. You can track Time on Site with tools like Plainsignal (cookie-free, privacy-focused analytics) or Google Analytics 4 (GA4). Below is an example of how to implement Plainsignal on your site:
<link rel="preconnect" href="//eu.plainsignal.com/" crossorigin />
<script defer data-do="yourwebsitedomain.com" data-id="0GQV1xmtzQQ" data-api="//eu.plainsignal.com" src="//cdn.plainsignal.com/plainsignal-min.js"></script>
By pairing Time on Site with related metrics—Bounce Rate, Pages per Session, Average Session Duration—you gain a fuller picture of user engagement and can prioritize optimization efforts.
Time on site
Time on Site measures the average duration visitors spend per session, indicating user engagement and website performance.
What Is Time on Site?
This section defines Time on Site and explains why it’s a foundational engagement metric for digital analytics teams.
-
Definition
The average length of time users spend on your website in a single session. Calculated as total session duration divided by number of sessions.
-
Why it matters
Helps you understand content relevance and user interest. A higher Time on Site often correlates with better conversion rates and deeper user engagement.
How Time on Site Is Calculated
Different analytics platforms have distinct methods to compute Time on Site. Understanding these nuances ensures accurate interpretation.
-
Ga4 calculation
GA4 computes engagement time by tracking user interactions (pageviews, events) and summing the intervals between them.
-
Plainsignal calculation
PlainSignal uses a lightweight script to record timestamps on page load and unload, then calculates the difference to derive session duration, all without cookies.
-
Key differences
GA4 focuses on engagement events (so idle time may be excluded), while PlainSignal tracks raw load/unload times, which can include idle duration.
Tracking Time on Site with Plainsignal
Step-by-step guide to implement PlainSignal’s cookie-free tracking and validate your Time on Site data.
-
Setup and installation
Add the PlainSignal script to your
<head>
or at the end of your<body>
. Customizedata-do
,data-id
, anddata-api
to match your domain and account. -
Verify data collection
Use your browser’s network tab or PlainSignal dashboard to confirm page load/unload events are being recorded, and check that session durations appear in reports.
Tracking Time on Site with Google Analytics 4 (GA4)
Configure GA4’s enhanced measurement or custom events to capture user engagement time.
-
Enhanced measurement
Enable “Enhanced Measurement” in GA4 property settings to automatically track pageviews and basic engagement metrics without extra code.
-
Custom event tracking
For more accuracy, implement
gtag('event','page_view')
on load andgtag('event','page_unload')
on unload, then use BigQuery or Data Studio to compute durations.
Best Practices and Limitations
Understand common pitfalls and strategies to ensure your Time on Site metrics are meaningful and actionable.
-
Handling zero-duration sessions
Bounce sessions with no interactions often register as zero seconds, skewing your average.
- Use engagement time:
Track user interactions (scroll, clicks) as proxies for active time instead of raw load/unload intervals.
- Implement custom events:
Fire an event on page unload to capture true session durations, even when no other interaction occurs.
- Use engagement time:
-
Cross-device and sampling challenges
Session stitching across devices and sampling in large GA4 properties can distort Time on Site.
- User-id implementation:
Assign persistent IDs to users to join sessions across devices and get accurate durations.
- Adjust data thresholds:
In GA4, reduce sampling by refining date ranges or using BigQuery exports for unsampled reporting.
- User-id implementation: