HTTP cache

A store that keeps HTTP responses and reuses them for later requests, following the rules the server sends in Cache-Control.

In more detail

A private cache belongs to one user, such as a browser. A shared cache, such as a proxy or content delivery network, serves many users, so it must never reuse a personal or credentialed answer for someone else. Caches key stored answers by method and address, plus any request headers named in Vary.

Example

In the browser: The server's headers decide how long a response stays fresh and when it must be revalidated. A service worker's Cache Storage is separate and fully controlled by your code.

Related terms

Taught in

References