The web is full of contradictory pointers to browser specificity details on the above matter and this is why I'd prefer to get some expert advice. Currently I don't care about non webkit browsers. But the more I study the subject, the more confirmations, that it is currently rather impossible, I find. So, I'd be grateful for any insights, tips or whatsoever. Also I wonder about how things may change with flow of time. Thanks.
What are the ways to get more local storage space (than standard 5M limit or so) for your HTML5 app?
-
5 megs should be enough for anyone... – Ben Parsons Apr 16 '12 at 08:58
-
1@op, see tagawas answer here: http://stackoverflow.com/questions/13567509/what-happens-when-localstorage-is-full – john-jones Apr 03 '14 at 10:31
1 Answers
A section in the draft says the following about raising the localStorage limit:
Site-specific white-listing of access to local storage areas User
agents may allow sites to access session storage areas in an unrestricted manner, but require the user to authorize access to local storage areas.
-- http://dev.w3.org/html5/webstorage/#user-tracking
I'd recommend you test for yourself in the browsers you intend to support.
My results in Chromium was a hard limit of ~2600k characters.
EDIT: There's some information on What is the max size of localStorage values?.
Actually Opera doesn't have 5MB limit. It offers to increase limit as applications requires more. User can even choose "Unlimited storage" for a domain.
I also found https://groups.google.com/a/chromium.org/group/chromium-discuss/msg/45153a251b4f441b which states that unlimited storages is available for Chromium apps.
-
Thank you, joar. I didn't know about unlimitedStorage permission for chrome-apps and this sounds promising to me as I asked my question thinking about building a chrome-app. I'll check later if it really works and then will accept your answer. – mcmlxxxiii Apr 16 '12 at 10:14
-
Perhaps the example at https://developers.google.com/chrome/apps/docs/developers_guide#live will make you more confident. – joar Apr 16 '12 at 13:13
-
Although, your answer is correct, @joar, the unlimitedStorage permission is not working with localStorage. See the image: http://s17.postimage.org/d3wqtlsjj/Screenshot.png – mcmlxxxiii Apr 17 '12 at 19:29