DEV Community

NEYAZ NAFIZ
NEYAZ NAFIZ

Posted on

Difference Between Local Storage And Session Storage in browser

A browser has two different storage. Session Storage and Local Storage. The storage stores two types of data, it's called Key and Value. And every single value is stored as an object. But the main difference between Local Storage and Session Storage is Local Storage stores data for permanent and Session Storage site data for temporary. As an example, if you open a browser and browse something then close the browser when you close the browser the session storage data was removed but the local storage still stores those data and when you again the browser works for that depend on past data. That's the main difference between Session Storage and Local Storage.

Top comments (0)