Claude Desktop Commander
Allows Claude desktop app to execute terminal commands and edit files on your computer through MCP, with features including command execution, process management, and diff-based file editing.
What is Claude Desktop Commander?
Claude Desktop Commander is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to allows claude desktop app to execute terminal commands and edit files on your computer through mcp, with features including command execution, process management, and diff-based file editing.
Allows Claude desktop app to execute terminal commands and edit files on your computer through MCP, with features including command execution, process management, and diff-based file editing.
This server falls under the Developer Tools category on MCPgee, the world's largest MCP server directory with 33,000+ servers.
Features
- Allows Claude desktop app to execute terminal commands and e
Use Cases
Maintainer
Works with
Installation
NPM
npx -y @wonderwhy-er/desktop-commanderManual Installation
npx -y @wonderwhy-er/desktop-commanderConfiguration
Configuration Details
claude_desktop_config.json
Performance
Response Metrics
Resource Usage
How to Set Up and Use Claude Desktop Commander
Desktop Commander MCP gives Claude full control of your local machine through the Model Context Protocol — letting it execute terminal commands, manage interactive processes, search and edit files, and even read Excel, PDF, and DOCX documents. It exposes a rich set of tools covering terminal session management, diff-based file editing, fuzzy search, and in-memory code execution (Python, Node.js, R) without leaving traces on disk. Developers and power users install it to turn Claude Desktop or Claude Code into a hands-on coding assistant that can operate their entire filesystem and run long-lived processes.
Prerequisites
- Node.js 18 or later installed
- Claude Desktop or Claude Code as your MCP client
- npx available on your PATH (comes with Node.js)
- macOS, Windows, or Linux (Docker option available for isolation)
Run the automated setup
The recommended installation method runs a setup script that automatically configures your Claude Desktop config file.
npx @wonderwhy-er/desktop-commander@latest setupAlternative: bash installer for macOS
If you prefer a single-line installer, use the provided curl script.
curl -fsSL https://raw.githubusercontent.com/wonderwhy-er/DesktopCommanderMCP/refs/heads/main/install.sh | bashAlternative: Docker for full sandboxing
Run Desktop Commander inside Docker if you want complete isolation from your host system.
bash <(curl -fsSL https://raw.githubusercontent.com/wonderwhy-er/DesktopCommanderMCP/refs/heads/main/install-docker.sh)Manual Claude Desktop configuration
If you prefer to edit the config yourself, add this block to claude_desktop_config.json. On macOS the file is at ~/Library/Application Support/Claude/claude_desktop_config.json.
{
"mcpServers": {
"desktop-commander": {
"command": "npx",
"args": ["-y", "@wonderwhy-er/desktop-commander@latest"]
}
}
}Add via Claude Code CLI
If using Claude Code rather than Claude Desktop, register the server at user scope.
claude mcp add --scope user desktop-commander -- npx -y @wonderwhy-er/desktop-commander@latestTune configuration via the set_config_value tool
After installation you can configure security and behaviour settings. Key options include blockedCommands, allowedDirectories, defaultShell, fileReadLineLimit, and telemetryEnabled.
# Example: ask Claude to restrict file operations to your project directory
# In Claude: "Set allowedDirectories to ["/Users/you/projects"]" Claude Desktop Commander Examples
Client configuration
Minimal claude_desktop_config.json entry to enable Desktop Commander MCP.
{
"mcpServers": {
"desktop-commander": {
"command": "npx",
"args": ["-y", "@wonderwhy-er/desktop-commander@latest"]
}
}
}Prompts to try
Desktop Commander enables Claude to act as a hands-on terminal and file agent.
- "Search all TypeScript files under src/ for usages of the deprecated API and show me a diff of the changes needed"
- "Start a dev server with npm run dev and watch the output for errors"
- "Read the Excel spreadsheet at ~/data/sales.xlsx and summarise Q4 figures"
- "Create a new React component file at src/components/Button.tsx with proper TypeScript types"Troubleshooting Claude Desktop Commander
Claude cannot find or execute commands after installation
Restart Claude Desktop after running the setup script so the updated claude_desktop_config.json is reloaded. Verify the config at ~/Library/Application Support/Claude/claude_desktop_config.json (macOS) contains the desktop-commander entry.
File edits fail with 'text not found' or fuzzy match errors
Desktop Commander uses exact string matching with fuzzy fallback. Ensure the SEARCH block in your edit_block call contains the exact text from the file (including whitespace). Check ~/.claude-server-commander-logs/fuzzy-search.log for details.
Terminal commands run but allowedDirectories restriction is ignored
The allowedDirectories setting only restricts file operation tools (read_file, write_file, etc.). Terminal commands executed via start_process bypass this restriction by design. Use the blockedCommands config key to prevent specific dangerous shell commands.
Frequently Asked Questions about Claude Desktop Commander
What is Claude Desktop Commander?
Claude Desktop Commander is a Model Context Protocol (MCP) server that allows claude desktop app to execute terminal commands and edit files on your computer through mcp, with features including command execution, process management, and diff-based file editing. It connects AI assistants to external tools and data sources through a standardized interface.
How do I install Claude Desktop Commander?
Install via npm with the command: npx -y @wonderwhy-er/desktop-commander. Then add the server configuration to your AI client's JSON config file (e.g., claude_desktop_config.json or .cursor/mcp.json).
Which AI clients work with Claude Desktop Commander?
Claude Desktop Commander works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.
Is Claude Desktop Commander free to use?
Yes, Claude Desktop Commander is open source and available under the MIT license. You can use it freely in both personal and commercial projects.
Claude Desktop Commander Alternatives — Similar Developer Tools Servers
Looking for alternatives to Claude Desktop Commander? Here are other popular developer tools servers you can use with Claude, Cursor, and VS Code.
Ecc
★ 188.2kThe agent harness performance optimization system. Skills, instincts, memory, security, and research-first development for Claude Code, Codex, Opencode, Cursor and beyond.
Javaguide
★ 155.8kJava 面试 & 后端通用面试指南,覆盖计算机基础、数据库、分布式、高并发、系统设计与 AI 应用开发
Gemini CLI
★ 104.5kA secure MCP server that wraps the Google Gemini CLI, allowing clients to query Gemini models using local OAuth sessions without requiring an API key. It provides tools for model interaction and diagnostics with built-in protection against command in
Awesome MCP Servers
★ 87.3k⭐ Curated list of Model Context Protocol (MCP) servers - tools that extend Claude Desktop, Cursor, Windsurf, and other MCP clients with custom capabilities.
MCP Servers
★ 86.0kModel Context Protocol Servers
CC Switch
★ 77.5kA cross-platform desktop All-in-One assistant for Claude Code, Codex, OpenCode, OpenClaw, Gemini CLI & Hermes Agent. Only official website: ccswitch.io
Browse More Developer Tools MCP Servers
Explore all developer tools servers available in the MCPgee directory. Each server includes setup guides for Claude, Cursor, and VS Code.
Set Up Claude Desktop Commander in Your Editor
Choose your AI client for step-by-step setup instructions.
Quick Config Preview
Add this to your claude_desktop_config.json or .cursor/mcp.json
Ready to use Claude Desktop Commander?
Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.