MCP_DISCOVERY_CACHE
A Claude Code environment variable, read out of the shipped bundle. It has been in the build since v2.1.217, including the newest one read.
Startup no longer dials cached HTTP or SSE MCP servers; they restore from cache and connect on first use.
Not Anthropic's. This is the line from the earliest changelog entry here that named it, v2.1.221.
In the changelogs
8Releases whose published page names MCP_DISCOVERY_CACHE.
-
v2.1.285
MCP discovery cache now limited to dynamic toolbox servers in cloud sessions
With
MCP_DISCOVERY_CACHEon, only dynamic toolbox HTTP servers in cloud sessions that send two identifying headers can use the cachefound in this entry's text
-
v2.1.282
MCP discovery cache stays off when Claude Code runs without a disk
In a diskless launch, Claude Code now keeps the MCP discovery cache off for the whole session regardless of other settings
found in this entry's text, named in this entry
-
v2.1.238
The MCP discovery cache is now off unless explicitly turned on
The MCP discovery cache flipped from on-by-default to off unless the server or you enable it.
named in this entry, found in this entry's text
-
v2.1.238
MCP work aborts when the signed-in account changes mid-flight
Switching accounts would cancel in-flight MCP work instead of finishing it under the new identity, but it's dark.
found in this entry's text
-
v2.1.238
MCP servers can connect lazily from a cached entry
Tool calls to a remembered MCP server could dial it on demand, but the cache behind it is off.
named in this entry, found in this entry's text
-
v2.1.232
MCP discovery cache and skills fetcher built on first use
The MCP discovery cache and skills fetcher are built on first use rather than at load.
found in this entry's text
-
v2.1.221
MCP servers can start from a discovery cache and connect lazily
Startup no longer dials cached HTTP or SSE MCP servers; they restore from cache and connect on first use.
named in this entry, found in this entry's text
-
v2.1.221
MCP servers can start in a new "cached" state instead of blocking on connect
MCP servers with a saved cache now show tools instantly and only connect when you first use them.
named in this entry, found in this entry's text
First cited
2The earliest release whose published evidence quoted MCP_DISCOVERY_CACHE was v2.1.238, 20 Aug 2026. That is the oldest release this project wrote about it, so it is a floor on the name's age and not the release that introduced it. It is not a presence reading: which builds carried the name is the table below.
Presence across releases
1Build by build
81One row per release since the first build this name was read out of. Absent means the build was read and the name was not in it, never mined means no bundle for that release was ever archived, and a declared type or a default is only ever what that release's own bundle stated.
Read out of the published npm bundle release by release, and out of Anthropic's own documentation as this site captured it. Nothing on this page is a description anybody here wrote about what the environment variable does. All environment variables.