# Lsp MCP

> Lsp MCP is an open-source MCP server for developer tools. MCP server giving AI assistants LSP code navigation and edits across 13 languages. It runs locally on your machine and is started by your AI client.

- **Kind:** MCP server
- **Pricing:** Open source
- **Platforms:** CLI, vscode, Linux, macOS, Windows, self-hosted
- **Repository:** https://github.com/theupsider/lsp-mcp
- **MCP Registry name:** io.github.theUpsider/lsp-mcp
- **Categories:** [developer tools](https://ai-powered.com/categories/developer-tools)
- **Listing updated:** 2026-11-18

## About

The README describes this as a bridge between language models and Language Server Protocol servers, so a model can ask a running language server for definitions, references, symbols, diagnostics and refactorings instead of guessing from raw text. It detects the language from project marker files such as package.json, Cargo.toml or go.mod and starts the matching server, running several servers side by side in one polyglot workspace.

Tools are exposed through a single language-independent interface, with each response carrying a readable text field plus the raw LSP payload. Read tools cover go-to-definition, references, type definitions, implementations, document and workspace symbols, and diagnostics; write tools cover rename, code actions, and document or range formatting.

The README says the server must run on the same machine as the source code, since the language servers need direct filesystem access. It is aimed at developers who use MCP-capable editors or agents on local or remote workspaces and want code intelligence without per-language setup.

## Features

- **Automatic language detection:** Scans the project root for language markers and selects matching language servers without manual configuration.
- **Read-side code intelligence:** Provides definition, reference, symbol, diagnostic and implementation lookups through LSP.
- **Write operations:** Offers rename, code actions and formatting tools that modify code through the language server.
- **Workspace persistence:** Remembers initialized workspaces and ready languages across server restarts.
- **Polyglot workspaces:** Runs multiple language servers at the same time within one project.
- **Hybrid responses:** Returns a human-readable text field alongside the raw LSP data.

## Good for

- Letting an AI agent jump to definitions and find references across a multi-language repository
- Applying automated renames or code actions through the language server rather than text search
- Pulling workspace diagnostics into an assistant's context before proposing fixes
- Searching symbols across a codebase from an MCP client

## Install

### Claude Code (Terminal)

```sh
claude mcp add lsp-mcp -- npx -y @theupsider/lsp-mcp
```

### Claude Desktop (claude_desktop_config.json)

```json
{
  "mcpServers": {
    "lsp-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@theupsider/lsp-mcp"
      ]
    }
  }
}
```

### Cursor (~/.cursor/mcp.json)

```json
{
  "mcpServers": {
    "lsp-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@theupsider/lsp-mcp"
      ]
    }
  }
}
```

### VS Code (.vscode/mcp.json)

```json
{
  "servers": {
    "lsp-mcp": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "@theupsider/lsp-mcp"
      ]
    }
  }
}
```

### Windsurf (~/.codeium/windsurf/mcp_config.json)

```json
{
  "mcpServers": {
    "lsp-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@theupsider/lsp-mcp"
      ]
    }
  }
}
```

### Other clients (your client's MCP settings (most use this shape))

```json
{
  "mcpServers": {
    "lsp-mcp": {
      "command": "npx",
      "args": [
        "-y",
        "@theupsider/lsp-mcp"
      ]
    }
  }
}
```

## FAQ

### How do I install it?

The README gives npm and bun global install commands for @theupsider/lsp-mcp, and a VS Code workspace .vscode/mcp.json example that runs it through npx.

### Which languages are supported?

The README lists 13 languages with their language servers, including Python, TypeScript, JavaScript, C#, Java, Go, Rust, C/C++, Ruby, PHP, Kotlin and Swift.

### Does it need to run on the same machine as my code?

Yes. The README says the language servers need direct filesystem access, so they cannot work over a remote connection or on a different machine than the source files.

### Is Lsp MCP free?

Yes. Lsp MCP is open source, so you can use and self-host it for free.

### How do I add Lsp MCP to Claude Code?

Run this command in your terminal: claude mcp add lsp-mcp -- npx -y @theupsider/lsp-mcp

### What are the best alternatives to Lsp MCP?

The closest alternatives to Lsp MCP are Lens MCP, Gopls MCP, Codelens MCP, Llmmcp and LingoHub MCP by usefulapi.

## Where this comes from

- Description: written from the project's README and its MCP Registry entry.
- Install steps: from the official MCP Registry entry.

## Alternatives

- [Lens MCP](https://ai-powered.com/mcp/lens-mcp-2): Lens MCP is an open-source MCP server for developer tools.
- [Gopls MCP](https://ai-powered.com/mcp/gopls-mcp): Gopls MCP is an open-source MCP server for developer tools.
- [Codelens MCP](https://ai-powered.com/mcp/codelens-mcp): Codelens MCP is an open-source MCP server for developer tools.
- [Llmmcp](https://ai-powered.com/mcp/llmmcp): Llmmcp is an open-source MCP server for developer tools.
- [LingoHub MCP by usefulapi](https://ai-powered.com/mcp/lingohub-mcp-by-usefulapi): LingoHub MCP by usefulapi is a freemium MCP server for developer tools.
- [awesome-mcp-servers](https://ai-powered.com/mcp/awesome-mcp-servers-2): awesome-mcp-servers is an open-source MCP server for developer tools.
- [MCP-Bridge](https://ai-powered.com/mcp/mcp-bridge-2): MCP-Bridge is an open-source MCP server for ai models and llm tooling.
- [Localazy MCP by usefulapi](https://ai-powered.com/mcp/localazy-mcp-by-usefulapi): Localazy MCP by usefulapi is a freemium MCP server for developer tools.

---
Source: https://ai-powered.com/mcp/lsp-mcp
