location storage: save the browser local storage, permanent preservation (case of involuntary deletion) can be accessed under the same domain name;
session storage: for a local store session data (session) of these pages can only access data in the same session and after the session ends data also will be destroyed. So sessionStorage not a persistent local storage, only the session-level storage.
Add session
sessionStorage.setItem("key", "value");
Obtaining session
var value = sessionStorage.getItem("key");