MCP Directory

MCP Language Server

Gives MCP-enabled clients semantic code tools: definition, references, rename, diagnostics, and more.

Unverified
stdio (local)
No auth
Go

Add to your client

Copy the config for your MCP client and paste it into its config file.

Install / run
go install github.com/isaacphi/mcp-language-server@latest

Paste into ~/Library/Application Support/Claude/claude_desktop_config.json

{
  "mcpServers": {
    "mcp-language-server": {
      "command": "mcp-language-server",
      "args": [
        "--workspace",
        "/Users/you/dev/yourproject/",
        "--lsp",
        "gopls"
      ],
      "env": {
        "PATH": "/opt/homebrew/bin:/Users/you/go/bin",
        "GOPATH": "/users/you/go",
        "GOCACHE": "/users/you/Library/Caches/go-build",
        "GOMODCACHE": "/Users/you/go/pkg/mod"
      }
    }
  }
}

Step-by-step guides: Add to Claude Desktop · Add to Cursor · Add to Windsurf

Before you start

  • Go installed (https://golang.org/doc/install) to install the server via 'go install'
  • A language server installed and on PATH (e.g. gopls, rust-analyzer, pyright, typescript-language-server, or clangd)
  • The chosen language server must communicate over stdio

About MCP Language Server

An MCP server that runs and exposes a language server (LSP) to LLMs. It bridges MCP-enabled clients to real language servers such as gopls, rust-analyzer, pyright, typescript-language-server, and clangd, giving the model semantic tools like get definition, find references, rename symbol, hover, diagnostics, and reliable line-based file editing. You configure it with a workspace path and an --lsp executable; arguments after -- are passed through to the language server.

Tools & capabilities (6)

definition

Retrieves the complete source code definition of any symbol (function, type, constant, etc.) from your codebase.

references

Locates all usages and references of a symbol throughout the codebase.

diagnostics

Provides diagnostic information for a specific file, including warnings and errors.

hover

Displays documentation, type hints, or other hover information for a given location.

rename_symbol

Renames a symbol across a project.

edit_file

Allows making multiple text edits to a file based on line numbers. Provides a more reliable and context-economical way to edit files compared to search-and-replace based edit tools.

When to use it

  • Letting an LLM coding agent jump to a symbol's definition or list all its references in a large codebase
  • Renaming a symbol safely across an entire project
  • Surfacing compiler/type-checker diagnostics (errors and warnings) for a file to the model
  • Giving the model hover documentation and type hints for precise code understanding
  • Making reliable, line-based multi-edit changes to files

MCP Language Server FAQ

Is this a language server for MCP?

No. It is an MCP server that runs and exposes an existing LSP language server to LLMs, so MCP clients can use semantic code tools.

Which language servers are supported?

The author has tested gopls (Go), rust-analyzer (Rust), pyright (Python), typescript-language-server (TypeScript), and clangd (C/C++), but it should be compatible with many more. The only requirement is that the language server communicates over stdio.

How do I pass arguments to the underlying language server?

Any arguments placed after '--' in the args array are forwarded to the language server, and environment variables in 'env' are passed on to it as well.

How do I enable verbose logging?

Set the LOG_LEVEL environment variable to DEBUG to enable verbose logging to stderr, including messages to and from the language server.

Alternatives to MCP Language Server

Compare all alternatives →

Microsoft's official browser-automation MCP using Playwright's accessibility tree (no vision model).

Featured
Verified
stdio (local)
No auth
TypeScript
12 tools
Updated 13 days agoRepo

Up-to-date, version-specific library documentation injected into your coding agent.

Verified
stdio (local)
API key
TypeScript
2 tools
Updated 17 days agoRepo

LSP-powered coding agent toolkit: semantic symbol search, references and structural edits.

Verified
stdio (local)
No auth
Python
11 tools
Updated 15 days agoRepo