sessionStorage cleaned up unexpectedly on Android
<p>I have a website which saves a stringified JavaScript object into the sessionStorage. It works well on desktop browsers - data survives over page reloads as per described on MDN.</p>

<p>On Android phones, it is not uncommon that a tab is reloaded when user switches back from another tab or when the browser is brought back from background to foreground, and I expect the sessionStorage will persist. This doesn't however seem to be the case. The sessionStorage is gone missing, as if a new session is created.</p>

<p>I have thought of using localStorage instead, which will not expire even if the session is closed. It doesn't really sort out all my problems though - as I expect a user can open it multiple times on multiple tabs, and do different things on each of them.</p>

<p>So my questions are:</p>

<ol>
<li>Is the sessionStorage behavior described above as expected? If not, what can I do to rectify it?</li>
<li>If the behavior is as expected, and I have to rely on localStorage, how can I identify the object stored for each individual tab?</li>
</ol>

<p>Thanks in advance for your help!</p>