[DOCS] MCP auto-background threshold and disable setting are missing from the docs

Status Fixed / completed
Reported on v2.1.212
Maintainer reply None cached
Activity 1 comment · opened Jul 17, 2026 · closed Aug 17, 2026

Documentation Type

Missing documentation (feature not documented)

Documentation Location

https://code.claude.com/docs/en/mcp

Section/Topic

Long-running MCP tool calls and the environment variables that control automatic backgrounding.

Current Documentation

The environment-variable reference currently says:

“Set to 1 to force-enable automatic backgrounding of long-running agent tasks. When enabled, subagents are moved to the background after running for approximately two minutes...”

The MCP guide explains that servers can connect in the background, but it does not document automatic backgrounding of an MCP tool call that itself runs longer than two minutes.

What's Wrong or Missing?

Claude Code 2.1.212 changes long-running MCP tool calls so they move to the background automatically after the configured threshold, keeping the session usable. The release adds CLAUDE_CODE_MCP_AUTO_BACKGROUND_MS to configure the threshold or disable the behavior, but the variable is absent from the environment-variable reference and the MCP guide does not describe the transition from a foreground tool call to a background task.

The current wording about automatic backgrounding mentions subagents only, so MCP users cannot discover the new behavior or control it when a server operation must remain attached to the current turn.

Suggested Improvement

Update the MCP guide and environment-variable reference to explain:

  • that an MCP tool call exceeding the threshold is moved to the background;
  • the default threshold and units for CLAUDE_CODE_MCP_AUTO_BACKGROUND_MS;
  • how to set a custom threshold and how to disable automatic MCP backgrounding; and
  • how users monitor, attach to, or retrieve the result of the background call.

Keep this separate from MCP_CONNECTION_NONBLOCKING, which controls server startup rather than the execution of a long-running tool call.

Impact

Medium - Makes feature difficult to understand

Additional Context

Affected Pages:

| Page | Context |
|------|---------|
| https://code.claude.com/docs/en/mcp | MCP tool execution and background behavior |
| https://code.claude.com/docs/en/env-vars | Missing CLAUDE_CODE_MCP_AUTO_BACKGROUND_MS reference |
| https://code.claude.com/docs/en/agent-view | Where users monitor background work, if MCP calls appear there |

Total scope: 3 pages should explain the behavior and its controls.

The behavior was added in Claude Code 2.1.212; the release notes are listed at https://code.claude.com/docs/en/changelog.

View original on GitHub ↗

This issue has 1 comment on GitHub. Read the full discussion on GitHub ↗