Difference between Local Storage and Session Storage, explained:
Local Storage: Local storage is a method that allows us to store key-value pair data in the user's browser. It is stored indefinitely in the browser and has a limit of 10MB.
Session Storage: Session storage is similar to Local storage, but the data is only stored as long as the user's session is active and can store data of up to 5MB. It is terminated as soon as the user closes the browser window.