Skip to main content
Glama

mlx-mcp-server

MCP server bridging Claude Code and Claude Desktop to a locally-running LLM. Optimized for MLX LM on Apple Silicon, with support for any OpenAI-compatible backend (Ollama, LM Studio, etc.).

Install

pip install mlx-mcp-server

Setup

1. Start your local LLM

# Apple Silicon — MLX LM
mlx_lm.server --model mlx-community/Mistral-7B-Instruct-v0.3-4bit

# Intel Mac / Linux — Ollama
ollama serve && ollama pull mistral

2. Add to Claude Desktop

# MLX (Apple Silicon)
mlx-mcp-server install

# Ollama
mlx-mcp-server install --base-url http://localhost:11434 --model mistral

# Preview before writing
mlx-mcp-server install --dry-run

3. Add to Claude Code

mlx-mcp-server install --claude-code

Restart Claude Desktop / Claude Code after installing.

Tools

Tool

Description

chat

Send a message to your local model

quick_test

Run a diagnostic: hello, math, creative, or code_review

health_check

Check if the backend is reachable

list_models

List available models on the backend

Configuration

Set via environment variables (or the install command sets them automatically):

Variable

Default

Description

MLX_BASE_URL

http://localhost:8080

Backend URL

MLX_DEFAULT_MODEL

""

Model name — required for Ollama

MLX_API_KEY

""

API key for secured backends

MLX_TIMEOUT

30

Request timeout in seconds

Manual Claude Desktop config

If you prefer to edit the config file directly (~/Library/Application Support/Claude/claude_desktop_config.json on macOS):

{
  "mcpServers": {
    "mlx": {
      "command": "mlx-mcp-server",
      "env": {
        "MLX_BASE_URL": "http://localhost:8080",
        "MLX_DEFAULT_MODEL": ""
      }
    }
  }
}

Requirements

  • Python 3.11+

  • A running OpenAI-compatible LLM backend:

    • MLX LM (Apple Silicon, recommended)

    • Ollama (Intel Mac / Linux)

    • LM Studio or any other OpenAI-compatible server

License

MIT

Install Server
A
license - permissive license
A
quality
B
maintenance

Maintenance

Maintainers
Response time
Release cycle
Releases (12mo)
Commit activity

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/deresolution20/mlx-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server