1. Home
  2. Blog
  3. AI

AI

Claude Sonnet 5.5 Migration Guide: Pricing, Speed and API Changes

Moving to Claude Sonnet 5.5? Here is what costs the same, what got cheaper and the five API changes that can break working code.

8 min read
Claude Sonnet 5.5 migration guide: pricing, speed and API changes

Key takeaways

  • Claude Sonnet 5.5 keeps Sonnet 5 prices ($2 input, $10 output per million tokens) but halves cache reads to $0.10.
  • Five changes can return errors on old code: thinking: disabled, forced tool use, the old computer-use tool, some advisor pairings and thinking-block reuse.
  • Adaptive thinking is now on by default, so read content blocks by type and raise max_tokens.
  • Do a staged rollout: swap the model ID, fix the 400 errors, then re-run your own evals and cost checks.

Claude Sonnet 5.5 is Anthropic’s mid-tier model, released on September 28, 2026 as the second model of the 5.5 family. It costs the same as Sonnet 5 on input and output, yet a few request settings that worked yesterday now return a 400 error.

That is the real story for developers. The headline numbers are easy to read off a pricing page. The breaking changes are not, and they usually show up in production logs on a Friday evening.

This guide covers the price, speed and context facts for Claude Sonnet 5.5, then walks through every migration change from the official docs with before-and-after code and a checklist you can paste into a ticket. All facts below come from Anthropic’s platform documentation as checked on October 31, 2026.

Claude Sonnet 5.5 at a glance

Item Value
API model ID claude-sonnet-5-5
Released September 28, 2026
Context window 1M tokens
Max output 128K tokens (300K on the Batch API with a beta header)
Input / output price $2 / $10 per million tokens
Cache read $0.10 per million tokens
Cache write $2.50 (5 minute) and $4 (1 hour) per million tokens
Batch API 50% discount on input and output
Thinking Adaptive, on by default, default effort high
Latency tier Fast
Knowledge cutoff June 2026

It is available on the Claude API, Amazon Bedrock (as anthropic.claude-sonnet-5-5), Google Cloud, Microsoft Foundry and Claude Platform on AWS. Anthropic lists retirement as not sooner than September 28, 2027.

Claude Sonnet 5.5 pricing and speed compared

The prices did not move, except for one line. Prompt cache reads cost $0.10 per million tokens, which is half of what Sonnet 5 charged. If your app re-sends a long system prompt or a large document on every call, that line is where you will see savings.

Model Price per MTok (in / out) Latency Default effort
Claude Fable 5.1 $10 / $50 Slower high
Claude Opus 5.5 $4 / $20 Moderate medium
Claude Sonnet 5.5 $2 / $10 Fast high
Claude Haiku 5.5 from $0.10 / $0.50 Fastest medium

Speed is a tier, not a number: the docs label Sonnet 5.5 “Fast”, Haiku “Fastest” and Opus “Moderate”. Real latency depends on your effort setting, prompt length and output size, so measure it on your own traffic. For a side-by-side with the larger model, read our Claude Opus 5.5 vs Sonnet 5.5 comparison, and for the cheapest tier see Claude Haiku 5.5 explained.

Watch the bill: thinking tokens are billed as output tokens. Because thinking now runs by default, the same prompt can cost more than it did on Sonnet 4.6 even though the price per token is unchanged.

The five breaking changes

These are the changes Anthropic lists for code that already runs on Sonnet 5. Each one is a 400 error or a silent behaviour change, so fix them before you flip traffic.

1. thinking: disabled is rejected

On Claude Sonnet 5.5, thinking: {"type": "disabled"} returns a 400 invalid_request_error. The lowest setting is between_tools, which turns off up-front thinking. It works at low, medium and high effort and returns an error at xhigh or max.

# Before (Claude Sonnet 5)
client.messages.create(
    model="claude-sonnet-5",
    max_tokens=16000,
    thinking={"type": "disabled"},
    messages=[{"role": "user", "content": "..."}],
)

# After (Claude Sonnet 5.5)
client.messages.create(
    model="claude-sonnet-5-5",
    max_tokens=16000,
    thinking={"type": "between_tools"},
    output_config={"effort": "high"},
    messages=[{"role": "user", "content": "..."}],
)

With between_tools, you cannot change effort mid-conversation, and you cannot send display, budget_tokens or block_binding with it. Manual thinking budgets (enabled with budget_tokens) also return 400.

2. Forced tool use returns an error

Setting tool_choice to {"type": "any"} or {"type": "tool", "name": "..."} fails. Only auto and none work. If you relied on forcing a tool to get structured data, keep tool_choice on auto, add strict: true to the tool, or move the schema to structured outputs. To make the model call a tool, say in the prompt when it applies.

3. Thinking blocks are tied to a model and a conversation

Each thinking block records which model made it. Sonnet 5.5 reads blocks from Sonnet 5, Opus 4.8, Haiku 4.5 and earlier models, but not from Opus 5, Opus 5.5 or the Fable and Mythos models. Unreadable blocks are dropped before the model sees them, and dropped blocks are not billed.

The API also checks that nothing before a thinking block changed since it was produced. Keep conversations append-only: change instructions with mid-conversation system messages rather than by editing earlier turns. On accounts created on or after August 31, 2026, replaying a block after such an edit returns a 400 unless you set a fallback behaviour.

4. The old computer-use tool is not accepted

On the Claude API and Google Cloud (Google managed), a request that declares computer_20251124 returns a 400. Use the computer_toolset_20260801 toolset instead. Amazon Bedrock still accepts the older tool for this model.

5. The advisor tool rejects four advisors

If you pair Sonnet 5.5 with the advisor tool, Claude Opus 4.8, Claude Opus 4.7, Claude Sonnet 5 and Claude Haiku 5.5 are rejected as advisors.

The silent change: text between tool calls

Short progress notes the model writes between tool calls now arrive inside thinking blocks. An app that streams that text to users will go quiet between calls until you set a display value that returns it, or switch to between_tools. This does not fail a request, which makes it easy to miss in testing.

How to upgrade from Sonnet 5 step by step

  1. Change the model ID to claude-sonnet-5-5 in a staging config, not in code.
  2. Search for "disabled", tool_choice, temperature, top_p and top_k. Setting a sampling parameter returns 400 on this model.
  3. Read response content by block type. A reply can start with a thinking block, so code that reads content[0].text breaks.
  4. Pass thinking blocks back unchanged in tool loops, including empty ones.
  5. Raise max_tokens, because it covers thinking plus text.
  6. Send 5 percent of traffic and compare errors, latency and cost per task.
  7. Re-run your effort sweep, since the best effort level may have shifted.

Coming from Sonnet 4.6 or earlier is a bigger jump. Thinking was off by default there, so also replace thinking budgets with an effort level, drop sampling parameters and set display: "summarized" if you show reasoning text. Models before 4.5 also need assistant prefills replaced. The official migration guide lists every group by starting model. If you want help, the docs even mention a Claude Code command, /claude-api migrate this project to claude-sonnet-5-5, that does the first pass for you.

What to test before you ship

Area Test Pass condition
Errors Replay 100 real prompts No 400 responses
Parsing Responses that start with thinking blocks Text still extracted
Tools Flows that used forced tool choice Same tool called with auto
Streaming UI Long multi-tool task Progress text still visible
Cost Cost per completed task Within your budget

The same habits that keep agents reliable apply here; our AI agents best practices post covers evals and monitoring, and the MCP stateless architecture guide matters if your tools run over MCP.

Who should move first

  • Heavy prompt-cache users: half-price cache reads pay off quickly.
  • Agent and coding workloads: Anthropic positions Sonnet 5.5 for agentic work, but verify on your own tasks.
  • Apps with strict output formats: test the forced-tool change first.
  • Small teams with simple chat features: a quick model-ID swap plus the thinking fix is usually enough.

Benchmark tables from third-party sites differ from each other, so treat them as a starting point and run a small eval on your own prompts. Official details live in the Sonnet 5.5 migration guide, the pricing page and the effort documentation.

Final thoughts

Claude Sonnet 5.5 is a cheap upgrade in price terms and a careful one in code terms. Swap the model ID in staging, fix the 400 errors from thinking and tool settings, then judge it by cost per finished task rather than price per token. Keep the migration checklist above in your pull request and the rollout stays boring, which is what you want.

Frequently asked questions

What is the Claude Sonnet 5.5 API model ID?

The Claude API model ID is claude-sonnet-5-5. On Amazon Bedrock it is anthropic.claude-sonnet-5-5.

How much does Claude Sonnet 5.5 cost?

Input costs $2 and output costs $10 per million tokens. Cache reads cost $0.10 per million tokens, and the Batch API gives a 50% discount on input and output.

Why does thinking disabled fail on Claude Sonnet 5.5?

The model no longer accepts it. Send thinking: {"type": "between_tools"} at low, medium or high effort, or use adaptive thinking.

Can I still force a tool call?

No. tool_choice of type any or tool returns a 400. Use auto with strict tool schemas or structured outputs, and say in the prompt when the tool applies.

How big is the context window?

The context window is 1M tokens with up to 128K output tokens. The Batch API supports up to 300K output tokens with a beta header.

Keep learning

Work with Stack Quora

Need help with testing, WordPress or SEO?

We help teams ship better software and grow their sites. Tell us what you are working on and we will suggest a clear next step.

Keep reading

More guides on testing, AI & modern development

Enjoyed this article? Pick a topic and jump straight into our newest tutorials.

Artificial Intelligence

Jaccard Similarity: Formula, Python, MinHash

Jaccard similarity measures overlap between two sets as intersection over union. Work the formula, compute it in Python for words…

Read article →
Software Development

Unix Timestamp Explained: Seconds vs ms

A Unix timestamp counts seconds since 1 January 1970 UTC. Learn seconds vs milliseconds, converting in Python, JavaScript and SQL,…

Read article →
DevOps

Git Hooks: Pre-commit and Commit-msg Examples

Git hooks run scripts at key moments such as commit and push. See tested pre-commit, commit-msg and prepare-commit-msg hooks, sharing…

Read article →
Test Automation

API Testing in Python: Pytest + Requests Suite

Build an API testing suite in Python with pytest and requests: fixtures, status codes, headers, JSON schema validation, CRUD flows,…

Read article →
Software Testing

Test Design Techniques: 9 Methods + Examples

Test design techniques help you write fewer tests that catch more bugs. Learn 9 black-box, white-box and experience-based methods with…

Read article →
Databases & SQL

SQL Temporary Table: Create, Use and Drop It

SQL temporary tables store interim results for one session. Learn syntax for SQL Server, PostgreSQL, MySQL, Oracle and SQLite, session…

Read article →
Databases & SQL

SQL CROSS JOIN: Every Combination + Examples

SQL CROSS JOIN returns every combination of rows from two tables. See the row math, product variants, calendar grids that…

Read article →
Software Development

JavaScript Date: Format, Parse, Timezone Bugs

JavaScript Date explained with tested Node.js code: zero-based months, the date-only UTC parsing trap, toISOString, getTimezoneOffset, Intl formatting, date math…

Read article →
Software Development

Python Requests: GET, POST, Timeouts, Retries

Python requests explained with code tested against a local API: GET with params, POST json vs data, headers and auth,…

Read article →
Software Development

Python Deepcopy vs Copy: Fix Nested Lists

Python deepcopy vs shallow copy explained with tested code: aliasing, nested lists, the [[0]*3]*3 trap, memo and cycles, custom __deepcopy__,…

Read article →
Artificial Intelligence

TF-IDF Explained: Formula and Worked Example

TF-IDF scores a word by how often it appears in a document and how rare it is across all documents….

Read article →
Software Development

Base64 Encoding Explained, With Python Code

Base64 encoding turns bytes into 64 safe text characters. See the bit-level steps, padding, URL-safe base64, the 33% size cost,…

Read article →
DevOps

Git Tag: Create, Push and Delete Release Tags

Git tag explained with tested commands: annotated vs lightweight tags, listing and sorting, pushing with follow-tags, deleting local and remote…

Read article →
Test Automation

Pytest Coverage: pytest-cov and Branch Gaps

Measure pytest coverage with pytest-cov: term-missing reports, branch coverage, HTML reports, pyproject settings and a fail-under gate for CI, with…

Read article →
Software Testing

Error Guessing in Testing: Checklist + Demo

Error guessing uses tester experience to predict where code breaks. Get a ready checklist of risky inputs, a step by…

Read article →
Databases & SQL

SQL LAG and LEAD: Compare Rows, 5 Examples

SQL LAG and LEAD read values from the previous or next row without a self join. Five tested examples: change,…

Read article →
Databases & SQL

SQL STRING_AGG: Combine Rows Into One String

SQL STRING_AGG joins values from many rows into one string per group. See syntax for PostgreSQL, SQL Server, MySQL GROUP_CONCAT,…

Read article →
Software Development

JavaScript Classes: Private Fields and Extends

JavaScript classes explained with tested Node.js code: constructors, methods, #private fields, getters, static members, extends and super, plus the errors…

Read article →
Artificial Intelligence

BM25 Explained: How Keyword Search Ranks Results, With Python Code and Hybrid Search

BM25 explained with a pure Python implementation we ran: the formula, IDF, term saturation, the k1 and b parameters, why…

Read article →
DevOps

Git Bisect Explained: Find the Commit That Broke Your Code, Manually or Automatically

Git bisect explained with a tested repository: find the one bad commit among 41 in 5 test runs, automate it…

Read article →
Test Automation

pytest Markers Explained: Custom Marks, skip, skipif, xfail and -m Filters

pytest markers explained with a tested suite: register custom marks, run only smoke tests with -m, combine filters with and,…

Read article →
Software Testing

Positive vs Negative Testing: Differences, 24 Real Test Cases and a Checklist

Positive vs negative testing explained with a real signup form: 6 positive and 18 negative test cases run in pytest,…

Read article →
Databases & SQL

SQL ORDER BY Multiple Columns: ASC, DESC, NULLS LAST, Case and Custom Order

SQL ORDER BY with multiple columns explained with tested queries: mixed ASC and DESC, tie-breakers, NULLS FIRST and LAST, case-insensitive…

Read article →
Databases & SQL

SQL Running Total: SUM OVER, Per-Group Totals, Moving Sums and the RANGE Trap

How to calculate a SQL running total with SUM() OVER: per-group totals, daily cumulative sums, moving sums, percent of total,…

Read article →
Artificial Intelligence

Cosine Similarity Explained: Formula, Worked Example and Python Code

Cosine similarity explained simply: the formula, a worked example by hand, pure Python and NumPy code, cosine vs Euclidean distance…

Read article →
DevOps

Git Squash Commits: 4 Easy Ways, Tested Step by Step (rebase -i, reset, merge)

Git squash commits explained with 4 tested methods: interactive rebase, reset –soft, merge –squash and fixup with autosquash. Before-and-after logs,…

Read article →
Test Automation

pytest parametrize Explained: 7 Patterns with Tested Examples

pytest parametrize explained with 7 tested patterns: basic cases, readable ids, stacked decorators, pytest.param with xfail and skip, indirect fixtures…

Read article →
Software Testing

Retesting vs Regression Testing: 8 Key Differences with a Real Bug Fix Example

Retesting vs regression testing explained with a real bug fix run in pytest: retesting confirmed the fix, the regression run…

Read article →
Artificial Intelligence

RAG Chunking Strategies Explained: Fixed, Overlap, Sentence, Recursive and Headings, Measured

RAG chunking strategies compared on one document with tiktoken 0.14: fixed-size, overlap, sentence packing, recursive splitting and heading-based chunks, measuring…

Read article →
DevOps

Git Stash Explained: Save, Apply, Pop and Untracked Files, Tested

Git stash explained with commands we ran on Git 2.56: push with a message, untracked files, list and show, apply…

Read article →
Software Testing

Pairwise Testing Explained: How All-Pairs Cuts 216 Tests to 13, Tested

Pairwise testing explained with a generator we ran in Python 3.13: a checkout with 216 combinations covered by 13 tests,…

Read article →
Test Automation

Test Doubles Explained: Dummy, Stub, Spy, Mock and Fake, with Tested Python Code

Test doubles explained with one Python example run in pytest 9.2: dummy, stub, spy, mock and fake, when to use…

Read article →
Artificial Intelligence

LLM Context Window Explained: Tokens, Limits and How to Fit More, Measured

The LLM context window explained with token counts we measured using tiktoken: words vs tokens for prose, code and Hindi,…

Read article →
DevOps

Git Cherry-Pick Explained: Copy the Commit You Need, Safely, Tested

Git cherry-pick explained with commands we ran in Git 2.56: copying a hotfix to a release branch, new hashes and…

Read article →
Test Automation

Snapshot Testing Explained: How It Works, When It Helps and When It Hurts

Snapshot testing explained with a pytest and syrupy demo we ran: creating snapshots, reading the diff after a code change,…

Read article →
Software Testing

Mutation Testing Explained: Why 100% Coverage Still Missed Our Bug

Mutation testing explained with a small mutation tool we built and ran: 14 mutants, a test suite with 100% line…

Read article →