Speed
Cache pages without serving old content
Either every visit rebuilds the page, or visitors see yesterday’s version.
- What you get
- A caching rule for each kind of page, and a way to refresh the moment content changes.
- Paste it into
- Your AI tool, in your project
The prompt
Review caching in this project so pages are fast and still correct. List the kinds of pages and data here and sort them: the same for everyone and rarely changing, the same for everyone and changing often, and personal to the signed-in user. For each, tell me how it's cached today (framework, CDN, browser) and whether that's right. Propose a rule for each kind: how long it can be reused and what event should refresh it. Make sure nothing personal is ever stored in a shared cache. Apply the changes, then show me the cache headers for one page of each kind and how to force a refresh when I need one.
Use it
Open your AI tool (Claude Code, Codex or Cursor) in your project folder and paste it in.
More in Speed
Make a slow page fast, with numbers
You ask for a faster site and get a cache bolted on and no proof.
Fix heavy images
A hero photo straight from a phone weighs more than the rest of the site.
Shrink the JavaScript you send
The site downloads megabytes of code before anything is usable.
Find why an action feels slow
You click a button and wait two seconds with nothing happening.