Start networking and exchanging professional insights

Register now or log in to join your professional community.

Follow

What is difference between session storage and local storage?

user-image
Question added by Syed Kamran Hyder , Senior UI/UX / Web & Graphic Designer / SharePoint Designer , Saudi Basic Industries Corporation (SABIC)
Date Posted: 2014/02/09
Shahid Riaz Bhatti
by Shahid Riaz Bhatti , Principal Software Engineer (Team Lead) , Sunstar Technologies Pvt Ltd

localStorage and sessionStorage both have different scope.

sessionStorage is accessible only by the window which created it and only for that span of time while the window which created is open.

 

On the other hand, localStoarge is something which is available to the user even if user close the window and then open it again.

 

So main difference is the expiry of the values which are stored in these stoarge.

muhammad  mubeen
by muhammad mubeen , Senior UI / UX Designer , Flowershop.ae

The only difference is that localStorage has a different expiration time sessionStorage will only be accessible while the window that created it is open. localStorage lasts until you delete it or the user deletes it

Jose Jr Dagohoy
by Jose Jr Dagohoy , System Operator , The Shared Electronic Banking Services Incorporated (KNET Kuwait)

Session storage are data that resides on the server which client are accessing while the local storage are on the client storage and typically it is more faster on caching or accessing those files by an application.

More Questions Like This

Do you need help in adding the right keywords to your CV? Let our CV writing experts help you.