Setting up Web Developer Tools to monitor cache status and age

To use the HTTP headers — for example, age and cf-cache-status — to see when a page is loaded from the cache and when the cache expires, set up the Web Developer Tools included in your desktop web browser as follows.

Developer tools setup

This procedure uses Chromium

The following procedure was tested using the open source desktop web browser, Chromium.

Other Blink-based browsers (for example, Chrome, Edge, Brave, and Opera) were checked for UI/UX differences and none were found.

The same fields can be setup and used for cache monitoring in Gecko- or WebKit-based browsers, but the procedure for doing so is different.

In the Developer Tools window:

  1. Select the Network tab.

  2. Select the Preserve log checkbox.

  3. Select the Doc option.

    chromium web developer tools network tab preserve log checked doc selected
    Figure 1. Network tab selected; Preserve log checked; and Doc selected
  4. Right-click on the Name row.

    A contextual menu presents.

  5. Select the Name  Response Headers  Manage Header Columns… item.

    chromium web developer tools right click name response headers manage header columns
    Figure 2. Name → Response Headers → Manage Header Columns… menu item
  6. The Manage Header Columns dialog opens.

    chromium web developer tools manage header columns dialog
    Figure 3. Manage Header Columns
  7. Click the Add custom header… button.

  8. Enter cf-cache-status in the Header Name field and click Add (or press Return).

  9. Click the Add custom header… button again.

  10. Enter age in the Header Name field and click Add (or press Return).

  11. Press the Esc key to close the Manage Header Columns dialog.

  12. The two added fields now appear in the Developer Tools window.

    chromium web developer tools added custom headers
    Figure 4. Added custom headers showing

With the Developer Tools setup to display the two required page headers, the Tools can be used to inspect a given page’s cache status and age.