Terminal MCP Server

A Model Context Protocol (MCP) server for secure terminal command execution and file system operations

Local serverstdioPython

What is the Terminal MCP server?

Terminal MCP server exists for a simple reason — assistants are far more useful when they can act on Terminal directly instead of describing what you should do. A Model Context Protocol (MCP) server for secure terminal command execution and file system operations.

What you get

  • Command Execution — Run terminal commands with timeout controls and comprehensive output capture
  • Directory Management — Navigate and list directory contents with intuitive formatting
  • Security Measures — Built-in safeguards against dangerous commands and operations
  • Command History — Track and display recent command executions
  • Cross-Platform Support — Works on both Windows and UNIX-based systems
  • File Operations — Read, write, update, insert, and delete file content with row-level precision

What the assistant can call

Once Terminal is connected, these are the calls the assistant has available:

  • Prerequisites — The Prerequisites tool exposed by this server
  • Cursor — For Cursor, use similar configuration settings as Claude Desktop
  • execute_command — The execute_command tool exposed by this server
  • get_command_history — The get_command_history tool exposed by this server
  • get_current_directory — The get_current_directory tool exposed by this server
  • change_directory — The change_directory tool exposed by this server
  • list_directory — The list_directory tool exposed by this server
  • write_file — The write_file tool exposed by this server
  • read_file — The read_file tool exposed by this server
  • insert_file_content — The insert_file_content tool exposed by this server
  • delete_file_content — The delete_file_content tool exposed by this server
  • update_file_content — The update_file_content tool exposed by this server

Configuration and credentials

  • Python 3.11+ - An MCP-compatible client (such as Claude Desktop) - UV/UVX installed (optional, for UVX method)

Setting it up

Installation goes through your MCP client rather than a global install: point it at @smithery/cli on npm and it is fetched when the client starts. The copy-paste blocks for Claude Desktop, Claude Code and Cursor are further down this page.

Choosing this one

Among the file and storage access options, the useful question is rarely "what can it do" but "what does it cost you to run" — permissions, credentials, and how much of your context its toolset consumes. Terminal's toolset — Prerequisites, Cursor, execute_command and 9 more — is a fair guide to whether it matches your workflow.

SyncDev reviews every entry in this directory against the project's own documentation before publishing, and revisits them as servers change.

Before you rely on it

  • It runs with your machine's permissions. That is convenient and also the reason to think about what you point it at before you approve a tool call.
  • With 12 tools registered it takes up a noticeable share of the context window; turn it off in projects that never touch Terminal.
  • MCP clients confirm each tool call by default. Leave that on until you have watched what the terminal mcp server does with a few real requests.

Available tools

ToolWhat it does
PrerequisitesThe Prerequisites tool exposed by this server.
CursorFor Cursor, use similar configuration settings as Claude Desktop.
execute_commandThe execute_command tool exposed by this server.
get_command_historyThe get_command_history tool exposed by this server.
get_current_directoryThe get_current_directory tool exposed by this server.
change_directoryThe change_directory tool exposed by this server.
list_directoryThe list_directory tool exposed by this server.
write_fileThe write_file tool exposed by this server.
read_fileThe read_file tool exposed by this server.
insert_file_contentThe insert_file_content tool exposed by this server.
delete_file_contentThe delete_file_content tool exposed by this server.
update_file_contentThe update_file_content tool exposed by this server.

How to install the Terminal MCP server

{
  "mcpServers": {
    "terminal-controller": {
      "command": "npx",
      "args": ["-y", "@smithery/cli"]
    }
  }
}

Add to claude_desktop_config.json, then restart Claude Desktop.

Configuration

  • Python 3.11+ - An MCP-compatible client (such as Claude Desktop) - UV/UVX installed (optional, for UVX method)

Example prompts to try

  • Use Terminal to Prerequisites.
  • Use Terminal to Cursor.
  • Use Terminal to execute command.

Frequently asked questions

It connects Terminal to MCP-compatible AI assistants such as Claude and Cursor, exposing 12 tools (Prerequisites, Cursor, execute_command, and more) that the assistant can call on your behalf. Instead of copying data back and forth by hand, the assistant works with Terminal directly.