Migrate to the MCP 2026-07-28 Spec: What Broke After Launch
Nikhil Tiwari
MCP Playground
TL;DR — updated November 2026, four months after launch
- It shipped. The 2026-07-28 spec went final on July 28. TypeScript, Python, Go and C# SDKs had support on launch day.
- Sessions are gone. No
initialize, noMcp-Session-Id. The protocol version rides in_metaon every request. - New MUSTs:
server/discover, plusMcp-MethodandMcp-Nameheaders on HTTP. - The break people actually hit: old clients get
-32022from modern-only servers. Keep legacy on for public servers. - Deprecated, not removed: Roots, Sampling and Logging work until at least July 28, 2027.
I wrote the first version of this guide a week before the 2026-07-28 MCP spec went final. It has now been live for four months, and the migration questions I get have changed.
In July the question was “what will break?”. Now it is “I migrated, so why can’t some clients connect?”. This update answers both, based on what actually happened once SDKs and clients shipped.
If you run an MCP server built on 2025-11-25, this is the checklist to move it to 2026-07-28. If you are starting from scratch, build your MCP server on the 2026-07-28 spec directly instead.
The short version: the code changes are small, the SDK does most of the work, and the real risk is cutting off clients that have not upgraded.
What the 2026-07-28 MCP Spec Changed
The maintainers called it the largest revision since launch, and it is. Here is the before and after for a server.
| Area | 2025-11-25 (legacy) | 2026-07-28 (modern) |
|---|---|---|
| Connection start | initialize handshake | None. server/discover is a MUST |
| Sessions | Mcp-Session-Id header | Removed |
| Protocol version | Negotiated once | In _meta on every request |
| HTTP routing | Gateway inspects the body | Mcp-Method and Mcp-Name headers, required |
| List caching | None | ttlMs and cacheScope on list results |
| Resource not found | -32002 | -32602 |
| Server asking the client | Server-to-client requests | Multi round-trip requests (inputRequired) |
| Scaling | Sticky sessions or a shared store | Any instance, any request |
I covered the reasoning behind the stateless design in MCP goes stateless. This post is only about getting an existing server across.
The 2026-07-28 MCP Migration Checklist
- Install the v2 SDK package next to v1.
- Remove session handling. Move any per-session state into explicit arguments.
- Let the SDK answer
server/discover, and set cache hints on lists. - Make sure every proxy forwards
Mcp-MethodandMcp-Name. - Fix hardcoded
-32002checks. - Replace Roots, Sampling and Logging, or schedule it before July 2027.
- Check your OAuth flow against the 2026 rules, starting with
issvalidation. - Keep legacy support on, and log which era each request uses.
- Test both eras before you ship.
Step 1: Pick the Right MCP SDK Package
The TypeScript v2 SDK did not ship as a major version bump. It shipped as a new package, @modelcontextprotocol/server, and the old @modelcontextprotocol/sdk v1 line is still maintained.
So you can install v2 beside v1 and move one endpoint at a time. Python, Go and C# also shipped 2026-07-28 support on launch day, so check your SDK’s release notes for the version that added it.
The zod 4 gotcha
jsonSchema property. Only zod 4 does. If your repo is on zod 3, install zod 4 under an alias instead of upgrading everything at once.Step 2: Remove Sessions From Your MCP Server
Delete the initialize handler, the session ID generator, and the shared session store. Each request now carries its protocol version and client info in _meta.
The harder part is code that quietly depended on a session. A shopping basket, a selected workspace, an open file handle: anything you kept server-side between calls.
Move that state into explicit handles. Return a basket_id from one tool and take it as an argument in the next. The model passes it along, and any instance can serve the call.
Once sessions are gone, a server that needed sticky routing can sit behind a plain round-robin load balancer. That is the main payoff of the migration.
Step 3: server/discover, Routing Headers and Cache Hints
server/discover is a MUST, but the SDK answers it
Capabilities used to come from the handshake. Now clients call server/discover. The v2 SDK answers it from the tools, prompts and resources you registered, so you write no handler.
Mcp-Method and Mcp-Name are required on HTTP
Modern requests carry the method and the tool or resource name as HTTP headers, so a gateway can route without reading the body. If a proxy strips unknown headers, modern traffic fails there. My MCP gateway guide covers the proxy side.
The same rule covers the new events/* methods: Mcp-Name must carry the event name, and some client SDKs don’t send it yet. The MCP Events guide lists that and the other rules servers trip on.
Set cache hints, or clients refetch every time
List results now carry ttlMs and cacheScope. Without your hints the SDK sends ttlMs: 0 and cacheScope: 'private', which is compliant but tells clients nothing.
Step 4: Fix the Error Codes
Resource-not-found moved from -32002 to the standard JSON-RPC -32602 (invalid params). A client with a hardcoded -32002 check silently stops matching.
If you serve both eras, return the era-correct code: -32002 to legacy requests, -32602 to modern ones. What MCP error -32602 means covers the other cases that return it.
There is also a new code to recognise. -32022 UnsupportedProtocolVersion is what a modern-only server returns to an old handshake. If you see it in client logs, the server dropped legacy support.
Step 5: Plan Off Roots, Sampling and Logging
The spec added a formal lifecycle: Active, then Deprecated, then Removed. Deprecated features keep working in this release and in every spec version published within a year, so the earliest removal is July 28, 2027.
- Roots: pass the scope explicitly, as a tool parameter, a resource URI or server config.
- Sampling: call your model provider’s API from the server instead of asking the client to sample.
- Logging: write to stderr or send structured logs to OpenTelemetry. W3C Trace Context propagation is now standard across SDKs.
If your server used to call back into the client mid-request, look at multi round-trip requests. Your handler returns an inputRequired result, and the client re-sends the original request with the answers. The v2 SDK maps the same handler onto 2025-era connections.
Long-running work moved too. The experimental Tasks API is now the Tasks extension.
Step 6: Tighten Authorization
Six auth proposals bring MCP closer to plain OAuth 2.0 and OpenID Connect. Most of the work lands on clients and authorization servers, not on the MCP server itself.
- Clients must validate the
issparameter on authorization responses, per RFC 9207. If you run the authorization server, make sure it sends one. - Clients declare
application_typeduring dynamic client registration, so a CLI or desktop client is not treated as a web app. - Credentials bind to a specific authorization-server issuer.
- Scope accumulation during step-up and
.well-knowndiscovery are clarified.
My MCP OAuth guide has been updated for both the 2025-11-25 and 2026-07-28 auth rules.
Migrated? Check both eras before you ship
Connect your server, force either spec revision, and call every tool. Free, in the browser.
Don’t Lock Out Old MCP Clients
This is the problem that showed up after launch. Plenty of clients are still on 2025-era SDKs: pinned versions in production agents, internal tools nobody has touched, desktop apps whose users never update.
Those clients only know the initialize handshake. A modern-only server answers it with -32022, and the connection ends. New v2 clients are fine either way, because they try server/discover and fall back to the handshake.
In the v2 TypeScript SDK, serving both is the default. One factory backs both eras, so they cannot drift apart.
Count the era on every request. When legacy traffic stays near zero for a few weeks, announce a date and switch to legacy: 'reject'. The dual-protocol checklist covers sessionful legacy servers and the full decision.
How to Test Your 2026-07-28 MCP Migration
A green test on the newest client says nothing about old ones, so test each era separately.
- Open the MCP server tester and connect with the version switch on Stateless 2026-07-28.
- Confirm
server/discoverlists every tool, and that list results carryttlMsandcacheScope. - Reconnect on Stateful 2025-11-25. The same tools should appear.
- Call one tool on each era, and request a missing resource to check the error code.
- Run the MCP Checker to see the revision you asked for next to the one that answered.
If you maintain a client, point it at the hosted mock MCP servers. The stateless mock accepts ?rev=2026-07-28 or ?rev=2025-11-25, so you can trigger the -32022 rejection on purpose.
Bottom line
Install the v2 SDK, remove sessions, let the SDK answer server/discover, fix the error codes and check your OAuth flow. Then keep legacy support on until your own traffic says nobody needs it.
FAQ: Migrating to the 2026-07-28 MCP Spec
Sources
Written by Nikhil Tiwari
15+ years in product development. AI enthusiast building developer tools that make complex technologies accessible to everyone.
Free MCP Tools (no install)
Build, compare & ship MCP agents
Connect any MCP server, run evals on it, compare 90+ models side-by-side, deploy hosted servers, and save reusable agents you can export as an API — all in your browser.