title: iOS 'Web App' has different localStorage than Mobile Safari
body: <p>I have a webapp for iPad with the meta tag:</p>
  
  <pre><code>&lt;meta name="apple-mobile-web-app-capable" content="yes"&gt;
  </code></pre>
  
  <p>When I open up the app from the homepage (web-app-capable version) or type in the address in Mobile Safari the contents of localStorage are different. I have confirmed that the addresses are identical by printing location.href.</p>
  
  <p>All changes made to localStorage while using Mobile safari are reflected in the web-app-capable version, but changes made in the web-app-capable version are not reflected in the Mobile Safari version.</p>
  
  <p>The domains are identical, localStorage should be identical. What in the world is going on? Can this be fixed? </p>
  
  <hr>
  
  <p><strong>Update - Solution</strong>: Following suggestion #2 from the accepted answer (forcing the user to be in fullscreen mode) I added this bit of code:</p>
  
  <pre><code>if(("standalone" in window.navigator) &amp;&amp; !window.navigator.standalone)
      window.location = "instructions.html";
  </code></pre>
  
  <p>So, if you are using a browser that supports standalone mode, and you are not in standalone mode, redirect to a page (instructions.html) which shows the user how to add the app to the home screen.</p>
  
  <p>Thank you to everyone for their input!</p>