What does the localStorage API store and for how long?

JavaScript Associate Easy

JavaScript Associate — Easy

What does the localStorage API store and for how long?

Key points

  • localStorage stores string key-value pairs
  • Data persists across browser sessions
  • No expiration date is set for stored data
  • Browser tabs or sessions do not affect data storage

Ready to go further?

Related questions