Web Storage (sessionStorage and localStorage) in private browsing mode (incognito)
Asked Answered
C

2

13

BACKGROUND

The HTML5 Web Storage feature in modern browsers is accessed through Javascript commands such as:

sessionStorage.setItem("username", "John");
localStorage.setItem("username", "John")

The site Can I use indicates that browser support is near 90%. However, in the "Known Issues" tab, Can I use says:

In private browsing mode, Safari, iOS Safari and the Android browsers do not support setting localStorage.

MY QUESTION

In private browsing mode, do Safari, iOS Safari and the Android browsers still support sessionStorage?

Chellman answered 25/9, 2014 at 15:29 Comment(3)
I was looking for an official answer not just a test of one browser. This is unfortunate since sessionStorage, as the name implies, should be allowed in private browsing mode.Chellman
It's disabled with some settings in some browsers. A great work-around available in this question: #35608224 See also: #21159801Boyle
Its 2017 now , has anything changed in regards to private browsing mode (incognito) ?Intellectualize
T
9

Android and chrome I believe allow you to access old keys in session storage, but not write to it. I know that Safari will not allow any use of session or local storage.

similar so question

Thaw answered 18/11, 2014 at 12:3 Comment(3)
what about cookies? would that allow saving just across page refreshes?Giese
@Giese the discussion is beyond Cookies.Janae
@Giese I tested this in FF and cookies work(kept) in private mood across tabsMolotov
N
1

Chrome will support localStorage and sessionStorage in private window.

Noontime answered 29/6, 2018 at 20:11 Comment(1)
but when? could you provide an official link where a such thing is stated? so far not yet supported (jan 2021)Jackinthepulpit

© 2022 - 2024 — McMap. All rights reserved.