Back to MCP Servers

Sequential Thinking MCP Server

Reference MCP server that enables structured, step-by-step problem solving with support for revising prior thoughts and branching reasoning paths.

Developer Tools by Anthropic (Model Context Protocol) None active
Overview

Sequential Thinking is a reference MCP server published in the official modelcontextprotocol/servers repository. It exposes a single tool, sequential_thinking, that gives an LLM a structured scratchpad for working through complex problems one step at a time. Each step can revise an earlier step, branch into an alternative line of reasoning, or extend the total thought count as the model discovers the problem is larger than expected.

The server is designed for situations where a problem cannot be solved in a single pass: tasks that require planning, hypothesis generation and verification, mid-course correction, or filtering irrelevant context. The tool itself does not perform reasoning; it provides a disciplined protocol the model uses to externalize its thinking, making chain-of-thought explicit, inspectable, and revisable across turns.

It is one of the original reference servers from the Model Context Protocol project and is distributed as an npm package (@modelcontextprotocol/server-sequential-thinking) and a Docker image. It has no external API dependencies and no authentication requirements, which makes it one of the simplest MCP servers to add to any client.

Tools

Tool Description
sequential_thinking Process a single step in a structured reasoning sequence. Supports revising earlier thoughts, branching into alternative reasoning paths, and dynamically expanding the planned number of steps.
Setup Guide

Prerequisites

  • Node.js (for the NPX install) or Docker
  • An MCP-compatible client such as Claude Desktop, Cursor, or VS Code with MCP support
  • No API key or account required

Claude Desktop (NPX)

Add to your claude_desktop_config.json:

{
  "mcpServers": {
    "sequential-thinking": {
      "command": "npx",
      "args": ["-y", "@modelcontextprotocol/server-sequential-thinking"]
    }
  }
}

Claude Desktop (Docker)

{
  "mcpServers": {
    "sequentialthinking": {
      "command": "docker",
      "args": ["run", "--rm", "-i", "mcp/sequentialthinking"]
    }
  }
}

Build the image locally with:

docker build -t mcp/sequentialthinking -f src/sequentialthinking/Dockerfile .

VS Code

Add to your user settings.json or .vscode/mcp.json:

{
  "servers": {
    "sequential-thinking": {
      "command": "npx",
      "args": ["-y", "@modelcontextprotocol/server-sequential-thinking"]
    }
  }
}

On Windows, wrap the command with cmd /c (for example "command": "cmd", "args": ["/c", "npx", "-y", "@modelcontextprotocol/server-sequential-thinking"]).

Optional Environment Variable

Set DISABLE_THOUGHT_LOGGING=true to suppress the server from logging each thought to stderr.

Use Cases
  • Plan and execute multi-step engineering tasks such as database migrations, where assumptions made early may need to be revised later in the process
  • Debug production incidents by enumerating hypotheses, testing them in sequence, and branching when a new clue invalidates the current line of reasoning
  • Compare architectural or design options by spawning parallel reasoning branches and reconciling them into a final recommendation
  • Decompose ambiguous product or research questions where the full scope only becomes clear after a few exploratory thoughts
  • Force an agent to externalize and inspect its chain of thought before taking destructive actions in other MCP tools
Example Prompts
  • "Use sequential thinking to plan a zero-downtime migration from Postgres 13 to Postgres 16 for our orders database."
  • "Think step by step about why our checkout p95 latency spiked yesterday at 18:00 UTC. Revise earlier thoughts if you find contradicting evidence."
  • "Compare a monolith versus modular monolith versus microservices for our current team size. Branch the reasoning and pick a winner."
  • "Walk through the tradeoffs of switching our auth from sessions to JWTs, expanding the thought count if you uncover more concerns."
  • "Use the sequential thinking tool to derive a test plan for the new pricing engine before I let you run any other tools."
Pros
  • Official reference implementation maintained in the modelcontextprotocol/servers repo
  • Zero configuration: no API keys, accounts, or external services required
  • Supports revision and branching, not just linear chain-of-thought, which is unusual among thinking tools
  • Available as both an npm package and a Docker image
Limitations
  • Provides only a single tool; it does not store thoughts across sessions or expose them as a queryable resource
  • The structure is advisory; the underlying model must still choose to use it well, and weaker models may misuse the revision/branch fields
  • No persistence, search, or visualization of the thought tree out of the box
Alternatives
  • Memory MCP server: another reference server, useful when you need persistent knowledge across sessions rather than in-context reasoning
  • mcp-think-tool: community server inspired by Anthropic's "think" tool pattern for scratchpad reasoning
  • Anthropic's built-in extended thinking on Claude models, which provides native step-by-step reasoning without a separate MCP server