Building with Claude Sonnet 5.5: Migration, Tuning, and Pricing

Claude Sonnet 5.5 is the second model in Anthropic‘s Claude 5.5 family after Opus 5.5, described as a clear upgrade over Sonnet 5: smarter, more efficient, and 30% faster, with per-token pricing unchanged. Because it typically uses far fewer tokens for the same work, most tasks cost up to 30% less. It ships as claude-sonnet-5-5 on the Claude API, Claude Platform on AWS, Google Cloud, and Microsoft Foundry, and anthropic.claude-sonnet-5-5 on Amazon Bedrock. Thinking is on by default, so responses can begin with a thinking block; the example loop reads response.content and dispatches on block.type instead of assuming text at index 0.

Anthropic positions Sonnet 5.5 for well-scoped everyday tasks—fixing bugs, iterating on features, producing polished documents and spreadsheets, and repeated agent tasks like investigation, review, and drafting. Opus 5.5 remains the recommendation for complex work requiring careful judgment, including long-horizon agentic coding and knowledge work, and Haiku 5.5 is coming for high-volume, low-latency workflows. Epic Games COO Daniel Vogel reports Sonnet 5.5 cleared the quality bar of a higher-tier model in early testing: it held up on a system design audit and data-flow review, managed tens of thousands of lines of code and multi-hour tasks, and needed less prescriptive prompting. The stated rule: Sonnet 5.5 fits when the task has a clear spec and a way to check the result; for the hardest long-horizon work, choose Opus.

Per-million-token pricing is $2 input, $10 output, $2.50 cache write (5 min), $4 cache write (1 hour), and $0.20 cache read—identical to Sonnet 5 across batch and prompt caching, so swapping the model ID alone doesn’t change the per-token bill; US-only inference costs 1.1x. The context window is 1M tokens native, max output is 128k tokens (300k on the Message Batches API with the output-300k-2026-03-24 beta header), and the knowledge cutoff is June 2026. Thinking uses adaptive mode by default with effort levels low through max; the Claude API defaults to high, Claude Code to medium. The high-resolution image tier accepts up to 2576 pixels on the long edge, with a 2000×1500 image costing about 2.5x the tokens of Sonnet 4.6/4.5 or Haiku 4.5. The minimum cacheable prompt drops to 512 tokens.

Migration from Sonnet 5 starts with the model ID swap, then six changes. thinking: {“type”: “disabled”} returns 400; use between_tools to turn off upfront thinking. between_tools works only at low/medium/high effort (400 at xhigh/max), accepts no display, budget_tokens, or block_binding fields, and can’t change effort mid-conversation; progress notes still return as thinking blocks with summary text and must be passed back unchanged. Forced tool_choice (any or tool) returns 400; send auto with strict: true tools, additionalProperties: false on every object, and prompt-level instructions on when to use the tool. Conversations are append-only: Sonnet 5.5 reads Sonnet 5’s thinking blocks, but no other model reads Sonnet 5.5’s. Computer use is only available through {“type”: “computer_toolset_20260801”}; requests declaring computer_20251124 return 400, the computer-use beta header must be dropped, and Amazon Bedrock still accepts computer_20251124. Advisor pairing rejects Opus 4.8, Opus 4.7, and Sonnet 5 as advisors; accepted advisors are Opus 5.5, Opus 5, and Sonnet 5.5, with advice encrypted as advisor_redacted_result blocks. Progress text between tool calls arrives in thinking blocks that are empty at the default display; use thinking.display “updates” (beta) or “summarized”. Claude Code users can run /claude-api migrate this project to claude-sonnet-5-5 to apply the changes automatically.

Effort levels are recalibrated, so old settings won’t carry over; re-run your effort sweep. Start at high unless the workload is agentic or latency-sensitive: medium for well-specified agentic coding and multistep tool use, low/medium for chat, and xhigh/max only where evals show a quality gain. Thinking counts toward max_tokens, so leave room—for agentic coding, set max_tokens to 128,000 and stream. Existing Sonnet 5 prompts should perform well, but remove workarounds such as refusal steering, tool-call retry shims, and “do not be lazy” before tuning anything else. At low effort the model sometimes reports changes done without running a real check; the prompting guide provides a system-prompt paragraph requiring an actual test, build, or type-check before reporting completion. Ask for summarized thinking rather than having the model write out its reasoning, which invites reasoning_extraction declines. Changing top-level effort invalidates the cache; per-message effort (beta) varies effort while keeping the cache.

Sonnet 5.5 improves on or matches Sonnet 5 on most alignment and honesty measures in Anthropic‘s automated audit and is the first Sonnet model with cybersecurity safeguards similar to those on its most capable models. Declines return HTTP 200 with stop_reason “refusal” and stop_details naming one of five categories: cyber, bio, frontier_llm, reasoning_extraction, or general_harms. Server-side fallback retries only cyber and frontier_llm declines on Sonnet 5. The model is available today on the Claude API, Amazon Bedrock, Claude Platform on AWS, Google Cloud, and Microsoft Foundry (Global Standard only). In Claude Code v2.1.284+ (Agent SDK for TypeScript v0.3.284+), the sonnet alias resolves to Sonnet 5.5 at medium effort with the 1M context window; thinking can’t be turned off, there’s no fast mode, and the default model remains Opus 5.5.

Building with Claude Sonnet 5.5

View Original