1 November 2026 • 5 min read
Prompt caching lets the model provider reuse the work it already did on the start of your prompt. If your app sends the same system prompt, tool definitions or reference document on every call, you pay a lower price for that repeated part and wait less before the first word of the answer arrives. This page sets out what the two vendors' own documentation says, with the arithmetic, so a product team can decide whether to turn it on. Figures are as of 1 November 2026; vendors change them, so check the linked pages before you budget.
Both vendors cache the prefix of a request, not the answer. On Claude, the cache covers the request in a fixed order: tools, then system, then messages, up to the block you mark with cache_control. OpenAI describes the stored item as the model's internal key-value state for that prefix, not the tokens themselves.
Two consequences follow. First, anything that changes early in the prompt breaks the match for everything after it. Second, caching does not change the answer. Anthropic states that caching has no effect on how the output is generated, so you can switch it on without re-testing quality.
The multipliers below apply to the normal input price of the model you use. Output tokens are not discounted.
| Claude | OpenAI (GPT-5.6 and later) | |
|---|---|---|
| How to turn it on | Opt in with cache_control | On by default for supported models |
| Default lifetime | 5 minutes, refreshed on each use | 30 minutes |
| Write cost | 1.25× (5 min); 2× for a 1-hour cache | 1.25× (30 min); 2.5× for a 12-hour cache in the Responses API |
| Read cost | 0.1× on most models; 0.05× on Opus 5.5 and Sonnet 5.5 | 0.1× on most models; 0.05× on GPT-6.1 Sol and Terra |
| Smallest cacheable prompt | 512 to 4,096 tokens, by model | 1,024 tokens |
Older OpenAI models work differently: they have no extra write charge and use a model-specific cached-input rate, which you read off OpenAI's pricing page. Check the model you actually call.
Take a long system prompt that costs 1× to process normally. OpenAI's documentation works the example for its models. Writing a prefix once and reusing it once costs 1.35× its ordinary input cost, against 2× without caching. Across ten requests, one write and nine reads cost 2.15×, against 10×.
The same sum holds for Claude's default cache: 1.25 for the write plus nine reads at 0.1 is 2.15×. Anthropic's price page says a 5-minute cache pays off after one read, and the 1-hour cache after two reads.
So the saving depends on how often the same prefix comes back inside the cache lifetime. A support bot that sends the same long policy document with every question gains a lot. A weekly report job that runs once and never repeats a prefix gains nothing and pays the write premium.
Both vendors say caching shortens the wait before the response starts, because the model skips reprocessing the cached prefix. Anthropic says you generally see better time-to-first-token for long documents. OpenAI lists "faster" as one of three benefits.
Neither page gives a latency figure, and OpenAI adds a warning: the cache lifetime decides when you get cache-read pricing, but it does not guarantee that a request reuses the stored state or runs faster. Measure the time to first token on your own traffic before you promise a number to anyone. Caching also has no effect on how long the answer takes to generate.
A hit needs the prefix to match exactly. Anthropic says hits require identical prompt segments, including all text and images up to the marked block. Practical rules from the two vendors:
Do not assume. Read the usage fields in each response.
cache_creation_input_tokens (written) and cache_read_input_tokens (read). If both are 0, nothing was cached, often because the prompt was under the minimum length. No error is raised in that case.cached_tokens in the input token details. OpenAI suggests tracking the hit rate as cached tokens divided by total input tokens.Log both against the cost of each request for a few days. If the hit rate is low, the cause is nearly always a prefix that changes: a timestamp at the top, or a tool list that is rebuilt each time.
For wider cost planning, see our pages on LLM costs at scale and the LLM API comparison for India.
On OpenAI, yes, for supported models. On Claude, no. You opt in by adding cache_control to the request, either at the top level or on individual content blocks.
Anthropic says it has no effect on output generation: the response is identical to one without caching. Only the processing of the repeated input is reused.
Anthropic's price page says the 1-hour cache pays off after two reads, against one read for the 5-minute cache. It helps when the same prefix returns after more than 5 minutes but inside the hour.
OpenAI says caches are not shared across organisations and cannot be reused across regional processing boundaries. Read each vendor's data-retention terms if you handle personal data.
Nine stories, every morning at 09:15 IST.
Get the brief free →