🎙 Free live masterclass · Sun, 29 Nov, 7:00 pm IST · Java Full Stack roadmap Register free →
Skills101
← Quiz: Browser Storage and Cookies: all 10 questions

Quiz: Browser Storage and Cookies · Question 1 of 10

Which storage is cleared when the browser tab is closed?

Which storage is cleared when the browser tab is closed?

  1. A.localStorage
  2. B.sessionStorage
  3. C.IndexedDB
  4. D.A cookie with Max-Age=604800
Answer & explanation

Correct answer: sessionStorage

sessionStorage belongs to one tab and disappears when that tab closes.

Can you get the rest right without peeking?

Take the timed Quiz: Browser Storage and Cookies quiz free. Pass it to earn XP and count towards your certificate.

Start the quiz →