Labsco
MCP SERVER

Desktop Commander MCP

by wonderwhy-er

Give an assistant the machine itself: files read and edited in place, searches that stream, and terminal sessions it can keep talking to.

Local Filesystem AccessOfficial source
Summary
Data analysis stops needing a file upload.

A REPL or a shell stays alive across calls, so a Python session can load a large file once and then be asked about it repeatedly instead of re-reading it every turn. The configuration is the thing to set first, and to understand the limits of.

What it is

File and process control on the local machine — reads that handle PDFs, images and Excel sheets, surgical edits, streaming search, and long-lived terminal processes you send input to and read output from. Twenty-six tools across configuration, terminal, filesystem, text editing and analytics.

What you get
  • Files and URLs read — including PDFs and Excel workbooks — with line or page pagination, and several files read in one call (`read_file`, `read_multiple_files`)
  • Files written or appended to, and PDFs created from markdown or modified page by page, with HTML and CSS styling and SVG graphics (`write_file`, `write_pdf`)
  • Surgical edits by old string and new, with the number of expected replacements stated up front, a fuzzy fallback when the exact match fails, and character-level diffs showing what differed (`edit_block`)
  • Directories created and listed to a depth, files moved or renamed, and full metadata for any path including Excel sheet info (`create_directory`, `list_directory`, `move_file`, `get_file_info`)
  • Searches started as a stream, results pulled progressively, and the search listed or stopped while it runs (`start_search`, `get_more_search_results`, `list_searches`, `stop_search`)
  • Terminal processes started, written to and read from while they run, listed, and terminated by PID (`start_process`, `interact_with_process`, `read_process_output`, `list_sessions`, `list_processes`, `kill_process`, `force_terminate`)
  • The server's own configuration read and changed — blocked commands, default shell, allowed directories, read and write line limits, telemetry (`get_config`, `set_config_value`)
  • Its own usage statistics and recent tool calls with the arguments and outputs they carried, which is how a lost session gets its context back (`get_usage_stats`, `get_recent_tool_calls`)
Requirements

Npx on your PATH. It acts on the machine it runs on, under your own user permissions, so read the boundaries before wiring it in. `allowedDirectories` restricts filesystem operations only — terminal commands can still reach files outside it — and setting it to an empty array grants the whole filesystem. The maintainers are explicit that directory restrictions and command blocking can be bypassed through symlinks, command substitution and absolute paths, and point at the Docker image when real isolation is the requirement. `fileReadLineLimit` defaults to 1000 lines and `fileWriteLineLimit` to 50, both raisable. Change configuration in a separate conversation from the work, because a model that hits a restriction may try to widen it.

Setup effort

One command — npx @wonderwhy-er/desktop-commander@latest setup