# MCP Inspector

CreateWithAI Hub page: https://createwithaihub.com/open-source/mcp-inspector
Latest version of this file: https://createwithaihub.com/open-source/mcp-inspector.md

- Type: Library · Category: Libraries & Open Source
- Publisher: Model Context Protocol project
- Pricing: Free · License: Apache-2.0 AND MIT
- Runs on: Web, macOS, Windows, Linux, Docker / self-hosted

The MCP project's developer tool for testing and debugging MCP servers from a web UI, a scriptable CLI or a terminal UI.

MCP Inspector is the reference tool from the Model Context Protocol project for connecting to an MCP server and exercising it by hand or from scripts. One npm package, @modelcontextprotocol/inspector, runs a browser UI (the default), a CLI for CI and coding agents, and a terminal UI, all sharing the same transports, config files and OAuth state. It is for developers building or reviewing MCP servers who want to see the tools, prompts, resources and raw JSON-RPC traffic before wiring a server into a client.

Useful for: Launching a local MCP server through the Inspector, calling each of its tools with test arguments, and checking the JSON-RPC transcript and server logs before publishing it.

## Key features

- Web UI with Tools, Prompts, Resources, Apps (MCP App UIs), Logs, Protocol (JSON-RPC transcript), Network and Console tabs
- CLI mode (--cli) with --method calls and --format json output for CI smoke tests and coding agents
- Terminal UI (--tui) and an experimental mcpdo connection CLI in the same package
- Connects to stdio servers or remote servers over Streamable HTTP or legacy SSE, with an end-to-end OAuth flow
- Handles both legacy and modern (2026-07-28) protocol versions
- Load testing, Docker image and secrets kept in the OS keychain

## Connection

- Language: TypeScript / JS

## Before you start

- Node.js 22.23.4+, 24.22.1+ or 26.12.1+

## Install steps from the official documentation

Web UI (default):

```
npx @modelcontextprotocol/inspector
```

Inspect a local stdio server:

```
npx @modelcontextprotocol/inspector node path/to/server/index.js
```

CLI: list a server's tools:

```
npx @modelcontextprotocol/inspector --cli node path/to/server/index.js --method tools/list
```

Inspect a remote server:

```
npx @modelcontextprotocol/inspector --server-url https://api.example.com/mcp --transport http
```

Terminal UI:

```
npx @modelcontextprotocol/inspector --tui node path/to/server/index.js
```

## Limitations

- Requires Node.js 22.23.4+, 24.22.1+ or 26.12.1+
- Without an OS keychain (headless Linux, SSH, containers) secrets are saved to ~/.mcp-inspector/secrets.json unencrypted unless you supply a key
- The web backend can spawn processes, so it binds to 127.0.0.1 and guards its API with a per-launch token; exposing it on a network needs explicit opt-in
- v2 changed CLI flags and config files; the v1 line (npm tag v1-latest) only gets security fixes

## Official links

- Website: https://modelcontextprotocol.io/docs/tools/inspector
- Source repository: https://github.com/modelcontextprotocol/inspector
- Documentation: https://modelcontextprotocol.io/docs/tools/inspector
- Source: https://github.com/modelcontextprotocol/inspector (README: single package with Web, CLI, TUI and experimental mcpdo; npx commands; secret storage warning; v2 on main, v1 on v1-latest with security fixes only; not archived)
- Source: https://raw.githubusercontent.com/modelcontextprotocol/inspector/main/LICENSE (Licensing transition: new code Apache-2.0, unrelicensed older contributions MIT, docs CC-BY-4.0; copyright Model Context Protocol a Series of LF Projects, LLC)
- Source: https://modelcontextprotocol.io/docs/tools/inspector (Reference tool for testing/debugging MCP servers; Node version requirement; quickstart, published-server and remote-server commands; legacy vs modern (2026-07-28) protocol eras)
- Source: https://modelcontextprotocol.io/docs/2026-07-28/tools/inspector/web (Web client tabs, http/sse transports, per-launch token, 127.0.0.1 binding on port 6274 and DANGEROUSLY_BIND_ALL_INTERFACES opt-in)
