Skip to main content
Glama
gierdo

nvim-editor-mcp

by gierdo

nvim-editor-mcp

MCP server bridging tool calls to Neovim editor actions via RPC.

Exposes Neovim operations (open files, run Lua, diagnostics, quickfix, notifications) as Model Context Protocol tools, so AI agents can drive your editor.

Installation

Requires uv and Python ≥ 3.11.

uv tool install .

This puts nvim-editor-mcp on your PATH.

Related MCP server: LSP-MCP

Usage

nvim-editor-mcp auto-discovers the socket from the $NVIM env var, which is set when the mcp is started from nvim, e.g. through codecompanion

nvim-editor-mcp

# Explicit socket path
nvim-editor-mcp --socket /tmp/nvim.sock

The server starts in stdio MCP mode. If no socket is given and $NVIM is unset, it starts anyway and discovers the socket on the first tool call (via attach_nvim).

Tools

Tool

Description

attach_nvim

Connect to a Neovim instance by socket path

open_file

Open a file at a specific line

set_quickfix

Populate the quickfix list

get_diagnostics

Fetch LSP diagnostics

nvim_exec_lua

Execute arbitrary Lua in Neovim

notify

Show a notification in Neovim

MCP client configuration

{
  "mcpServers": {
    "nvim-editor-mcp": {
      "command": "nvim-editor-mcp"
    }
  }
}

Development

Setup

uv sync

This creates a .venv and installs all runtime + dev dependencies.

Linting & formatting

uv run ruff check .
uv run ruff format .

Type checking

uv run ty check

Tests

uv run pytest

All checks (CI-style)

uv run ruff check . && uv run ruff format --check . && uv run ty check && uv run pytest

License

GPL-2.0

A
license - permissive license
-
quality - not tested
C
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.

Related MCP Servers

View all related MCP servers

Related MCP Connectors

  • Markdown-first MCP server for Notion API with 8 composite tools and 39 actions.

  • A comprehensive Model Context Protocol (MCP) server that enables AI assistants to interact with yo…

  • MCP server for AI dialogue using various LLM models via AceDataCloud

View all MCP Connectors

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/gierdo/nvim-editor-mcp'

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