Skip to Content
Platform.Ontology

measureUserAgentSpecificMemory()

Asks for a breakdown of memory the page and its iframes use.

Gets silentlySpeed and timingMemoryWeb browsersWhile you use it

In one line

Can check how much memory the page and its embeds use

Asks for a breakdown of memory the page and its iframes use.

Reports total bytes and per-origin attribution in cross-origin isolated contexts. A noisy but accurate measure of memory use, useful for leaks and for inferring device memory pressure.

What it can and can't do

What the user does: Nothing. The site calls it while the page is open, in a protected page mode

It can

  • Get the total memory the page uses
  • Get a split by source, only in cross origin isolated pages
  • Find memory leaks
  • Guess your device's memory size from the numbers

It cannot

  • See other tabs or apps
  • Get these numbers outside protected pages
  • Work in Firefox or Safari
  • Ask permission first

How it differs between platforms: Chrome and Edge only. Firefox and Safari do not support it.

Browser support

BrowserStatusFirst versionReleasedNote
ChromeSupported892021-03-02None
EdgeSupported892021-03-04None
FirefoxNot supportedNot availableNot listedNone
SafariNot supportedNot availableNot listedNone
Safari on iPhoneNot supportedNot availableNot listedNone
Chrome on AndroidSupported892021-03-02None
Samsung InternetSupported15.02021-08-13None

How a site asks for it

APIperformance.measureUserAgentSpecificMemory()
Browser compat keysapi.Performance.measureUserAgentSpecificMemory
How access is grantednone
What the user seesNot listed
Needs a secure context (HTTPS)No
Needs a user gestureNo
How long it lastsNot listed
How to take it backNot listed
Inside an iframeNot listed

Typical flow

  1. Be cross-origin isolated
  2. Call the method (takes 0 to 20 s, GC-aligned)
  3. Receive bytes and breakdown

Data you get

What comes back: Bytes with noise, async result
Shape: object

FieldTypeUnitRangePrecision
bytesintegerbytes0 to GBnoisy, bucketed
breakdownlistNoneentries per originattribution by URL

Technical limits

  • Cross-origin isolation required
  • Result delayed and noised to prevent Spectre-style use

The story

What it is

A page can ask for a breakdown of how much memory it and its frames use.

For you

You never see it. It helps teams find pages that hog memory and crash tabs. Fixed pages stay faster and your browser is less likely to say Aw, Snap.

For makers

Real time apps and long sessions can leak memory until the tab crashes. This API lets teams measure it from real visitors, but it only works on isolated pages, because it could leak data between sites.

Where you see it

TypeExampleApps
gamesA browser game studio sees tabs crash after 30 minutes and finds a memory leak in a texture loader.None named
videoA video call site tracks memory over a long meeting and fixes a leak that crashed older laptops.Google Meet
creativeA design tool checks memory growth on large files to decide when to warn you to save.Figma
productivityA big web spreadsheet checks memory use in test runs to keep huge sheets from freezing.Google Sheets
developerA QA team runs automated tests that fail a build if memory grows too much.None named
analyticsMonitoring tools collect page memory and show which release made it worse.Datadog RUM, New Relic
shoppingA retailer finds that an endless scroll product list uses too much memory on cheap phones.None named

Risks

  • Only in isolated Chromium pages
  • Rarely used

What the platform says

Good uses and abuse

Legitimate uses

  • Memory leak detection in apps

Known abuse

  • Memory side channel research

Scores

ScoreValueMeaning
Sensitivity2 of 5How revealing the data is
Utility3 of 5How useful it is to honest apps
Friction1 of 5How much the user has to do
Fingerprint bits2Rough identifying entropy, when known

History

  • 2020-09, Chrome: Origin trial replaces performance.memory for precise use
  • 2021-03, Chrome 89: Ships for cross-origin isolated contexts

Sources

How well checked: Based on official documentation.

On this page