Currently looking into various browsers indexeddb limits. Found that Chrome didn't have a hard limit but permissions needed to be given (Source), that Firefox was 50% of local storage (Source) but couldn't find anything for Edge or Safari.
I experimented with Edge and found it didn't have the limit set by IE: 500MB per domain (Source)
Unfortunately navigator.storage.estimate()
doesn't work on Edge https://developer.mozilla.org/en-US/docs/Web/API/StorageManager/estimate
Does anyone have any experience with Edge or Safari regarding this?
Microsoft Edge's IndexedDB limit is 20% of the global max, similar to Firefox and Chrome:
It depends on the device and which version of Edge you're using. The latest version is similar (sic) to Chrome/FF and have the following limits per domain - each domain can take up to 20% of the global limit (which is for all domains):
Source: https://twitter.com/gregwhitworth/status/1020391736974094336
So how big the db can grow per-domain depends on how big your hard drive volume size is.
Safari's IndexedDB limit is unlimited for Desktop, according to: https://developers.google.com/web/fundamentals/instant-and-offline/web-storage/offline-for-pwa
In mobile Safari, apps can use up to 50MB max, whereas desktop Safari allows unlimited storage (and prompts after 5MB)
However, Safari implemented new IndexedDB limits as first tracked in November 2018:
If the size of free disk space is over 1 GB, the default limit is 500 MB; otherwise it is half the free disk space. - WebKit change tracker
Safari seems to be poorly documented at the moment so I thought I'd share my recent experience with Safari mobile (11.4) / IndexedDB storage limitations.
TLDR: 50MB quota does not apply to IndexedDB storage on Safari mobile (11.4)
Initially I thought that there was a 50MB hard limit for combined total of all offline storage methods (Local+Cache+Session+IndexedDB+WebSQL+Cookies).
I am pulling down 180MB of data over the wire and dumping it straight into IndexedDB (browser reports IndexedDB consumption of 98MB - some kind of internal compression going on here) and Safari (mobile 11.4) happily accepts it in IndexedDB.
The 50MB limit seems to apply only to Local / Cache Storage (possibly others), not IndexedDB - I guess volume % quotas apply here.
Side note: don't bother trying to save space in your IndexedDB by compressing content with LZ-string or similar - the browsers internal compression implementation means that it either makes no difference or actually increases the consumption!
As of 19 October 2020 the accepted answer seems to be disprovable by example, since I have just loaded 30G using indexedDB into both Chrome and Edge (latest versions of both). I did so 1G at a time, with hundreds of objects on each iteration, to allow both browsers ample opportunity to object if they elected to do so. They did not.
The data remained persistent and available over restarts of the browsers. According to the accepted answer, I should have been limited to 4G (20% of 20G, since my disk is 500G, or ">128GB").
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With