IndexedDB
A large browser database that can hold gigabytes of structured data for one site.
In one line
Can keep gigabytes of organized data for its own site in your browser
A large browser database that can hold gigabytes of structured data for one site.
Stores app data, offline caches and, for trackers, bigger profiles or IDs that survive cookie clearing. Quota is a share of free disk, so a site can fill hundreds of MB without a prompt.
What it can and can't do
What the user does: Nothing. It happens as the site saves your work or caches data.
It can
- Store lots of structured data, such as messages, notes or a catalog
- Keep it between visits
- Work offline with it
It cannot
- Let other sites see it
- Hold more than the site's storage limit
- Keep it after you clear site data
- Keep it after a private window closes
Browser support
| Browser | Status | First version | Released | Note |
|---|---|---|---|---|
| Chrome | Supported | 24 | 2013-01-10 | None |
| Edge | Supported | 12 | 2015-07-29 | None |
| Firefox | Supported | 16 | 2012-10-09 | None |
| Safari | Supported | 8 | 2014-10-16 | None |
| Safari on iPhone | Supported | 8 | 2014-09-17 | None |
| Chrome on Android | Supported | 25 | 2013-02-27 | None |
| Samsung Internet | Supported | 1.5 | 2013-09-25 | None |
How a site asks for it
| API | indexedDB.open(name, version) |
| Browser compat keys | api.IDBFactoryapi.IDBDatabase |
| How access is granted | none |
| What the user sees | None |
| Needs a secure context (HTTPS) | No |
| Needs a user gesture | No |
| How long it lasts | Best effort: kept until the user clears it or the browser evicts under disk pressure. Safari applies the 7 day cap |
| How to take it back | Clear site data, browser privacy settings |
| Inside an iframe | Not listed |
Data you get
What comes back: Records in object stores
Shape: object
How often: any time
| Field | Type | Unit | Range | Precision |
|---|---|---|---|---|
quota | integer | percent of disk | 10 to 60 | approximate |
Technical limits
- Chrome: up to about 60% of total disk per origin
- Firefox: about 10% of disk per site group, up to 10 GiB
- Safari 17+: up to about 60% of disk per origin in the browser
- Eviction is least recently used across origins
- Partitioned in third party frames
The story
What it is
A large browser database that can hold gigabytes of organized data for one site.
For you
You never see it. It is why a web app has your emails or notes ready offline, and why a game keeps big progress without logging in.
For makers
It is the main database of the web. Makers use it for offline apps, game saves and caches. It can also hold an ID that survives clearing cookies in some cases.
Where you see it
| Type | Example | Apps |
|---|---|---|
| games | A browser game made with Unity or Emscripten stores its save files and downloaded levels here. | Unity WebGL games |
| productivity | A web email or notes app keeps all your messages here for fast, offline search. | Gmail |
| creative | A web design tool keeps your open file safe between visits. | Figma |
| media | A web music app keeps your downloaded songs here. | None named |
| messaging | A web chat app stores recent chat history for a quick start. | Slack, WhatsApp Web |
| ads | A tracking script keeps a hidden visitor ID here to bring you back after cookie clearing. | None named |
| security | A web wallet or password tool keeps encrypted data here. | None named |
Risks
- Hidden persistent ID
- Large local data
What the platform says
- web.dev: Storage for the web. Google explains IndexedDB as the main place for large offline data in web apps.
- MDN: IndexedDB API. Documents the browser database that sites use to store large amounts of structured data.
Good uses and abuse
Legitimate uses
- Offline apps, large local data
Known abuse
- Cookie respawn store, large fingerprint caches
Scores
| Score | Value | Meaning |
|---|---|---|
| Sensitivity | 3 of 5 | How revealing the data is |
| Utility | 5 of 5 | How useful it is to honest apps |
| Friction | 0 of 5 | How much the user has to do |
| Fingerprint bits | 0 | Rough identifying entropy, when known |
History
- 2023-07, Chrome 115: Third party IndexedDB partitioned
- 2023-09, Safari 17: Quota model changed: per origin share of disk plus 7 day cap kept
Related capabilities
Related
- localStorage. Can keep up to about 5 MB of text notes per site, until cleared
- Cache Storage. Can keep copies of pages and files so the site opens without internet
- Origin Private File System. Can keep fast private files in the browser that count against its storage limit
Sources
How well checked: Checked against real behavior.