PROMPT CACHING CALCULATOR

How much does prompt caching actually save you?

Caching the stable part of a prompt can cut input costs dramatically at volume — or barely matter, depending on your hit rate. Model it with your own numbers. Discounts and hit rates are editable assumptions, clearly labeled, because they differ by provider and workload.

Discount guide: Anthropic cache reads ≈ 90% off input rate; OpenAI cached input ≈ 50% off. Adjust to your provider and model.

Monthly input cost, no caching

$0.00

Monthly input cost, with caching

$0.00

Monthly savings

$0.00

Input rates come from the auto-updated LLM pricing table. Excludes output tokens and cache-write surcharges. Measure your actual prompt size with the token counter or the chat token counter.

FAQ

Prompt caching FAQ

What is prompt caching?

Prompt caching lets providers reuse the computation for a stable prefix of your prompt — typically the system prompt, instructions, and reference documents — across requests. Cached input tokens bill at a steep discount: Anthropic cache reads cost about 90% less than regular input tokens, and OpenAI cached input is typically about 50% less. Exact rates vary by model and change over time, so the discount here is editable.

What part of my prompt is cacheable?

The prefix that stays byte-identical between requests: system instructions, few-shot examples, tool definitions, and shared context documents. The user message and anything that changes each request is not cacheable. The "cached share" input models what fraction of your prompt is that stable prefix.

What is a realistic cache hit rate?

Caches expire after minutes of inactivity (commonly around 5 minutes, extendable on some providers), so hit rate depends on traffic. A busy production endpoint hitting the same prefix continuously can exceed 90%; a low-traffic internal tool may hit far less. Start with your requests-per-minute and the provider TTL.

Does this include cache write costs?

No. Some providers (notably Anthropic) bill a surcharge of about 25% over the base input rate to write the cache. For workloads with reasonable hit rates the write cost is small relative to read savings, but very low-traffic workloads can lose money on caching — check your provider’s documentation.