Skip to content

QuizNot attempted

A repeat visit with nothing deployed

Yesterday you visited a site whose HTML is no-cache (with an ETag) and whose hashed assets are max-age=31536000, immutable. Nothing has been deployed since. What network traffic does today's visit cause?
1–4 to choose, Enter to submit
Show answer & explanation

Correct answer:

  • One conditional request for the HTML, answered with 304; the JS and CSS come from the browser cache without any request
  • The HTML must be revalidated (no-cache), and since it didn't change the server replies 304 with no body.
  • The assets are still fresh for a year, so they are used straight from the memory or disk cache.
  • Not "nothing at all": no-cache always costs that check.
  • Not "everything re-downloaded": the ETag makes the HTML check cheap, and fresh assets need no request.
  • Not "304 for each asset": fresh, immutable assets are not revalidated at all.