Guides

Does a break cost tokens? Claude Code’s prompt cache and your pauses

On a Claude subscription, no. Claude Code keeps your conversation’s prompt cache for an hour, so a five- or fifteen-minute break doesn’t cool it. With an API key, usage credits or a cloud provider, the cache lives five minutes, and the first message after a longer pause re-reads your whole context at the cache-write price. Here’s how the cache works, what a cold one costs, and what to do before you step away.

How long the cache lives

Claude Code picks the cache lifetime, the TTL, for every request. By default:

RequestsClaude subscription, within plan usageAPI key, usage credits or cloud provider
Your conversation with Claude1 hour5 minutes
Subagents, workflows, compaction, session titles5 minutes (a few helper requests get 1 hour)5 minutes

“The cache lives five minutes” is the most repeated line about Claude Code, and on a subscription it’s wrong. Five minutes is the API’s default. Claude Code asks for the one-hour TTL on a subscription for your main conversation. Two exceptions: subagents still get five minutes, and once you go over your plan’s limit and draw on usage credits, the main conversation drops to five minutes too, because the shorter cache is cheaper to write.

Each request that hits the cache resets the timer. The clock runs whenever no request goes out: you’re on a break, the session is waiting for your answer, or a long command is still running.

What the cache does

The model doesn’t remember anything between requests. Each time you send a message, Claude Code sends the whole context again: the system prompt and tools, your CLAUDE.md and memory, every earlier message and tool result, and your new message. The cache lets the API reuse what it already processed and work only on what changed.

It matches the start of the request exactly. Anything that changes early in the request, like the tool list or the model, makes everything after it uncached. Anything added at the end, like a new message or a file Claude reads, keeps the rest cached.

What a cold cache costs

When the cache has expired, the next request reprocesses the full context and writes it to the cache again. That turn is noticeably slower and more expensive. Afterwards the cache is warm again.

With an API key, here’s the difference for one session with 150,000 tokens of context on Opus 5.5, at Anthropic’s prices in November 2026:

Your next message after…The 150,000 tokens are billed asCost
A 3-minute pause (cache warm)Cache reads, $0.20 per million$0.03
A 10-minute break (5-minute cache expired)Cache writes, $5 per million$0.75

One break, one session: 75 cents instead of 3 cents. With four sessions open and eight breaks a day, it adds up to a real line on the bill. Your new message and Claude’s answer cost the same either way.

On a subscription you don’t pay per token. Anthropic doesn’t publish how cached and uncached tokens weigh against plan limits; its documentation only says the turn after a miss is slower and more expensive. A break under an hour doesn’t cause a miss.

I take a short break between pomodoros with several sessions open, and on a subscription that’s free. The expensive case is lunch: an hour or more away from a long conversation.

What to do before a break

You’ll also find scripts that ping a session every few minutes to keep its cache warm. Each ping is a request that reads your whole context. On a subscription they save nothing within the hour, and every ping is one more request against your plan.

What cools the cache without a break

Some actions in the middle of a task cost one slow, uncached turn, even if you never left the desk:

Editing files, editing CLAUDE.md, changing permission mode, running skills and spawning subagents keep the cache. So does /rewind, which jumps back to a point that is already cached. Pick the model and effort at the start of a session, and save /compact for natural breaks.

Check if your cache is warm

Where Meowdoro fits

We built Meowdoro, a focus timer around the MacBook notch for people who work with Claude Code and Codex. Each session gets a ring that shows how full its context is. When one is filling up, the break card says so, which is the cheap moment for /compact: the cache is still warm and you’re about to step away anyway. Meowdoro doesn’t warm the cache and never sends anything to your agents. Rest is free on a subscription; Meowdoro just tells you when to take it. Try it and tell us what’s missing.

Questions

How long does Claude Code’s prompt cache last?

One hour for your main conversation on a Claude subscription within plan usage. Five minutes with an API key, usage credits or a cloud provider, and for subagents everywhere. Each request that hits the cache resets the timer.

Does taking a break cost tokens in Claude Code?

On a subscription, not if the break is under an hour. With an API key, a break longer than five minutes means your next message re-writes the whole context to the cache: for 150,000 tokens on Opus 5.5, about $0.75 instead of $0.03.

Should I set promptCacheTtl to 1h?

On a subscription you already get an hour. With an API key it helps if you often leave sessions idle for more than five minutes; it costs more if you work in short, continuous bursts, because one-hour cache writes are priced at 2× the input price instead of 1.25×.

Does /compact reset the cache?

It replaces the conversation history, so that part of the cache is rebuilt from the shorter summary. Compacting while the cache is warm is cheap; compacting after it expired reprocesses the whole conversation.

Why is my first message after a break so slow?

The cache expired, so Claude Code reprocessed your full context. The next turns are fast again.

How the cache works and the TTL defaults: the Claude Code documentation on prompt caching, read on November 9, 2026. Prices and multipliers: the Claude API documentation on prompt caching, read on November 9, 2026; the example counts only the 150,000 tokens of existing context.