unbiased ai

Blog

Prompt caching

Part of the Unbiased glossary: the vocabulary of LLM pricing and infrastructure, defined with receipts instead of adjectives.

Prompt caching lets an LLM API reuse previously processed context instead of recomputing it, billing cached input at a fraction of the normal rate: 10% on most models, and as little as 2.5% on Claude Fable 5.1. Anthropic and OpenAI charge a premium to write the cache, from 1.25x the input rate. For context-heavy workloads it is the largest single cost lever available.

Why it matters

Most production traffic resends the same system prompt, tool definitions, and shared context on every request. Without caching you pay full input price for identical tokens thousands of times a day; with it, those tokens bill at roughly a tenth. Agentic workloads amplify this: coding agents reread files constantly.

Measured: what caching did to a real agentic session

We ran a real Claude Code bug-fix session on Fable 5 and published the full ledger: 5 API calls, 114,419 cached-read tokens against just 1,859 written. The session billed $0.5887 with caching; the identical session without it computes to $1.5422, a 2.6x difference. At Fable rates, caching is not an optimization, it is the difference between viable and not. Full ledger in the Fable 5 breakdown.

Cache rates on current models

The read discount is no longer a flat 90%. Newer models price cache reads lower still, and the write premium depends on how long you keep the cache.

ModelInputCache readRead vs inputCache write
Claude Fable 5.1$10$0.252.5%$12.50 (5 min), $20 (1 hour)
Claude Opus 5.5$4$0.205%$5 (5 min), $8 (1 hour)
Claude Sonnet 5.5$2$0.105%$2.50 (5 min), $4 (1 hour)
Claude Haiku 4.5$1$0.1010%$1.25 (5 min), $2 (1 hour)
GPT-6 Astra$10$110%$12.50 (30 min), $25 (12 hours)
GPT-6.1 Sol$2$0.105%$2.50 (30 min), $5 (12 hours)
GPT-6 Luna$0.10$0.0110%$0.125 (30 min), $0.25 (12 hours)
Gemini 4 Argon$2$0.105%No write charge listed; implicit caching only
Gemini 3.8 Flash$0.75$0.07510%Explicit caches add $0.50 per 1M tokens per hour of storage
Pareto by Unbiased$0.80$0.033.75%No write rate listed

US dollars per 1M tokens, short-context standard rates from the Anthropic, OpenAI and Gemini pricing pages and our pricing page, verified October 26, 2026. Google lists the Gemini 4 Argon rates through November 30, 2026 and the Gemini 3.8 Flash rates through December 31, 2026, doubling after. Every tracked model is in the LLM price index.

When a cache write pays for itself

A write costs more than plain input, so caching only pays once the prefix is read back. At a 1.25x write and a 0.1x read, writing a prefix once and reading it once costs 1.35x its normal input price, against 2x for sending it twice uncached. Anthropic's 5-minute cache breaks even after one read; its 1-hour cache, written at 2x, after two.

Reuse is where it compounds. Over ten requests that share a prefix, one write and nine reads cost 2.15x the normal input price at a 0.1x read rate, against 10x uncached. At Claude Fable 5.1's 0.025x read rate the same ten requests cost about 1.48x. To price your own traffic, use the prompt caching cost calculator.

How each provider turns caching on

All three reward the same habit: put stable content (system prompt, tool definitions, shared documents) first, and the part that changes last.

Common questions

How much does prompt caching save?

Cache reads bill at 10% of the input rate on most Anthropic, OpenAI and Gemini models ($1/M on Fable 5 instead of $10/M), 5% on Claude Opus 5.5, Claude Sonnet 5.5, GPT-6.1 Sol and Gemini 4 Argon, and 2.5% on Claude Fable 5.1. Anthropic and OpenAI charge 1.25x the input rate for short-lived cache writes. Our measured agentic session saved 2.6x overall.

When does caching hurt instead of help?

When your context churns: every change to cached content triggers a write at full or premium price. Stable system prompts and shared documents cache well; per-request context does not.

Do I need to change my code to use caching?

On Anthropic you mark cacheable blocks explicitly. On OpenAI's GPT-6 models, implicit mode places a breakpoint for you, and Gemini 2.5 and newer cache implicitly by default. Either way, structuring prompts so stable content comes first is what makes it work.

How long does a prompt cache last?

On Anthropic you choose 5 minutes or 1 hour, and each read refreshes it. On OpenAI's GPT-6 models the default is at least 30 minutes, with a 12-hour minimum available in the Responses API at a higher write rate.

Is a cache write more expensive than normal input?

On Anthropic and OpenAI, yes: a 5-minute or 30-minute write costs 1.25x the input rate, a 1-hour Anthropic write 2x and a 12-hour OpenAI write 2.5x. At a 0.1x read rate, one write plus one read already costs less than sending the prefix twice uncached.

What does cached input cost on Pareto?

Pareto by Unbiased bills cached input at $0.03 per million tokens, against $0.80 for uncached input and $3.20 for output. Rates are on the pricing page.

Compare any two models

VS

List rates and dated competitor measurements: prices and measured bills. Preliminary Pareto 26.10 benchmark costs per task from October 1, 2026 are on the model card. Verbosity: Edition 2.

See the receipts behind the definitions.
Get started with Unbiased

Try it on one part of your codebase

Set Pareto up in the coding agent you already use and give it a week of real work. Pareto starts at $10 a month.

Hand this to your agent
Read https://unbiased.ai/glossary/prompt-caching/ and tell me what matters for my setup. If Pareto fits, read https://unbiased.ai/works-with/agent.md, find the coding agent I use on this machine, and set it up to use Pareto. Ask before changing any file, and never ask me to paste my API key into chat.

It asks before changing files and never needs your key in chat. Read the agent runbook