Harness the power of local LLMs with this TUI MCP Client for Ollama. Featuring all core MCP primitives (tools, prompts, resources), agent mode, multi-server, mo
Harness the power of local LLMs with this TUI MCP Client for Ollama. Featuring all core MCP primitives (tools, prompts, resources), agent mode, multi-server, mo
A simple yet powerful Python client for interacting with Model Context Protocol (MCP) servers using Ollama, allowing you to harness local LLMs for advanced tool execution.
English | 简体中文 | Español
Sponsored by
Learn how to use Atlas Cloud with ollmcp in the Sponsors section
Watch this demo as an Asciinema recording
MCP Client for Ollama (ollmcp) is a modern, interactive terminal application (TUI) built for harness engineering, connecting local Ollama LLMs to one or more Model Context Protocol (MCP) servers. By fully supporting the core MCP primitives (tools, prompts, and resources), it provides a controlled terminal space where you steer, and the agent executes. With a rich, user-friendly interface, it lets you safely manage your setup in real time with no coding required. Whether you're building, testing, or exploring, this client streamlines your workflow with features like fuzzy autocomplete, advanced model configuration, MCP server hot-reloading for rapid development, and strict Human-in-the-Loop safety controls.
ollama list to see available models. If no models are installed, you can pull one using ollama pull . For example, ollama pull gemma4:latest.Install ollmcp via pip, add an MCP server, and run the client:
# Install ollmcp via uv
uv tool install --upgrade ollmcp
# or via pip
pip install --upgrade ollmcp
# Add an MCP server (example: playwright stdio server)
ollmcp mcp add playwright -- npx @playwright/mcp@latest
# Run the client (check optional flags with `ollmcp --help`)
ollmcp # once running, use /help for interactive commandsOption 1: Install with uv and run (recommended)
uv tool install --upgrade ollmcp
ollmcpOption 2: Install with pip and run
pip install --upgrade ollmcp
ollmcpOption 3: Only run without installing (requires uv package manager)
uvx ollmcpOption 4: Install from source and run using virtual environment
git clone https://github.com/jonigl/mcp-client-for-ollama.git
cd mcp-client-for-ollama
uv run -m mcp_client_for_ollamaCould not find a version that satisfies the requirement ollmcp (from versions: none)This almost always means the Python you are using is older than the required 3.11+. This is common on macOS, where the system Python (/usr/bin/python3) or the Xcode-bundled Python can be 3.9 or older. When no release matches requires-python >= 3.11, pip filters out every version and reports the misleading "from versions: none".
First check your version:
python3 --version # must be 3.11 or newerThen install with a modern Python. The simplest option is uv, which fetches a suitable Python for you automatically:
uv tool install --upgrade ollmcp # recommended, installs the CLI in an isolated environment
# or, if you prefer pip, make sure to use a Python 3.11+ interpreter:
python3.11 -m pip install --upgrade ollmcp
# Then run the client:
ollmcpTake a look at the Installation Options.
error: externally-managed-environment (PEP 668)On recent Debian/Ubuntu (Python 3.12+), the system pip is intentionally locked to protect OS-managed packages, so pip install ollmcp is blocked. This is a system policy (PEP 668), not an issue with ollmcp. Install it into an isolated environment instead:
uv tool install --upgrade ollmcp # recommended, installs the CLI in an isolated environment
# or, if you prefer pip, use a virtual environment:
python3.11 -m venv ollmcp-env
source ollmcp-env/bin/activate
python3.11 -m pip install --upgrade ollmcp
# Then run the client:
ollmcpTake a look at the Installation Options.
[!WARNING] Avoid
pip install --break-system-packages ollmcp. It works, but it installs into the system Python and can break packages your OS depends on.
ollmcp can manage its own MCP server configurations directly from the command line, similar to claude mcp:
# Remote servers (Streamable HTTP or SSE)
ollmcp mcp add --transport http
ollmcp mcp add --transport sse
# Local stdio servers - everything after `--` is the command to run
ollmcp mcp add [options] -- [args...]
# List configured servers
ollmcp mcp list
# Remove a server
ollmcp mcp remove
# For more details on options and usage, run:
ollmcp mcp --help
ollmcp mcp add --helpExamples:
[!TIP] Once you have added some servers, simply running
ollmcpwill connect to them automatically.
ollmcp mcp add --transport http github https://api.githubcopilot.com/mcp/ --header "Authorization: Bearer $YOUR_GITHUB_PAT"
ollmcp mcp add --transport stdio playwright npx @playwright/mcp@latest
ollmcp mcp add filesystem -- npx -y @modelcontextprotocol/server-filesystem /allowed-dir1 ~/allowed-dir2 # stdio transport by default
ollmcp mcp add --env API_KEY=YOUR_KEY --transport sse my-sse-server http://localhost:8000/sse--transport, -t: stdio (default), sse, or http.--header, -H: HTTP header as "Name: Value" for sse/http servers. Repeatable.No open issues yet, or sync has not completed.