Prompt Caching ROI Calculator
See whether caching your system prompt or documents pays off: cache writes, reads, expiry and break-even for Claude, GPT and Gemini.
Updated · By Niraj Kumar · 6 sources
https://checkpre.com/ai/prompt-caching-roi-calculator
Model
Each request
Everything identical at the start of every request: tools, system prompt, reference documents. Most providers will not cache a prefix under about 1,000 tokens.
The user's message and anything else placed after the cached prefix.
Traffic
One request every minute, assumed evenly spread.
- Without caching
- $1,037 a month
- With caching
- $259.89 a month
- Cache writes
- 30 a month
- $0.75 to write
- Cache reads
- 43,170 a month
- at $0.20 per 1M tokens
- Break-even
- 1 read per write
- Reads each cache write needs before it pays for itself
- 1Claude Haiku 5.5Anthropic$12.99
- 2GPT-6 LunaOpenAI$12.99
- 3DeepSeek V4.1 FlashDeepSeek$24.71
- 4GPT-5.6 LunaOpenAI$28.58
- 5Qwen3.7 PlusAlibaba$46.79
- 6Gemini 3.5 Flash-LiteGoogle$59.12
- 7Qwen3.8 FlashAlibaba$74.13
- 8DeepSeek V4 ProDeepSeek$99.22
- 9Gemini 3.8 FlashGoogle$101.00
- 10Claude Haiku 4.5Anthropic$129.95
- 11Grok 4.3xAI$146.12
- 12Claude Sonnet 5.5Anthropic$216.72
- 13GPT-6.1 SolOpenAI$216.72
- 14Claude Sonnet 5Anthropic$259.89
- 15GPT-6 SolOpenAI$259.89
- 16GPT-5.6 TerraOpenAI$285.81
- 17Gemini 3.1 ProGoogle$318.06
- 18Grok 4.7xAI$337.41
- 19Claude Opus 5.5Anthropic$433.44
- 20GPT-5.6 SolOpenAI$519.78
- 21Claude Opus 5Anthropic$649.73
- 22Claude Fable 5.1Anthropic$975.68
- 23Qwen3.8 MaxAlibaba$984.96
- 24GPT-6 AstraOpenAI$1,299
How the Prompt Caching ROI Calculator works
cost = (fresh input × input rate + cached input × cache rate + (output + reasoning) × output rate) ÷ 1,000,000This page uses the same method as the LLM API Cost Calculator, which explains each term and assumption in full.
Worked example
A Claude Sonnet 5 assistant with a 10,000-token system prompt and reference pack, 500 tokens of question and 300 of answer, taking 60 requests an hour around the clock.
- 1Without caching, 43,200 requests a month cost $1,037
- 2With requests a minute apart, the five-minute cache never expires: it is written once a day at $2.50 per million tokens
- 3All the other requests read the prefix at $0.20 instead of $2: 43,170 reads a month
- 4With caching the month costs $259.89
Caching saves $776.91 a month, 75% of the bill. At 6 requests an hour the five-minute cache expires between requests, every request pays the write premium, and caching instead costs $21.60 more; the one-hour cache fixes that.
Frequently asked questions
How much does prompt caching save?
A cache hit is billed at 10% of the input rate on most models listed, 5% on Claude Opus 5.5 and 2.5% on Claude Fable 5.1. Writing to Anthropic's five-minute cache costs 1.25× input and its one-hour cache 2×, so a cached prefix pays off from the first read on the five-minute cache and the second on the one-hour cache. Google charges a storage fee per hour instead. Caching only works on an identical prefix, so put stable content first and anything that changes per request last.
Should I use the five-minute or the one-hour cache?
Use the five-minute cache when requests reuse the prefix at least every few minutes, since each hit refreshes it and the write is cheaper. Use Anthropic's one-hour cache when the gaps are longer, for example a user who replies after twenty minutes or an agent step that runs past five: it costs 2× input to write and needs two reads to break even, but it survives the gap.
How does caching work on OpenAI and Gemini?
OpenAI lists a cache write rate of 1.25× input and a cached-input rate of a tenth, with no one-hour option, so the calculator treats it like a five-minute cache. Google's explicit context cache is billed at the normal input rate to create and then per million tokens per hour of storage, so it pays only above a steady request rate.
Why is my cache hit rate low?
Caching matches an exact prefix, so any byte that changes invalidates everything after it. The usual culprits are a timestamp or request ID in the system prompt, tools listed in a different order, or JSON serialised with unsorted keys. Prefixes below a model's minimum cacheable length, from 512 to 4,096 tokens on Claude models depending on the model, are not cached at all. Check the cache-read token count each response reports.
Sources
- Anthropic, Claude API pricing · checked
- OpenAI, API pricing · checked
- Google, Gemini API pricing · checked
- DeepSeek, Models and pricing · checked
- xAI, Models and pricing · checked
- Alibaba Cloud Model Studio, Model pricing · checked
Related calculators
- LLM API Cost CalculatorPrice a real workload across Claude, GPT, Gemini, DeepSeek, Grok and Qwen side by side, with prompt caching, batch discounts and exact token counts.
- AI Coding Agent Cost CalculatorWhat an AI coding agent costs per task and per month, where every step resends a large context that mostly caches and the model thinks before it acts.
- AI Chatbot Cost CalculatorWhat a customer support or assistant chatbot costs to run on Claude, GPT or Gemini per month, with the system prompt cached.
More in AI, Cloud & Developer
- LLM Cost per Million Words Calculator
- RAG Cost Calculator
- LLM Summarization Cost Calculator
- LLM Classification Cost Calculator
- Claude Sonnet 5 vs GPT-6 Sol API Cost
- Claude Sonnet 5 vs GPT-5.6 Terra API Cost
- Claude Sonnet 5 vs Gemini 3.1 Pro API Cost
- Claude Sonnet 5 vs Claude Opus 5.5 API Cost
- All 99 AI, Cloud & Developer calculators