What are the differences between cookie, local storage and session storage?
Below are some of the differences between cookie, local storage and session storage:
|Feature||Cookie||Local storage||Session storage|
|Accessed on client or server side||Both server-side & client-side||client-side only||client-side only|
|Lifetime||As configured using Expires option||until deleted||until tab is closed|
|SSL support||Supported||Not supported||Not supported|
|Maximum data size||4KB||5 MB||5MB|
If you like this question & answer and want to contribute, then write your question & answer and email to freewebmentor[@]gmail.com. Your question and answer will appear on FreeWebMentor.com and help other developers.