measureUserAgentSpecificMemory()
Asks for a breakdown of memory the page and its iframes use.
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
| Browser | Status | First version | Released | Note |
|---|---|---|---|---|
| Chrome | Supported | 89 | 2021-03-02 | None |
| Edge | Supported | 89 | 2021-03-04 | None |
| Firefox | Not supported | Not available | Not listed | None |
| Safari | Not supported | Not available | Not listed | None |
| Safari on iPhone | Not supported | Not available | Not listed | None |
| Chrome on Android | Supported | 89 | 2021-03-02 | None |
| Samsung Internet | Supported | 15.0 | 2021-08-13 | None |
How a site asks for it
| API | performance.measureUserAgentSpecificMemory() |
| Browser compat keys | api.Performance.measureUserAgentSpecificMemory |
| How access is granted | none |
| What the user sees | Not listed |
| Needs a secure context (HTTPS) | No |
| Needs a user gesture | No |
| How long it lasts | Not listed |
| How to take it back | Not listed |
| Inside an iframe | Not listed |
Typical flow
- Be cross-origin isolated
- Call the method (takes 0 to 20 s, GC-aligned)
- Receive bytes and breakdown
Data you get
What comes back: Bytes with noise, async result
Shape: object
| Field | Type | Unit | Range | Precision |
|---|---|---|---|---|
bytes | integer | bytes | 0 to GB | noisy, bucketed |
breakdown | list | None | entries per origin | attribution 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
| Type | Example | Apps |
|---|---|---|
| games | A browser game studio sees tabs crash after 30 minutes and finds a memory leak in a texture loader. | None named |
| video | A video call site tracks memory over a long meeting and fixes a leak that crashed older laptops. | Google Meet |
| creative | A design tool checks memory growth on large files to decide when to warn you to save. | Figma |
| productivity | A big web spreadsheet checks memory use in test runs to keep huge sheets from freezing. | Google Sheets |
| developer | A QA team runs automated tests that fail a build if memory grows too much. | None named |
| analytics | Monitoring tools collect page memory and show which release made it worse. | Datadog RUM, New Relic |
| shopping | A 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
- web.dev: Monitor total page memory usage. Google says it lets sites measure memory across the whole page, to find leaks and bloat.
Good uses and abuse
Legitimate uses
- Memory leak detection in apps
Known abuse
- Memory side channel research
Scores
| Score | Value | Meaning |
|---|---|---|
| Sensitivity | 2 of 5 | How revealing the data is |
| Utility | 3 of 5 | How useful it is to honest apps |
| Friction | 1 of 5 | How much the user has to do |
| Fingerprint bits | 2 | Rough 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
Related capabilities
Related
- performance.memory (legacy heap size). Can see how much memory the page uses, in Chrome and Edge
Sources
How well checked: Based on official documentation.