Terminal Server
MCP server that can execute terminal commands
What is Terminal Server?
Terminal Server is a Model Context Protocol (MCP) server that allows AI assistants like Claude, Cursor, and VS Code to mcp server that can execute terminal commands
MCP server that can execute terminal commands
This server falls under the Developer Tools category on MCPgee, the world's largest MCP server directory with 33,000+ servers.
Features
- MCP server that can execute terminal commands
Use Cases
Maintainer
Works with
Installation
Manual Installation
npx terminal-serverConfiguration
Configuration Details
claude_desktop_config.json
Performance
Response Metrics
Resource Usage
How to Set Up and Use Terminal Server
Terminal Server is a Python MCP server that gives AI assistants like Claude the ability to execute shell commands directly in a designated workspace directory on your machine. Built with FastMCP, it exposes a single `run_command` tool that runs arbitrary shell commands via subprocess and returns stdout or stderr to the AI. It supports multiple deployment modes including local Python (stdio), Docker (stdio), Docker with SSE transport, and Google Cloud Platform, making it flexible for both local development and cloud-hosted AI workflows.
Prerequisites
- Python 3.10 or higher and the `uv` package manager installed
- Git to clone the repository
- Docker (optional, for containerized deployment modes)
- An MCP-compatible client such as Claude Desktop
- A designated workspace directory where commands will be executed
Clone the repository
Download the terminal server source code from GitHub.
git clone https://github.com/theailanguage/terminal_server.git
cd terminal_serverInstall dependencies with uv
Use uv to install the Python dependencies required by the server.
uv sync
# Or with pip:
pip install -r requirements.txtCreate a workspace directory
The server runs commands inside `~/mcp/workspace` by default. Create this directory or adjust the DEFAULT_WORKSPACE variable in terminal_server.py to match your preferred location.
mkdir -p ~/mcp/workspaceConfigure Claude Desktop
Edit your claude_desktop_config.json to register the terminal server using uv to run terminal_server.py. Replace the directory path with your actual clone location.
{
"mcpServers": {
"terminal": {
"command": "uv",
"args": [
"--directory", "/absolute/path/to/terminal_server",
"run",
"terminal_server.py"
]
}
}
}Restart Claude Desktop and verify
Restart Claude Desktop after saving the configuration. The terminal server will appear as an available tool. Test with a simple command to confirm connectivity.
Terminal Server Examples
Client configuration
Claude Desktop configuration using uv to run terminal_server.py from the cloned repository directory.
{
"mcpServers": {
"terminal": {
"command": "uv",
"args": [
"--directory", "/Users/yourname/terminal_server",
"run",
"terminal_server.py"
]
}
}
}Prompts to try
Ask Claude to run shell commands via the terminal server's run_command tool.
- "Run the command ls in my workspace"
- "Execute echo Hello from Claude"
- "List all Python files in the workspace directory"
- "Run pwd to show the current working directory"
- "Check if a file called config.json exists in the workspace"Troubleshooting Terminal Server
Claude Desktop cannot find or start the server
Verify the `--directory` path in the config points to the exact location where you cloned the repo. Also ensure `uv` is on the system PATH by running `which uv` in a terminal.
Commands fail with 'No such file or directory' errors
The server runs all commands inside `~/mcp/workspace` by default. Ensure this directory exists (`mkdir -p ~/mcp/workspace`). If you want a different working directory, edit the `DEFAULT_WORKSPACE` variable in `terminal_server.py`.
Docker-based deployment not receiving commands
When using the Docker deployment, make sure you build the image first (`docker build -t terminal_server_docker .`) and that the volume mount path in the config matches the workspace you want to expose inside the container.
Frequently Asked Questions about Terminal Server
What is Terminal Server?
Terminal Server is a Model Context Protocol (MCP) server that mcp server that can execute terminal commands It connects AI assistants to external tools and data sources through a standardized interface.
How do I install Terminal Server?
Follow the installation instructions on the Terminal Server GitHub repository. Clone the repo, install dependencies, and add the server config to your AI client.
Which AI clients work with Terminal Server?
Terminal Server works with all major MCP-compatible AI clients including Claude Desktop, Claude Code, Cursor, VS Code (GitHub Copilot), Windsurf, and Cline.
Is Terminal Server free to use?
Yes, Terminal Server is open source and available under the NOASSERTION license. You can use it freely in both personal and commercial projects.
Terminal Server Alternatives — Similar Developer Tools Servers
Looking for alternatives to Terminal Server? 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 Terminal Server 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 Terminal Server?
Browse our complete directory of 33,000+ MCP servers, read setup guides for your editor, and start building with the Model Context Protocol.