Fix guide · updated 2026-11-20
MCP error -32001: Request timed out (why MCP calls stop at 60 seconds)
McpError: MCP error -32001: Request timed out
A tool call fails with McpError: MCP error -32001: Request timed out. The server didn't send that error: your client stopped waiting. The TypeScript SDK gives up after 60 seconds unless you raise the limit, and Codex and Claude Code (with remote servers) also stop a request at 60 seconds by default. We reproduced each case below on a local server with the official TypeScript SDK (1.29) and Python SDK (1.30.0), and read the clients' documentation (November 2026). Here's which limit you hit and how to raise it.
What the error means
The client sends a request and starts a timer. If no answer comes back in time, it gives up with code -32001 and tells the server it cancelled the request. In our test, a tool that needed 4 seconds, called with a 2-second limit, failed after exactly 2.0 seconds, and the server got the cancellation.
So the server isn't necessarily broken. Either the tool takes longer than the client's limit, or the server never answers at all. If the call always fails after the same number of seconds (60, 30, 10), you're hitting a limit, and the next section shows where it's set.
Two variants. MCP error -32001: Maximum total timeout exceeded is the same code for a ceiling on the whole call (maxTotalTimeout, below). A Python client says it differently: code 408 and Timed out while waiting for response to ClientRequest. Waited 2.0 seconds. The Python SDK has no limit at all unless you set one.
Raise the limit in your client
Claude Code. Add a timeout in milliseconds to the server's entry in .mcp.json, or set the MCP_TOOL_TIMEOUT environment variable for every server. For HTTP, SSE and claude.ai connector servers, each request also stops at 60 seconds by default, and a timeout above 60000 raises that limit too. The per-server timeout is a hard limit on the whole call: progress messages from the server don't extend it. A server that is slow to start is a different limit, MCP_TIMEOUT (default 30000).
{
"mcpServers": {
"my-server": {
"type": "http",
"url": "https://your-server.example.com/mcp",
"timeout": 600000
}
}
}
Codex. In ~/.codex/config.toml, on the server's entry: tool_timeout_sec (default 60) for tool calls and startup_timeout_sec (default 10) for starting the server.
[mcp_servers.my-server]
# … your existing settings for this server …
tool_timeout_sec = 300
startup_timeout_sec = 30
TypeScript SDK client. The limit goes in the options, which are the third argument of callTool:
const result = await client.callTool(
{ name: 'my_tool', arguments: { query: 'test' } },
undefined, // result schema: keep the default
{ timeout: 300_000 } // 5 minutes
);
Watch the position. In our test, passing { timeout: 2000 } as the second argument set no limit at all, and when the result came back the call failed with TypeError: v3Schema.safeParse is not a function, because the second argument is the schema that checks the result.
Python SDK client. No limit by default. If you set one, it applies to the whole session or to one call:
from datetime import timedelta
async with ClientSession(read, write, read_timeout_seconds=timedelta(minutes=5)) as session:
...
result = await session.call_tool("my_tool", {"query": "test"}, read_timeout_seconds=timedelta(minutes=5))
Other clients (MCP Inspector, n8n, IDE plugins) have their own request-timeout setting: look for it in the client's settings before changing the server.
Long tools: send progress
A tool that runs for minutes can report progress, and the TypeScript SDK client can restart its timer each time progress arrives. It only does that when the caller asks:
const result = await client.callTool(
{ name: 'long_job', arguments: {} },
undefined,
{
timeout: 30_000, // allowed silence between two progress messages
resetTimeoutOnProgress: true,
maxTotalTimeout: 600_000, // ceiling for the whole call
onprogress: (p) => console.log(`${p.progress}/${p.total ?? '?'}`),
}
);
On the server (TypeScript SDK), the tool sends progress when the client asked for it:
async (args, extra) => {
for (let i = 1; i <= steps; i++) {
await doOneStep(i);
if (extra._meta?.progressToken !== undefined) {
await extra.sendNotification({ method: 'notifications/progress',
params: { progressToken: extra._meta.progressToken, progress: i, total: steps } });
}
}
return { content: [{ type: 'text', text: 'done' }] };
}
In our test, a 5-second tool sending progress every second, called with a 2-second limit, failed at 2.0 seconds without resetTimeoutOnProgress and finished after 5.0 seconds with it. Adding maxTotalTimeout: 3000 stopped it at 3.0 seconds with Maximum total timeout exceeded.
Progress doesn't help with Claude Code's per-server timeout, which counts the whole call: raise that number instead. For jobs that run longer than any sensible limit, have the tool start the job and return an ID at once, and add a second tool that returns the result when it's ready.
Give your AI tool this prompt:
Our MCP client fails with "MCP error -32001: Request timed out" when it calls a tool that takes a long time. (1) Find where our client sets the MCP request timeout and raise it above the tool's real duration: TypeScript SDK = the third argument of callTool, { timeout } in milliseconds (not the second argument, that's the result schema); Claude Code = "timeout" in milliseconds on the server's entry in .mcp.json, or MCP_TOOL_TIMEOUT; Codex = tool_timeout_sec in config.toml. (2) If the tool is ours and can run long, send notifications/progress while it works (only when the request carries a progressToken), and call it with resetTimeoutOnProgress: true plus a maxTotalTimeout. (3) Make the tool stop its work when the request is cancelled (extra.signal in the TypeScript SDK). Don't change anything else.
If it's your server
When a client gives up, the work doesn't stop by itself. The TypeScript SDK passes the cancellation to your tool as extra.signal: in our test, a tool that listened to it stopped as soon as the client timed out. A tool that ignores it keeps running, and the client may retry it on top.
If even fast tools time out, the server isn't answering. Run the curl from our 406 guide with -v: if initialize hangs too, look at the server's logs, and make sure nothing between the client and the server holds the event stream back (a proxy that buffers responses, for example nginx without proxy_buffering off on the MCP location).
Not quite your error?
404withSession not foundontools/listor a tool call: see MCP server "Session not found" (404) after initialize.406 Not Acceptable: see MCP 406 Not Acceptable.405 Method Not Allowed: see MCP server 405 Method Not Allowed.
Still stuck?
Time the failing call. The same number of seconds every time means a client limit: find it in the list above. Random times mean the server or something in front of it: look at the server's logs for the request, and check whether it ever started.