CLAUDE LABJP
RELEASE — Claude Code v2.1.243 shipped on August 25 with broad improvements across usage reporting, model selection, sign-in, and reliabilityUSAGE — /usage now breaks results down per loop, showing run count, total tokens, tokens per run, and last run, which makes a chatty /loop task easy to spotSETTINGS — modelPicker lets you curate the /model list with your own order and labels, while promptCacheTtl and subagentPromptCacheTtl let the main conversation and subagents keep different cache lifetimesLOGIN — /login now offers keyless sign-in with an Anthropic Console account, so organizations that do not permit API keys can still get inPERFORMANCE — The native binary is now zstd-compressed, dropping from roughly 340MB to 75MB on Linux x64, and each session uses about 40 to 60MB less memoryFIX — v2.1.245 resolves a startup crash on distributions shipping glibc 2.44, including Arch Linux, CachyOS, and Fedora RawhideRELEASE — Claude Code v2.1.243 shipped on August 25 with broad improvements across usage reporting, model selection, sign-in, and reliabilityUSAGE — /usage now breaks results down per loop, showing run count, total tokens, tokens per run, and last run, which makes a chatty /loop task easy to spotSETTINGS — modelPicker lets you curate the /model list with your own order and labels, while promptCacheTtl and subagentPromptCacheTtl let the main conversation and subagents keep different cache lifetimesLOGIN — /login now offers keyless sign-in with an Anthropic Console account, so organizations that do not permit API keys can still get inPERFORMANCE — The native binary is now zstd-compressed, dropping from roughly 340MB to 75MB on Linux x64, and each session uses about 40 to 60MB less memoryFIX — v2.1.245 resolves a startup crash on distributions shipping glibc 2.44, including Arch Linux, CachyOS, and Fedora Rawhide
Articles/Claude Code
Claude Code/2026-08-26Advanced

I decide the prompt cache TTL by where I come back to, not how long I was away

Claude Code v2.1.242 added promptCacheTtl and subagentPromptCacheTtl. Whether the one-hour cache pays off depends on returning to the same directory and the same git state, not on how long the break was. Here is the order I check things in.

claude-code130prompt-caching14promptCacheTtlcost-optimization30statusline2

Premium Article

Mornings in the iOS wallpaper app repo, afternoons on the web side, back into Xcode by evening. Running several products as an indie developer means moving between working directories many times a day. Every switch, Claude Code seemed to be re-reading the conversation from the top, and the waiting added up.

Claude Code v2.1.242 introduced two settings: promptCacheTtl and subagentPromptCacheTtl. They let you stretch the prompt cache lifetime from five minutes to one hour. My first reaction was that this would suit someone who steps away as often as I do.

Then I read the specification before writing the setting, and the deciding factor turned out not to be the length of the break. Whether the cache is still there when you return depends less on how long you waited and more on where you return to. If the destination has changed, stretching the TTL buys you a cache that never gets read once.

Two knobs, two buckets

Claude Code does not let you place cache_control yourself. It decides both the position and the boundaries. What you get to set is the lifetime, for requests split into two fixed buckets.

BucketRequests it coversSetting key
Main conversationInteractive turns, non-interactive -p runs, Agent SDK turns, and the helpers that run inline with thempromptCacheTtl
Everything elseSubagents, workflows, in-process teammates, forks, compaction, session titlessubagentPromptCacheTtl

Both accept exactly two values, 5m and 1h. Anything else is ignored. Write 30m and it is not rejected with an error; it quietly falls back to the default. That quiet fallback matters later, so keep it in mind.

{
  "promptCacheTtl": "1h",
  "subagentPromptCacheTtl": "5m"
}

The defaults, meanwhile, depend on how you are billed.

BucketClaude subscription, within plan usageUsage credits, API key, or cloud provider
Main conversationOne hourFive minutes
Everything elseFive minutes, except a small set of server-controlled helper requests that get one hourFive minutes

While you are on a subscription and inside your plan's included usage, the main conversation already runs on the one-hour cache. The moment you go over the limit and start drawing on usage credits, that usage is billed to you, so Claude Code drops back to the cheaper five-minute TTL. Sign in with an API key or go through a cloud provider and everything starts at five minutes.

So writing promptCacheTtl explicitly is worth doing in two situations: you are on an API key or a cloud provider, or you are on a subscription and want to keep the hour after passing your plan's limit. If you are comfortably inside your plan, setting "1h" changes nothing that was not already true.

Subagents start at five minutes no matter what you pay

This is where I tripped first. On a subscription, the main conversation is running on a one-hour cache. Call a subagent and that child lands in the five-minute bucket. Exactly when you fan work out in parallel, the side that would benefit most from a warm cache is the side that starts cold.

The reasoning makes sense once you read it. A subagent opens its own conversation with its own system prompt and tool set, separate from the parent's. The prefixes differ, so it cannot read the parent's cache at all. It warms one of its own across its turns instead.

A fork inverts this. A fork inherits the parent's system prompt, tools, and conversation history exactly, so its first request reads the parent's cache. Two ways of splitting work, and from the cache's point of view they are not the same thing. I wrote about their broader differences in branching cuts loose, delegation stays in the session, but the caching behaviour alone is enough to change the choice sometimes.

Does that mean you should set subagentPromptCacheTtl to "1h"? I do not. One-hour writes are billed at a higher rate than five-minute writes, and subagents are short-lived — most finish their job in a handful of turns. There is no reason to pay the expensive write for something that disappears before it can earn it back.

The one case that flips this is calling the same subagent definition repeatedly within an hour. For that, I run the numbers through the break-even formula further down before deciding.

Thank you for reading this far.

Continue Reading

What follows includes implementation code, benchmarks, and practical content we hope you'll find useful. This site runs without ads — server and development costs are supported entirely by members like you. If it's been helpful, we'd be truly grateful for your support.

WHAT YOU'LL LEARN
You'll be able to tell, before flipping the switch, whether your own working rhythm can actually benefit from a one-hour cache
You'll understand why subagents and forks are treated differently by the cache, and pick the right one when you split work
You'll avoid the quiet days where a setting is in place but doing nothing, by checking precedence and unsupported environments up front
Secure payment via Stripe · Cancel anytime

Unlock This Article

Get full access to the rest of this article. Buy once, read anytime. This site is ad-free — your support goes directly toward keeping it running.

or
Unlock all articles with Membership →
Share

Thank You for Reading

Claude Lab is ad-free, supported entirely by members like you. We publish practical guides daily with implementation code, benchmarks, and production-ready patterns. If you've found it useful, we'd love to have you on board.

  • Copy-paste ready implementation code
  • New advanced guides published daily
  • $5/mo or $15 for lifetime access
View Membership →

Related Articles

Claude Code2026-05-05
Claude Code + Ollama: Cutting API Costs with Local LLMs
Worried about Claude Code API costs? Learn how to combine Ollama (local LLM) with a litellm proxy to significantly reduce expenses, and discover a practical framework for deciding which tasks to run locally versus in the cloud.
Claude Code2026-04-21
Claude Code × Python Hybrid Development Patterns: A Production Guide to 50% Token Reduction
Seven production-tested patterns for hybrid Claude Code × Python workflows, each with working code and real-world token reduction data.
Claude Code2026-07-17
The Morning My Table Ended in "… 2,847 more rows" — Separating Render Caps from Token Cost in Tool Output
Claude Code 2.1.209 caps markdown tables at 200 rows plus a remainder count. Only the rendering is capped — the model still receives every row. Here is how to measure the gap and redesign tool output around aggregates.
📚RECOMMENDED BOOKS
Build a Large Language Model (From Scratch)
Sebastian Raschka
LLM Dev
Prompt Engineering for LLMs
Berryman & Ziegler
Prompting
AI Engineering
Chip Huyen
AI Eng
* Contains affiliate links
See all →