emacsclient-mcp
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@emacsclient-mcpinsert "Hello, world!" at point"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
emacsclient-mcp
Emacs MCP server + Pi extension — 22 Emacs tools for LLM-assisted editing, search, buffer management, and PR review.
What is this?
A Model Context Protocol (MCP) server that gives LLMs direct access to Emacs — no emacsclient binary needed. It communicates via Unix socket using the Emacs server protocol, implementing &-quoting as defined in emacsclient.c and server.el.
Comes with:
Rust MCP binary — 22 tools over JSON-RPC stdio
Pi extension — auto-spawns the binary, registers all tools
PR review agent — 4-phase workflow (Setup → Analysis → Issues → Report)
Related MCP server: email-send-mcp
Quick Start
1. Install
# Option A: Pi package (recommended — gets extension + agent)
pi install npm:@bimawa/emacsclient-mcp
# Option B: Rust binary only (for other MCP clients)
cargo install emacsclient-mcp
# Option C: Homebrew (macOS)
brew install bimawa/tap/emacsclient-mcp2. Start Emacs server
M-x server-start
;; or:
emacs --daemon3. Reload Pi
/reloadPi picks up the extension, spawns the binary, discovers 22 Emacs tools, and registers the emacs-pr-review agent.
Tools
Category | Tools |
Eval |
|
Buffers |
|
Navigation |
|
Search |
|
Editing |
|
Windows |
|
PR Review Agent
Activate with /agent emacs-pr-review in Pi. The agent:
Setup — gets the diff, opens review buffer in
org-mode, splits Emacs windowsAnalysis — reads each changed file, applies review heuristics (R1–R4)
Findings — documents issues by severity: BLOCKER / CRITICAL / WARNING / SUGGESTION
Report — shows summary in Emacs, offers inline comments
Protocol
Implements the exact Emacs server protocol from server.el:
Client sends first (no server greeting)
Single-line commands:
-auth KEY -eval EXPR\n&-quoting: spaces →&_, newlines →&n, leading-→&-,&→&&Response:
-emacs-pid PID\n-print RESULT\n
Binary Resolution
The extension finds the binary in this order:
EMACS_MCP_BINARYenvironment variablePre-built binary alongside the extension (package distro)
~/.cargo/bin/emacsclient-mcp(cargo install)which emacsclient-mcp(PATH / Homebrew)cargo run --release(dev mode)
Development
# Build the Rust binary
cargo build --release
# Run locally with Pi
pi -e ./extension/index.ts
# Test the MCP binary directly
echo '{"jsonrpc":"2.0","id":1,"method":"initialize",...}' | ./target/release/emacsclient-mcpLicense
MIT © bimawa
This server cannot be deployed
Maintenance
Related MCP Connectors
The Remote MCP server acts as a standardized bridge between LLM applications (like Claude, ChatGPT, and Cursor) and external services, enabling AI agents to access external tools and resources. Its primary capability is providing a centralized search tool to discover other MCP servers and their respective tools. Unlike local implementations, it runs remotely with OAuth authentication and permission controls for security.
The OpenRouter MCP server plugs OpenRouter into the AI tools you already use. Once connected, your assistant can pull live OpenRouter data (models, prices, your credits, rankings, and docs) and send quick test messages, all without leaving your editor.
MCP server connecting AI agents to 100+ apps (Gmail, Slack, Notion, GitHub) via one-click OAuth.
A comprehensive Model Context Protocol (MCP) server that enables AI assistants to interact with yo…
Related MCP Servers
- AlicenseAqualityBmaintenanceA comprehensive MCP server providing tools for AI agents to interact with code, including reading symbols, importing modules, replacing text, and sending OS notifications.310 npm10MIT
- AlicenseBqualityDmaintenanceAn MCP server that enables LLMs to compose and send emails with attachments, and search for files in directories by pattern.25MIT
- FlicenseCqualityCmaintenanceA security-first MCP server that provides LLMs with structured tools for filesystem, process, search, build/test/lint, IDE integration, and more.402-
- FlicenseAqualityDmaintenanceA universal MCP server that provides AI agents with structured tools for filesystem, database, shell, and git operations, enabling seamless interaction with projects.19-