It is a storage device that is used to store data persistently on the user's device. If any data was stored in local storage then it is going to be persistent and it is not going to be deleted by tab close or window close, any of these activities are not going to clean up your data.

Size limit: you can use a maximum of 5 MB per domain.

Performance: all the operations that you perform like getData,setData, and clear local storage. All of these operations are synchronous. Note: if you want to perform complex computations on the local storage, be aware because it is synchronous, it blocks the main thread and does the computation until, unless the computation is done, it is not going to move ahead.

Data persistence: it persists across browser sessions and tab close. Across the browser session, the same information is shared, and it is not going to be cleaned up and the cleaning has to be done manually by using removeItem or clear storage.

Data structure: key-value pair.

Syntax: key: value Note: The value must always be a string. You can't store a deeply nested object or array directly. Instead, you serialize and deserialize using JSON.stringfy and JSON methods, and then you consume it.

Security:

Use cases(when to use) :

When not to use :