Writes to the active iTerm terminal, often used to run a command. Returns the number of lines of output produced by the command.
Reads the requested number of lines from the active iTerm terminal.
Sends a control character to the active iTerm terminal.
iTerm Terminal Control provides AI models with the ability to interact directly with your iTerm terminal sessions. It enables models to execute commands, read terminal output, and send control characters, making it ideal for CLI assistance and REPL interactions. This tool is designed with efficiency in mind, allowing models to inspect only the specific terminal output they need rather than the entire session history. The integration feels natural as you share your terminal with the model, which can help with troubleshooting, executing multi-step tasks, or interacting with command-line tools and programming language REPLs.
iTerm Terminal Control allows AI models to interact with your active iTerm terminal sessions. This enables the model to help you with command-line tasks, troubleshoot issues, and interact with REPLs (Read-Eval-Print Loops) for various programming languages.
Before installing iTerm Terminal Control, ensure you have:
Create or edit the Claude Desktop configuration file:
~/Library/Application Support/Claude/claude_desktop_config.json
%APPDATA%/Claude/claude_desktop_config.json
Add the following configuration:
{
"mcpServers": {
"iterm-mcp": {
"command": "npx",
"args": [
"-y",
"iterm-mcp"
]
}
}
}
You can also install iTerm Terminal Control automatically using Smithery:
npx -y @smithery/cli install iterm-mcp --client claude
Once installed, you can ask the AI model to:
When using iTerm Terminal Control, keep these safety points in mind:
If you encounter issues: