The Web Storage store user data locally on web browser. It can be store huge data with security without affecting performance of appication. Web storage based on two objects like Local Storage and Session Storage.
Both the storage are almost same except the data persistent time. The web browser does not send data from these storage to server unlike coockie.
• localStorage.setItem(key, value) :: It always key-value pair, It stores value related to key.
• localStorage.getItem(key) :: It stores value related to key.
• localStorage.removeItem(key) :: You can be remove stored item from storage using 'removeItem' method with key value.
• localStorage.clear() :: You can be clear all stored data from storage using 'clear()' method.