---
title: Chrome Killed the Unload Event. Your Pageview Count Just Got Less Honest.
description: Chrome stopped firing the unload event by default in October 2026, and more back and forward navigations now restore from the bfcache without a page load. Here is how to count those restores, recover lost exit beacons and find what still blocks the cache.
author: LETSGROW Dev Team
date: 2026-12-01
category: Analytics
tags: ["bfcache", "Google Analytics", "Core Web Vitals", "Chrome", "Web Performance"]
url: "https://letsgrow.dev/blog/bfcache-analytics-pageviews-unload-deprecation-chrome"
---
Chrome finished deprecating the `unload` event this autumn. As of Chrome 155, released October 6, 2026, `unload` handlers no longer run by default on any site unless that site explicitly opts back in. Chrome's own docs warn this kind of change shows up in analytics, and it is easy to miss. Two things changed underneath your analytics at once: any tag code that relied on `unload` to send data stopped firing in Chrome, and more of your pages became eligible for the back/forward cache (bfcache), which restores a page from memory without loading it again.

Our position is simple: if your pageview tracking only fires on page load, you are likely undercounting Chrome visits that restore from the bfcache, and the fix is a few lines of code plus one dashboard. Here is what happened and what to do about it.

## What Actually Changed in Chrome

The bfcache is a browser optimization that keeps a page in memory when the user navigates away, with JavaScript paused. If the user hits back or forward soon after, the browser makes the page visible again and resumes JavaScript. According to web.dev, all major browsers include a bfcache, Chrome has had one since version 96, and Chrome usage data shows that 1 in 10 navigations on desktop and 1 in 5 on mobile are back or forward navigations.

The `unload` event and the bfcache never got along. Historically, desktop Chrome (and Firefox) made pages with an `unload` listener ineligible for the bfcache. Chrome's fix was to stop firing `unload` by default. Sites can still opt back in with a Permissions Policy, and enterprises can re-enable it with a device policy. The rollout reached the top 50 sites during 2025, then expanded to all sites in 2026 over eight milestones, from 1% of Chrome page loads in Chrome 146 to 100% in Chrome 155. The exception is Chrome on iOS, which uses the WebKit engine and behaves like Safari.

A second change landed earlier. Chrome now allows pages served with `Cache-Control: no-store` into the bfcache when it judges this safe, with the final rollout to all users scheduled for March and April 2025. Before that change, Chrome's documentation identified `no-store` as the largest reason the bfcache was not used, affecting about 17% of history navigations on mobile and 7% on desktop. Pages are still evicted if cookies change, and a `no-store` page only stays cached for 3 minutes instead of 10.

The net effect: more back and forward navigations in Chrome now restore an existing page instead of loading a new one. Faster for users, and quieter for any script that only listens for a fresh load.

## Why Your Pageviews Look Different

Here is the measurement trap, in Google's own words from the web.dev bfcache guide: many popular analytics libraries don't measure bfcache restores as new pageviews. When a user goes back to your pricing page and it restores from memory, your tag does not run again, because nothing loaded. Chrome's documentation warns that sites may see fewer page loads in analytics as bfcache use grows, and the same applies to ad impressions if ads only load on page load.

Performance data shifts too. bfcache restores replace what would have been repeat page loads, which are usually among your fastest. Remove them from a page-load dataset and web.dev notes the distribution can skew slower even though users got a faster experience. If someone on your team saw load-time metrics drift this year without a code change, this is a candidate explanation worth checking before anyone starts optimizing the wrong thing.

The other casualty is any "send it on exit" logic. If a tag, a custom scroll-depth script or a homegrown time-on-page tracker sends its final beacon from an `unload` handler, that handler no longer runs by default in Chrome (outside iOS, and unless your site opted back in). Nothing errors. The data just stops arriving.

::compare-table
title: "Old Assumptions vs. How Chrome Behaves Now"
columns: ["Assumption", "Reality in Chrome today", "What to use instead"]
rows:
  - ["Every back navigation reloads the page", "Eligible pages restore from the bfcache without loading", "Listen for pageshow and check event.persisted"]
  - ["unload fires when the user leaves", "unload handlers do not run by default since Chrome 155", "pagehide (fires whenever unload would, plus on bfcache entry)"]
  - ["Cache-Control: no-store keeps a page out of the bfcache", "Chrome may cache it unless cookies change or certain APIs are used", "Reserve no-store for sensitive pages; no-cache or max-age=0 for freshness"]
  - ["A drop in pageviews means a drop in visits", "Some of the drop can be uncounted bfcache restores", "Track restores as a separate navigation_type"]
::

## Count Restores Without Double Counting

The fix web.dev recommends for Google Analytics is to send a pageview when a page is restored from the bfcache, using the `pageshow` event and its `persisted` property:

```javascript
window.addEventListener('pageshow', (event) => {
  if (event.persisted) {
    gtag('event', 'page_view');
  }
});
```

We would go one step further and follow web.dev's second pattern: tag every pageview with a `navigation_type` parameter. Send the value from `performance.getEntriesByType('navigation')[0].type` on a normal load, and `back_forward_cache` on a restore. That keeps restores visible as their own segment, so nobody mistakes a tracking fix for a traffic spike. Register the parameter as a custom dimension in your analytics tool so you can actually filter on it.

If you run Google Tag Manager, a reasonable starting point is a small Custom HTML tag that pushes a `bfcache_restore` event to the dataLayer inside that `pageshow` listener, with your pageview tag triggered on it. Test it before publishing, because the exact setup depends on how your container already fires pageviews.

For Core Web Vitals, use Google's `web-vitals` JavaScript library, which supports bfcache restores in the metrics it reports, rather than writing your own logic.

## Find What Still Blocks the bfcache

Counting restores fixes the reporting. Making more pages eligible fixes the experience. Three tools cover it:

**Chrome DevTools.** Open Application, then Background services, then Back/forward cache, and click Test back/forward cache. DevTools navigates away and back and either reports a successful restore or lists the reasons it failed, marking the ones you can fix as Actionable. Lighthouse also includes a bfcache audit.

**The notRestoredReasons API.** Shipped from Chrome 123, it adds a `notRestoredReasons` property to `PerformanceNavigationTiming` so you can collect blocking reasons from real users. For cross-origin iframes, such as many ad and chat widgets, Chrome only reports whether that frame blocked the bfcache, not why. That alone is useful: it tells you which vendor to question.

**CrUX.** The Chrome UX Report includes a navigation types metric with a `back_forward_cache` category, so you can see your share of bfcache navigations without instrumenting anything.

Common blockers to look for, per web.dev: `unload` listeners (which still block the bfcache in Firefox), `window.opener` references, and, in some browsers, open IndexedDB connections or in-progress `fetch()` requests when the user leaves. web.dev also advises adding `beforeunload` listeners only while there are unsaved changes. Close connections on `pagehide` and reopen them on `pageshow`.

::checklist
title: "bfcache Analytics Audit"
items:
  - "Search your codebase and tag manager for unload listeners and move that logic to pagehide"
  - "Add a pageshow listener that sends a pageview when event.persisted is true"
  - "Send a navigation_type parameter with every pageview and register it as a custom dimension"
  - "Run the DevTools back/forward cache test on your top landing pages"
  - "Check your CrUX navigation types for the back_forward_cache share"
  - "Reserve Cache-Control: no-store for pages with sensitive data"
  - "Add beforeunload listeners only while there are unsaved changes, then remove them"
  - "Annotate your dashboards with Chrome's unload rollout window, March to October 2026"
::

## The Takeaway

Chrome did the right thing for users. Instant back navigation is a better experience, and the `unload` event was unreliable long before Chrome removed it. But the browser changed under your measurement stack, and many analytics setups were built on the assumption that every page view starts with a page load. That assumption is wrong now. Spend an afternoon this week adding the `pageshow` listener, tagging navigation types and running the DevTools test on your five highest-traffic pages. Then the next time someone asks why pageviews moved, you will have an answer backed by data instead of a guess.
