🧠 cccache — Prompt Caching in Claude Code
Really understand the cache running behind the scenes when you chat with Claude Code — what gets reused, what breaks, and how to pay 10% instead of 100% from the context.
What you'll understand here
The Claude API is stateless: with every message, the entire conversation (tools + system prompt + history) is sent again. The prompt caching keeps that already-processed beginning and reuses it—instead of reprocessing everything from scratch every turn. It’s a prefix matching: the cache key is the exact bytes up to a cutoff point; a single different byte in the middle invalidates everything after it.
The terms, made simple
Hit, miss, write, TTL, breakpoint, cache_read_input_tokens — each one defined at its first appearance.
What breaks the cache
Change the list of tools, dates in the system prompt, nondeterministic order — the silent invalidators and how to find them.
The real savings
Read ~0.1× · write ~1.25× · uncached 1×. When the cache pays off, and when compacting is more worthwhile.
The 3 tracks
Fundamentals and terms
The problem of reprocessing, the idea of the prefix, hit/miss/write, breakpoint, and verification fields. Each term is defined the first time it appears.
Technical
The cache within a growing conversation, skills and tools (appending vs. breaking), and invalidation in depth — with copy-run examples.
Advanced best practices
Caching vs. compaction, cache-friendly architecture and auditing, and a module of ready-to-use copy-run prompts for Claude Code today.
How to use this course
- Mark each topic as read — the module, track, and course progress bars all advance together.
- Highlight and annotate in the text itself — select a segment to highlight, annotate, or mark as a question.
- Open “My journey” — see progress, questions, and notes, and pick up where you left off.
- Adjust the appearance — theme (dark/light/sepia/focus/high contrast), font, size, width, and line spacing.
- Export your progress — download a
.jsonwith your progress and import it on another device. - 100% offline — opens directly from the file, without a server. Your progress stays only in your browser.