Optimizing for cost and intelligence
Balance cost and intelligence on the Claude Platform, with measured results for prompt caching, effort, model choice, output caps, and multimodel strategies.
The most capable model can be too expensive at scale, and the least expensive model can fall short on quality. The Claude Platform gives you direct control over that tradeoff. You choose the model, the effort level, and the architecture for each request, which lets you place a workload almost anywhere on the cost-to-intelligence frontier.
Cost and intelligence are usually pictured as a frontier where one buys the other. The first group of levers on this page moves a workload toward that frontier by cutting cost without touching quality; only the second group moves along it:
The levers come in two kinds:
- Free wins cut spend without touching quality: prompt caching, token hygiene, a prompt audit against the model you are running, and batch processing at 50% off for work that can wait up to 24 hours.
- Tradeoffs exchange cost for intelligence: model choice, effort, output caps and session budgets, an elapsed-time clock, and multimodel architectures.
A workspace spend limit is the backstop for both kinds of lever: see Set budgets and output caps.
Each lever comes with measured results and the rule for when it pays. In Anthropic’s measurements, prompt caching was usually the largest lever. The multimodel levers are narrower; a second model was measured in two shapes, an advisor and an orchestrator.
Start here
Match your situation to a row.
| Your situation | Do this | Where |
|---|---|---|
| Any workload, any model | Turn on prompt caching and trim unneeded tokens; both are free | Cache repeated context · Trim tokens |
| A person waits between turns | Count the gaps between your requests, then pick the cache duration from the table in that section | Pick the cache duration |
| Costs are too high; quality is fine | Try lower effort on the model you use now | Tune effort |
| You are not on the latest model | Upgrade; on the coding benchmarks in that section each newer model solved at least as many tasks as the one before it, usually for less per solved task | Upgrade the model |
| You are choosing or switching models | Compare on cost per completed task, not per token | Compare models |
| High-volume work with outputs you can check | Try Claude Haiku 5.5 first | Compare models |
| Quality isn’t good enough | If you lowered effort, restore it; otherwise try the next tier up at its default effort | Tune effort · Compare models |
Attempts end with stop_reason: max_tokens | Raise max_tokens to 64,000: in Anthropic’s tests only 7 of about 18,000 turns were longer, and cost per solved task did not rise | Set budgets |
| You can check outputs (tests, a verifier) | Run at low effort and re-run failures at high: in Anthropic’s tests, about 40% lower cost than everything at high, at the same pass rate | Re-run failures |
| Agent loops with a few very costly runs | Set a Claude Managed Agents session budget and a workspace spend limit | Set budgets |
| You want agent runs to finish sooner | Tell the model time matters and show it the elapsed time: 7% to 47% less time in Anthropic’s tests, for a few points of score | Show the model elapsed time |
| A lower-cost model stalls only on hard decisions | Try an advisor. It can help only when your model consults it; first price its model alone at low effort and measure the consult rate | Advisor strategy |
| The work exceeds one context window | Split the work and hand the parts to lower-cost models | Orchestrator strategy |
These results are Anthropic-internal (Benchmarks referenced) and directional, not guarantees, so measure on your own workload with the four-step method.
Cut spend without losing quality
Prompt caching, token hygiene, batch processing, and a prompt audit against your current model all lower what you pay without lowering output quality. Two caveats apply: batch processing trades latency for its discount, and context editing, a token-hygiene lever, cost more than it saved on the short run measured in this section and changed nothing on the long one.
Cache repeated context
Why caching comes first
Turn on prompt caching before any other lever, because by default every turn of an agentic task resends the entire growing conversation: system prompt, tool definitions, and every prior turn.
- A 40-turn task sends its first turn 40 times, so task cost grows with roughly the square of turn count.
- Caching does not stop the resending, but each resend costs about a tenth as much (a twentieth on Claude Opus 5.5 and Claude Sonnet 5.5, a fortieth on Claude Fable 5.2, Claude Mythos 5.2, Claude Fable 5.1, and Claude Mythos 5.1) and processes faster.
- The prefix is billed at the cache-read rate instead of the input price, and each turn pays the 1.25x cache-write rate only for what is new.
Message threads, in beta, stop the resending while a thread lasts, until 5 minutes after its last request. They lower time to first token, not cost: the model still reads the whole conversation, so keep cache_control on every request. Threads don’t support compaction or most context editing.
What good looks like.
- Over a full day of real traffic, agent loops read a median 84% of their input from the cache, and the top 10% of them, coding or not, read 94% or more17.
- Deep in a task, a well-built loop pays full price on under 1% of its input.
- Below about 80%, look for something breaking the cache (see What breaks the cache).
Anthropic priced the DeepResearch Bench II7 runs with and without the cache discount:
The cache’s default lifetime is 5 minutes and an agent loop’s turns are seconds apart, so the discount applies to most tokens on every turn. The caching chart’s runs read 89% to 93% of their input tokens from the cache.
Pricing other runs’ recorded token counts the same way, each model at its default effort, gives the average token cost per task without caching:
| Benchmark | Model | Without caching |
|---|---|---|
| SWE-bench Pro3 | Claude Opus 5.5 | 3.3 times the cost with caching |
| SWE-bench Pro | Claude Sonnet 5.5 | 3.1 times the cost with caching |
| Claude Managed Agents task set25, whose sessions are short | Claude Haiku 5.5 | 1.7 times the cost with caching |
| A small agent that triages bug reports (Trim input and context tokens)16 | Claude Sonnet 5.5 | 7.3 times the cost with caching |
The saving varies with how many turns a task takes, because shorter loops re-read less.
Pick the cache duration
If your loop waits on a person between turns, use the 1-hour cache duration once about 1 turn in 20 follows a pause between 5 minutes and an hour and few gaps run over an hour. On Claude Fable 5.2, Claude Fable 5.1, Claude Opus 5.5, and Claude Sonnet 5.5, keeping the 5-minute cache warm can cost less.
The 1-hour duration costs more to write (2x the input price instead of 1.25x). A miss on either duration bills the whole prefix at the write price instead of the read price.
Choose the cache duration when a conversation starts. In Anthropic’s test, the first turn added at 1 hour to a conversation cached at 5 minutes wrote the whole prompt again, once: $0.80 USD at 100,000 tokens on Claude Opus 5.5, compared with $0.02 USD of input for a turn that read the cache16.
Anthropic measured a small agent that triages bug reports (Trim input and context tokens) with pauses inserted before some turns to simulate a person’s delay16. Accuracy stayed within run-to-run noise at every setting measured. Anthropic also measured extra requests that keep the 5-minute cache warm (keep-alive requests).
To decide, count the gaps between consecutive requests in a conversation, and find your row in the following table. A row that names your model takes precedence over a row with “Any” in the Model column:
| Your gaps between requests | Model | Use |
|---|---|---|
| Turns arrive seconds apart | Any | 5-minute default |
| About 1 gap in 20 or more falls between 5 minutes and an hour, and few gaps run over an hour | Any | 1-hour duration |
| Gaps over an hour are common: about 60% or more of your pauses longer than 5 minutes also run past an hour | Any | 5-minute default |
| Only 1 or 2 gaps in 20 fall between 5 minutes and an hour, and none lasts more than about half an hour | Claude Opus 5.5 and Claude Sonnet 5.5 | 5-minute cache kept warm, instead of the 1-hour duration |
| A pause of more than 5 minutes comes before every turn, and few pauses run over an hour | Claude Opus 5.5 and Claude Sonnet 5.5 | 1-hour duration |
| Pauses run for minutes | Claude Fable 5.1 and Claude Fable 5.2 | 5-minute cache kept warm, instead of the 1-hour duration |
| Pauses run toward an hour, and few run over an hour | Claude Fable 5.1 and Claude Fable 5.2 | 1-hour duration |
On Claude Haiku 5.5, use the “Any” rows: it reads the cache at the standard 0.1x the input price, twice the 0.05x of Claude Opus 5.5 and Claude Sonnet 5.5, so by list prices each keep-alive request costs twice as much, relative to the input price, as on those two models. A max_tokens: 0 request refreshed its cache in a separate test (reference 16).
Why, row by row.
- Any model.
- Turns arrive seconds apart. No pauses: the default cost about 19% less than the 1-hour setting on Claude Sonnet 5.5, about 15% to 18% less on Claude Opus 5.5.
- About 1 gap in 20 or more. The break-even, worked out from token counts, is about 1 turn in 30 on Claude Sonnet 5.5 and Claude Opus 5.5.
- Gaps over an hour are common. On any model, a gap over an hour expires both durations, and the 1-hour setting then re-writes the prefix at its higher write price.
- Claude Opus 5.5 and Claude Sonnet 5.5, whose cache reads cost 0.05x the input price.
- Only 1 or 2 gaps in 20. At default effort, keep-alive requests cost 8% to 13% less than the 1-hour duration on Claude Opus 5.5, 8% to 16% less on Claude Sonnet 5.5.
- A pause comes before every turn. On Claude Opus 5.5 and Claude Sonnet 5.5, keep-alive requests cost a few percent more than the 1-hour duration at 6-minute pauses and over 50% more at 45-minute pauses.
- Claude Fable 5.1 and Claude Fable 5.2, whose cache reads cost 0.025x the input price.
- Pauses run for minutes. On Claude Fable 5.2, keep-alive requests19 cost about 4.5% to 19% less than the 1-hour cache, with 10% of turns paused and with a 6-minute pause before every turn.
- Pauses run toward an hour. On Claude Fable 5.2, only with a 45-minute pause before every turn did the 1-hour cache win, by about $0.12 USD19 on a session of 5 bug reports.
The following chart plots cost per session against the share of paused turns on Claude Sonnet 5.5:
The following chart adds the 5-minute cache kept warm by keep-alive requests, on Claude Fable 5.1, Claude Opus 5.5, and Claude Sonnet 5.5:
What to know.
- The 1-in-20 rule leaves a margin over the break-even of about 1 turn in 30. At 1 turn in 20 the 5-minute and the 1-hour setting cost about the same on Claude Sonnet 5.5, within run-to-run variation; at 1 turn in 10 the 5-minute setting cost 54% more (reference 16).
- On models other than Claude Sonnet 5.5 and Claude Opus 5.5, prices put the break-even in the same range: every current model uses the same cache-write multipliers, and every model but Claude Fable 5.2, Claude Mythos 5.2, Claude Fable 5.1, Claude Mythos 5.1, Claude Opus 5.5, and Claude Sonnet 5.5 the same read price.
- The Claude Opus 5.5 and Claude Sonnet 5.5 keep-alive figures come from requests sent with
max_tokens: 1. Amax_tokens: 0request also refreshed an existing cache entry on Claude Fable 5.1, Claude Opus 5.5, Claude Sonnet 5.5, and Claude Haiku 5.5 (reference 16).
To keep the cache warm:
- Take the previous request, set
max_tokensto 0, and dropstreamif it was set. Do not change a byte of the prefix. - Re-send the request’s headers with its body. Without the original request’s
anthropic-betaheader, the beta-gated fields in the replayed body are rejected. - Send it within 4 minutes of the previous request’s start, and every 4 minutes after that, until the next turn arrives or the session ends. Count from the request’s start, because the cache’s 5-minute lifetime runs from there.
That is the pre-warming request: it refreshes the cache’s lifetime, returns no output, and costs little more than the cache read. Once the cache has expired, the next request, keep-alive or not, re-writes the prefix at the cache write price16.
A max_tokens: 0 request is rejected in the following cases:
- The request sets
thinking.type: "enabled"(the default adaptive thinking on Claude Fable 5.1 and Claude Fable 5.2 is fine), structured outputs, or a forced tool choice (its limitations). On those workloads, buy the 1-hour duration instead. - The request carries the top-level
compactionparameter, so don’t re-send a compaction request from compaction on demand as a keep-alive request.
# Within 4 minutes of the last request's start (time spent generating counts
# against the cache's lifetime), re-send that request with max_tokens set to
# 0, dropping stream (a max_tokens: 0 request cannot stream). Send the same
# headers as the original request, including any anthropic-beta header.
jq '.max_tokens = 0 | del(.stream)' last_request.json | \
curl https://api.anthropic.com/v1/messages \
-H "x-api-key: $ANTHROPIC_API_KEY" \
-H "anthropic-version: 2026-10-21" \
-H "content-type: application/json" \
--data-binary @-Turn on caching
Setup takes little work. Automatic caching places breakpoints for you; otherwise, the Claude API skill that ships with Claude Code can add caching to an existing integration from one prompt:
Claude Code
Let Claude Code add caching for you
/claude-api add prompt caching to this integrationOn the code that produced these measurements, the skill put one breakpoint on the system block and one on each of the two most recent user turns; Explicit cache breakpoints explains where to place them.
What breaks the cache
Put per-request text, such as a status line, at the end of the newest user turn, after the last cache breakpoint. On later requests, leave each earlier turn as you sent it, with its old status line still in it. Make cache-invalidating changes at a natural break, such as the first request after a compaction. On models that run the prefix check, a request that edits the system prompt or tools can get a 400 error even at such a break. Send those changes in messages instead, where your platform supports it (see Change tools or instructions without failing the prefix check). The cache is a byte-exact prefix match over the request in order (tools, then system prompt, then messages), so a change anywhere invalidates everything after it.
When something must change mid-conversation, send it in the form that keeps the cache, where the model supports it. Anthropic tested each change both ways on Claude Fable 5.1, Claude Opus 5.5, and Claude Sonnet 5.5, on a cached conversation of about 100,000 tokens that held the model’s first reply with its thinking. Editing the system prompt cost about 25 to 50 times what the same text cost as a mid-conversation system message. Changing effort at the top level cost 20 to 40 times what changing it in a message cost18:
When a change invalidates the cache, the part of the prefix it affects is written again instead of read. A write to the 5-minute cache costs 1.25x the input price, and a cache read costs a small fraction of the input price. At list prices, that write costs 50 times a read on Claude Fable 5.2, Claude Mythos 5.2, Claude Fable 5.1, and Claude Mythos 5.1, where a cache read costs 0.025x the input price. That write costs 25 times a read on Claude Opus 5.5 and Claude Sonnet 5.5 (0.05x), and 12.5 times on Claude Haiku 5.5 (0.1x). The chart’s figures are from the Messages API.
In a separate Anthropic test on Claude Opus 5.5 and Claude Fable 5.2, requests that edited the system prompt or tools and sent earlier thinking blocks back still got the 400 error. They got it even as the first request after a compaction at a token threshold18.
What to do.
- Put nothing that changes per request, such as a timestamp or a queue position, ahead of the stable prefix: it turns every request into a full cache write. In Anthropic’s test, a 25-token status line at the front of the system prompt made each request write the whole conversation; moved to the end of the newest user turn, it left the cache read intact18.
- The prompt caching page lists the changes that invalidate the cache, such as a change to
effort, the thinking configuration, thespeedsetting, the system prompt, or a tool definition. Changing the output format invalidates the cache for that conversation (see structured outputs). - Check which models support each form: mid-conversation system messages, and per-message effort, which is in beta.
- After a cache-invalidating change, confirm cache reads have not dropped; if they have, cache diagnostics shows where the prefix diverged.
On an earlier model, Anthropic measured when to make such a change, on long sessions of the issue-triage agent described in Trim input and context tokens18. The sessions that made changes started at low effort, then switched to the default effort and added one tool. Making the two changes mid-session cost the most. Making them on the request that triggered the compaction cost nearly as much, because that request still carried the whole conversation and wrote it to the cache again. Making them on the next request, the first after the compaction, cost the least. Accuracy was within run-to-run noise. That model doesn’t run the prefix check. On a model that does, add the tool in a message instead: see Add, remove, or turn off tools, which is in beta. The following chart also shows sessions with no changes. They aren’t a like-for-like baseline, because they ran at the default effort throughout and two of them compacted a second time:
Trim input and context tokens
Most agent requests carry tokens that never influence the answer. Trimming them rarely costs output quality, although not every lever here saved money when measured. Two places to look:
- Input trimming.
- Dynamic filtering in the web fetch tool keeps boilerplate out of fetched pages.
- Image resizing right-sizes vision inputs.
- Tool search with deferred loading loads tool definitions only when needed (see Defer unused tool definitions).
- Programmatic tool calling lets Claude run several tool calls from code so only the filtered result enters the context; its documentation reports 24% fewer input tokens on agentic search benchmarks, with a higher score.
- Manage tool context compares tool search, programmatic tool calling, prompt caching, and context editing.
- Context lifecycle. Context editing clears stale tool results, and automatic compaction with its threshold stops long loops from carrying their whole history forward.
The levers interact with the cache and each other, so judge them by net effect, and use cache diagnostics to confirm your cached prefix survives each change.
In measurements on an earlier model28, Anthropic ran them on an issue-triage agent working through 20 real bug reports with screenshots from a public repository, and on a longer variant of the same job with 2.6 times the tokens. With caching on, input trimming (image resizing and tool search) cut the cost of both runs further.
Defer unused tool definitions
Every tool definition attached to a request is input on every turn, and a few MCP servers add up to hundreds of them.
In a measurement on an earlier model27, Anthropic ran the triage agent with its own two tools plus a catalog of real tool definitions from public MCP servers, for a total of up to 502 tools, loading all of them or marking the extras defer_loading behind tool search:
- With every definition loaded, the run cost rose as the catalog grew, tracking the schema tokens on each request.
- With tool search, the run cost stayed flat at every catalog size.
- Accuracy was in the same range either way, and the model never called a wrong tool, so at this scale unused definitions cost money, not correctness.
- Keep your 3 to 5 most used tools loaded, so Claude can call them without searching first.
- On the same earlier model, deferring a public GitHub MCP server’s toolset (
default_config: {defer_loading: true}on the MCP connector) cut the run cost at the same accuracy. With the toolset deferred and no tool search tool in the request, no run called the server’s tools.
Keep data files out of the prompt
When the model has to compute over a table, upload it with the Files API and let the model query it with code execution instead of pasting it in. Anthropic asked 25 aggregate questions15 (sums, filtered counts, group-bys, and a date filter) over a 1,862-row public CSV, with the answers computed by pandas:
Pasted into the prompt, the table is about 91,000 input tokens on every request, and Claude Sonnet 5 answered 7 of 25 questions correctly. Uploaded, with code execution, it answered all 25, and the run cost about a twelfth as much. Claude Opus 5 showed the same pattern. Neither approach used prompt caching.
Manage the context lifecycle
The context levers only pay on a session long enough to need them:
Anthropic measured these levers on an earlier model28:
- In these runs, the prune was a short function in the issue-triage agent’s own code: at each task boundary, it replaced each search result of over 2,000 characters with a one-line extract.
- On the 20-issue run the levers saved little or nothing, and context editing made the run cost more.
- On the long run the prune and compaction both cut the cost, while context editing changed nothing.
- If you use context editing, clear in a few large batches, because each clear costs a cache write.
Batch work that can wait
Route every request no one is waiting on through the Batch API, and keep the interactive path for the rest. The Batch API takes 50% off every token of a request, including cached ones, in exchange for results arriving any time within 24 hours.
- Batching is the second-largest free lever after caching for unattended agent work: evaluation runs, backfills, and scheduled jobs such as a recurring run of the issue-triage agent from the token-trimming measurement.
- Batching combines with most of this page, but not with fast mode, message threads, or Claude Managed Agents sessions (see Claude Managed Agents pricing).
Audit prompts against the current model
Audit prompts against the model you run now, and again whenever you change models: it is a free win.
- Each model generation responds to prompts differently, so a prompt accumulates text written for a model you no longer use.
- The usual case is over-specific instruction added to compensate for an older model: “verify twice,” “be maximally thorough,” a mandatory step-by-step procedure, or a hand-rolled reasoning scratchpad.
- A newer model follows such instructions to the letter, producing extra tool rounds and extra writing that you pay for with no gain in accuracy.
The audit is one command. The Claude API skill that ships with Claude Code has a prompt-audit command that reads a project’s prompts and request code and reports what was written for a different model:
Claude Code
Let Claude Code audit your prompts for you
/claude-api prompt-auditThis shortened excerpt shows the command run against a support-desk prompt and request code containing those patterns:
$ claude
> /claude-api prompt-audit
10 findings. The three that matter most:
1. budget_tokens returns a 400 on Opus 5 (support_agent.py:10). This code
does not run against its own target model. Everything else here is
quality; this one is an outage.
2. The prompt contains two live contradictions. Line 15 says confirm before
every refund, line 17 says process every eligible refund immediately.
Line 19 asks for a complete recap *and* a three-sentence maximum.
3. The reasoning scaffold and the 6-step script fight the model rather than
steer it. <scratchpad> + "reason step by step" is now a request
parameter, not prose; the mandatory 6-step procedure plus "investigate
fully even when the ticket looks simple" forces four tool calls on a
"where's my package" ticket.
...
-After any refund or escalation, verify twice before submitting: re-fetch
-the order, re-check every figure in your reply against the fresh lookup,
-and review the reply a second time for errors.
+Before submitting a refund or an escalation, re-fetch the order and confirm
+every figure in your reply matches the fresh lookup.The command then proposes its edits as a diff (one hunk shown) and lists what it deliberately left alone: the refund window, the tone requirement, and the quality bar. You review a patch, not a rewrite.
Anthropic measured the effect on a support-desk evaluation14, across two migrations between earlier models:
- From Claude Opus 4.8 to Claude Opus 5, prompts written for the older model cost more per ticket on the newer model, for no change in accuracy.
- Running the audit over the same prompts made Claude Opus 5 both cheaper than the unaudited version and more accurate, a gain outside the noise.
- From Claude Sonnet 4.6 to Claude Sonnet 5, the audit cut the cost per ticket at the same accuracy.
The two kinds of stale text have different costs:
- Instructions the new model follows too literally cost money: removing “verify twice” cut Claude Opus 5’s cost per ticket, and removing “be maximally thorough” cut it almost as much.
- Text that no longer fits the model costs accuracy instead: a retired thinking setting, contradictory rules, and a hand-rolled scratchpad that conflicts with the model’s own thinking each restored accuracy on Claude Opus 5 when removed.
The same patterns tend to appear in tool descriptions and skills, which are worth auditing too.
Trade cost against intelligence
These levers set where a single model sits between cost and intelligence: model choice, effort, re-running failures at a higher setting, the budgets and caps it works within, and whether it can see how much time has passed. If you are a model or two behind, upgrade first (Upgrade the model); otherwise, start with an effort sweep on your current model (Tune effort). From lowest to highest cost and capability, the current models are Claude Haiku 5.5, Claude Sonnet 5.5, Claude Opus 5.5, and Claude Fable 5.2 (the frontier model); Models overview has the full lineup and prices.
Compare models on cost per task
Compare models on cost per completed task, not per token, because you pay for completed tasks. For most agent workloads, start with Claude Opus 5.5 at its default effort (medium).
A more capable model can finish a task with less work, which can offset much of the per-token premium. Anthropic measured this on the SWE-bench Pro3 subset, whose scores are not comparable to the public leaderboard, priced as a customer is billed:
The following table lists the results:
| Benchmark | Model | Effort | Score | Cost |
|---|---|---|---|---|
| SWE-bench Pro3 subset | Claude Sonnet 5.5 | high (default) | 87.6% of tasks solved | $0.11 USD per solved task |
| SWE-bench Pro subset | Claude Opus 5.5 | low | 87.4% of tasks solved | $0.12 USD per solved task |
| SWE-bench Pro subset | Claude Opus 5.5 | medium (default) | 92.8% of tasks solved | $0.22 USD per solved task |
| SWE-bench Pro subset | Claude Fable 5.1 | high (default) | 92.3% of tasks solved (a single run) | $1.19 USD per solved task |
| Internal agentic-coding benchmark11 | Claude Opus 5.5 | medium (default) | 86.6% | $0.84 USD per attempt |
| Internal agentic-coding benchmark | Claude Fable 5.2 | medium | 88.9% (a single run) | $1.34 USD per attempt |
| GPQA Diamond9 | Claude Haiku 5.5 | medium (default) | 85% accuracy, compared with 91% for each of Claude Opus 5.5 and Claude Sonnet 5.5 | About a twentieth of Claude Opus 5.5’s cost per correct answer and about a tenth of Claude Sonnet 5.5’s |
| Claude Managed Agents task set25, 79 tasks | Claude Haiku 5.5 | medium | 93% of attempts passed (a single run) | About $0.011 USD per passed attempt |
On 463 of the 478 problems in the SWE-bench Pro subset, the ones whose reference solutions also pass with no network access (reference 3), Claude Fable 5.2 at high, its default on the Messages API, solved 96.3% of tasks for $1.39 USD per solved task. The same Claude Fable 5.1 run at its default, counted over these 463 problems, solved 92.4% for $1.17 USD. At low, Fable 5.2 solved 94.6% for $0.39 USD per solved task: more tasks than Fable 5.1 at its default, for about a third of the cost. At a similar pass rate, Claude Opus 5.5 still costs less per solved task on these problems: at its default it solved 93.1% for $0.22 USD, at high 95.5% for $0.30 USD, and at xhigh 96.5% for $0.75 USD, level with Fable 5.2 at high for a little over half the cost.
What to do.
- Start with Claude Opus 5.5 at its default effort: on the SWE-bench Pro subset it matched Claude Fable 5.1 at its default, inside run-to-run noise, for about a fifth of the cost per solved task. Opus 5.5 and Fable 5.1 both largely saturate the SWE-bench Pro subset. Use Claude Fable 5.2 for demanding reasoning and long-horizon agentic work, or when your evals on Claude Opus 5.5 at higher effort still fall short.
- At the other end, Claude Haiku 5.5 suits high-volume and latency-sensitive work with checkable outputs.
- Price every candidate in cost per completed task on your own traffic, including Claude Opus 5.5 at its default effort and the frontier model at reduced effort. Each of Claude Opus 5.5’s token prices, cache reads included, is twice Claude Sonnet 5.5’s, but on the SWE-bench Pro subset Opus 5.5 at
lowsolved about the same share of tasks as Sonnet 5.5 at its default, inside run-to-run noise, for about 7% more per solved task. - Measure what a more expensive model buys on your own workload. On the 44 DeepResearch Bench II7 tasks scored for every model, at default effort on the Messages API, Claude Opus 5.5 scored 2.4 points above Claude Sonnet 5.5 for 1.5 times the cost per task. Claude Fable 5.2 cost 4.3 times as much as Claude Sonnet 5.5 for no measurable gain in score, and 2.9 times as much as Claude Opus 5.5 for a score 1.9 points lower. Against Claude Fable 5.1, it cost 20% to 61% less at each effort level and scored 4.7 to 7.0 points lower. On all 50 tasks, Claude Opus 5.5 is not measurably ahead of Claude Sonnet 5.5: safeguards nearly always stopped it on four biology tasks that Claude Sonnet 5.5 answered, and a stopped attempt counts as a failure.
- Price the tail of your workload, not the median: compare models on the hardest tenth of your tasks, not the typical one.
The bill is decided by the tasks the cheaper model fails, because a failed task still bills its tokens, then the retry, then whatever the failure costs downstream. The tail is also where the money goes even when nothing fails. On a 20-problem WideSearch1 run, two problems carried 43% of the spend:
The multimodel strategies exist to spend frontier intelligence on that tail without paying frontier rates for the rest.
Upgrade the model
If you are a model or two behind, the cheapest lever is the model string. On the coding benchmarks in this section and in Compare models, each newer model solved at least as many tasks as the one before it; most cost less per solved task, and Claude Fable 5.2, at high, cost more than Claude Fable 5.1. On a research benchmark, Claude Fable 5.2 did the reverse: it cost less per task than Claude Fable 5.1 at each effort level and scored lower (Compare models). The chart plots recent Claude models on two benchmarks in which an agent works alone on one written task and tests check the result: the SWE-bench Pro3 subset, where every model ran through the same test setup, and Terminal-Bench 320. The table lists what each upgrade changed:
| Benchmark | Upgrade | Effort | Score | Cost |
|---|---|---|---|---|
| SWE-bench Pro3 subset | Claude Sonnet 4.6 to Claude Sonnet 5 | Default | 5 more points | 16% less per solved task |
| SWE-bench Pro subset | Claude Sonnet 5 to Claude Sonnet 5.5 | Default | About 10 more points | 87% less per solved task; 85% less at Claude Sonnet 5’s prices |
| SWE-bench Pro subset | Claude Opus 5 to Claude Opus 5.5 | Default: high to medium | About the same: 91.9% to 92.8% of tasks solved | 78% less per solved task; about 69% less at Claude Opus 5’s prices |
| SWE-bench Pro subset | Claude Fable 5 to Claude Fable 5.1 | Default | About the same score | 43% less per solved task |
| Terminal-Bench 320 | Claude Opus 4.7 to Claude Opus 4.8 | high | From 7% to 15% of tasks solved | From $183 USD to $63 USD per solved task |
| Terminal-Bench 3 | Claude Opus 4.8 to Claude Opus 5 | high | From 15% to 41% of tasks solved | From $63 USD to $28 USD per solved task, a 56% saving |
| Claude Managed Agents task set25 | Claude Haiku 4.5 to Claude Haiku 5.5 | As served; medium on Claude Haiku 5.5 | From 62% to 93% of attempts passed, one run per model | From $0.041 USD to about $0.010 USD in token cost per attempt; about 84% less per passed attempt |
When it pays.
- The size of the saving depends on the work. From Claude Opus 5 to Claude Opus 5.5, it is 78% per solved task on the SWE-bench Pro subset and 40% on typical workloads (Introducing Claude Opus 5.5). From Claude Sonnet 5 to Claude Sonnet 5.5, it is 87% on the same subset and up to 30% for most work (Introducing Claude Sonnet 5.5).
- Where older models already solve most tasks, the cost of each attempt decides the saving: on the SWE-bench Pro subset, Claude Opus 5.5 scores about the same as Claude Opus 5 for 78% less per solved task.
- Where older models mostly fail, the pass rate decides the saving: on Terminal-Bench 320, the upgrade from Claude Opus 4.8 to Claude Opus 5 raises tasks solved from 15% to 41% and costs 56% less per solved task.
- Compare on cost per solved task, not per token: the same text costs about 30% more tokens on Claude 4.7 and later models, so a per-token comparison makes the newer models look more expensive by construction.
Tune effort
Sweep effort on your own workload before you add a second model. Lower effort costs less and is often faster, and how much accuracy it gives up depends on the task: on long-horizon coding, effort bought accuracy, and on research tasks it bought a lot in one measurement and a little in another. The effort parameter governs how much thinking, tool calling, and self-verification the model does; on the Messages API, high is the default on most models, and medium on Claude Opus 5.5 and Claude Haiku 5.5.
The following table lists Anthropic’s measurements on two benchmarks with current models; scores and costs are not comparable between the two benchmarks. Costs are per task, not per solved task as in Compare models on cost per task. Each score pools two runs on SWE-bench Pro and three on DeepResearch Bench II, unless its cell says otherwise:
| Benchmark | Model | Effort | Score | Cost per task |
|---|---|---|---|---|
| SWE-bench Pro3 subset | Claude Opus 5.5 | low | 87.4% of tasks solved | $0.11 USD |
| SWE-bench Pro subset | Claude Opus 5.5 | medium (default) | 92.8% of tasks solved | $0.21 USD |
| SWE-bench Pro subset | Claude Opus 5.5 | high | 95.3% of tasks solved | $0.29 USD |
| SWE-bench Pro subset | Claude Opus 5.5 | xhigh | 96.7% of tasks solved (a single run) | $0.74 USD |
| DeepResearch Bench II7 | Claude Fable 5.2 | low | Rubric score 54.5% | $1.49 USD |
| DeepResearch Bench II | Claude Fable 5.2 | medium | Rubric score 55.0% | $2.16 USD |
| DeepResearch Bench II | Claude Fable 5.2 | high (default on the Messages API) | Rubric score 57.7% | $4.82 USD |
The following chart plots accuracy against cost per task for Claude Opus 5.5 on the SWE-bench Pro3 subset:
The following chart plots rubric score against cost per task for Claude Fable 5.1 on DeepResearch Bench II7:
What to do.
- Sweep two or three effort levels on a sample of your own traffic, each in a separate session: changing top-level effort mid-session invalidates the cache and distorts the comparison. The curve is the baseline any multimodel strategy must beat (step 2 of measuring on your own workload).
- On long-horizon coding, effort is a real tradeoff, which re-running failures at higher effort turns back into a saving. At
medium, Claude Sonnet 5.5 scored about 7 points lower than at its default,high, on the SWE-bench Pro3 subset for about 59% of the cost per task (2 runs each), and scored 62.7% compared with 77.8% on the internal agentic-coding benchmark11 (1 attempt per task). - At
xhighandmax, Claude Sonnet 5.5 can start its own rounds of review after it finishes a task, which takes more time and tokens. To keep that work on the task, add the prompt under “Thoroughness atxhighandmaxeffort” in Prompting Claude Sonnet 5.5 to your system prompt. - On research tasks, measure the model you ship. Claude Fable 5.2 scored 3.3 points higher at
highthan atlowon DeepResearch Bench II, for 3.2 times the cost, and not measurably higher atmediumthan atlow; Claude Opus 5.5 scored 13.3 points lower atlowthan atmediumon DRACO21. The two results come from different models on different benchmarks, so they show that the answer varies, not why. - At
low, Claude Opus 5.5’s typical task took 84% less time than atmediumon DRACO21, 30% less on HLE22, and 47% less on an internal set of physics problems23, and it scored 13.3, 3.4, and 14.0 points lower (3, 3, and 4 attempts per task). - On an internal defect-search benchmark8 (10 runs per setting), Claude Opus 5.5 scored 34 points lower at
lowthan atmedium, for about a fifth of the cost. Claude Fable 5.2 scored 4.3 points lower atlowthan athigh, for 37% less.
Re-run failures at higher effort
When a task’s outcome is checkable, the cheapest policy on the effort curve is not a fixed setting: run every task at a low setting and re-run only the failures at a higher one.
Anthropic computed this policy task by task from the Claude Opus 5.5 effort runs on the SWE-bench Pro3 subset in Tune effort:
In the following table, the re-run costs count the failed cheap attempts:
| Policy | Tasks solved | Cost per task |
|---|---|---|
low, failures re-run at high | About 97% | About $0.17 USD |
medium, failures re-run at high | About 97% | About $0.24 USD |
Everything at high | 95.3% | $0.29 USD |
- At
low, 13% of tasks failed. With those re-run athigh, the pass rate was slightly higher than with everything athigh, for a little over half the cost. - Use this policy for the saving, not the lift. Most of the small lift is the second attempt: re-running the failures of one
highrun athighscores about the same, for more money.
Two conditions apply. First, you need a failure signal (here, the benchmark’s own tests); a checker that passes bad work lets those failures through. Second, every first-pass failure takes two runs’ worth of wall-clock time, so the saving is paid for in latency on the failures.
Set budgets and output caps
Two controls do two different jobs: a session budget caps what one Claude Managed Agents session can spend, and max_tokens caps the length of one response. Set each where it applies, with a workspace spend limit as the final backstop.
- Session budgets on Claude Managed Agents are a hard stop on spend. A session budget is a dollar cap on one session’s list cost, which the platform meters for tokens, web searches, and session running time.
- At the cap, or a fraction past it, the session pauses with
stop_reason: budget_reached; raising the budget resumes it. It is platform-enforced and works on any model with a list price. Deployments apply the same budget to each session they start. max_tokenscaps a single response, invisibly to the model, so lowering it does not make the model economize. The turns that needed the room are discarded and still billed. Retrying capped attempts rarely helps: at the same cap most of them fail again, and at a higher one you also pay for the wasted attempt.- Set
max_tokensto 64,000 for agentic work, or to 128,000, the maximum, when a single cut-off attempt is costly. Stream responses that large, treatstop_reason: max_tokensas a failure, and save money with effort, which the model can see. - On Claude Haiku 5.5, raise a small
max_tokensor lower effort: thinking is on by default and counts toward the cap, so a response can end before any text (see the Claude Haiku 5.5 migration guide).
The following table shows what each model solved and what a solved task cost at each cap on an internal repository-task benchmark12, one attempt per task, each model at its default effort on the Messages API. The rows at 16,384 average two runs, and the other rows are one run each:
| Model | max_tokens | Attempts ended by the cap | Tasks solved | Cost per solved task |
|---|---|---|---|---|
| Claude Opus 5.5 | 16,384 | 25% | 57.6% | $5.38 USD at list prices |
| Claude Opus 5.5 | 64,000 | 0% | 75.6% | $5.38 USD at list prices |
| Claude Opus 5.5 | 128,000 | 0% | 68.9% | $5.94 USD at list prices |
| Claude Fable 5.2 | 16,384 | 85% | 20.3% | $27.96 USD at list prices |
| Claude Fable 5.2 | 64,000 | 2% | 77.4% | $24.42 USD at list prices |
| Claude Fable 5.2 | 128,000 | 0% | 78.2% | $24.52 USD at list prices |
Claude Opus 5.5 at 64,000 and 128,000: No attempt was cut off at either cap, so the cap does not explain why these two rows differ in tasks solved or in cost per solved task. Each row is one run.
Compare the caps within each model. The two models were measured in separate runs.
On the internal repository tasks12, almost every turn finishes far below a 16,384-token cap, but one longer turn ends the whole attempt: with a higher cap, 1.7% of Claude Fable 5.2’s turns passed 16,384 tokens, and at 16,384 the cap ended 85% of its attempts. The rare long turn is what a higher cap buys (Claude Opus 5.5 and Claude Fable 5.1 are the two models in this chart):
Ask for shorter answers. Output tokens cost five times input tokens on Claude Haiku 5.5, Claude Sonnet 5.5, Claude Opus 5.5, Claude Fable 5.2, and Claude Fable 5.1, and in an agent loop every token the model writes comes back as input on every later turn, so you pay for a long answer again and again.
In a measurement on an earlier model26, Anthropic ran a small agent that triages bug reports (Trim input and context tokens) under three final-answer instructions, three runs each, with the same model and tools:
- The original asked for two lines.
- The shorter variant asked for one.
- The longer variant asked for a memo with six headed sections.
The following chart plots the cost per run of each format:
All three scored within run-to-run noise of each other against the correct labels, so the formats differ in what you pay far more than in what they get right. Ask for the answer you will read, not the one that looks thorough.
Show the model elapsed time
To make an agent finish sooner and cost less, tell it that time matters, and show it the elapsed time on every request. In Anthropic’s measurement, the two changes cut the time of a single Claude Opus 5.5 agent at medium effort by 47% and its cost by 60% on the typical (median) DRACO21 research task, and its average score was 4.1 points lower.
On HLE22 and an internal physics set23, the typical task took 14% and 7% less time, and the physics score was 3.0 points lower. Lowering effort to low saved more time and cost than the changes did, and lost more score (reference 21). Check the score on your own tasks before you adopt the changes.
Reference 21 gives the exact text used for both changes in the measured runs. For working code, see the Claude Cookbook recipe Multi-agent teams under latency pressure and budgets, which applies both changes to a team of agents. To use the system prompt instead of the first user message to say that time matters, see Time signals for multiagent harnesses.
The following chart also plots a team, whose lead agent rarely started helpers, and a single agent at low effort:
To pay for speed instead, set speed: "fast" on Claude Fable 5.2 or Claude Opus 5.5. Fast mode gives up to 2.5x higher output tokens per second at twice the standard token prices. Switching speed mid-conversation misses the prompt cache.
Combine models
Tune one model before you add a second: sweep effort on your current model first, because most workloads end there, and if the sweep shows a gap, price the stronger model alone at low effort. Build a pairing only if it beats the single model’s whole curve of score against spend. On your own workload, judge a pairing against the same model at lower effort and against the next model down running alone.
The following table compares the two strategies:
| Strategy | Control flow | Frontier model’s role | Fits | Frontier cost scales with |
|---|---|---|---|---|
| Advisor | Smaller model runs the loop, escalates on demand | Consulted for plans and corrections | Serial work that is hard in spots, such as a coding agent’s many turns between a few real decisions | How of |