Verified

Lsp MCP Server

Language Server Protocol integration for LLM-powered code analysis and suggestions.

Data last scanned yesterday · Reviewed last month

339 tools123TypeScriptMIT

Overview

This MCP server bridges the gap between AI models and the Language Server Protocol (LSP). By functioning as an intermediary, it allows your AI assistant to query hover information, retrieve code completions, and fetch diagnostic messages directly from your existing LSP providers. It manages document lifecycles through open and close commands, ensuring the LSP remains synchronized with your project files. The tool exposes a suite of utilities including `get_info_on_location` and `get_code_actions`, alongside real-time diagnostic resources. It supports runtime configuration of log levels and includes a console output system for monitoring interactions between the LSP server and your AI agent.

Our verdict

With a security score of 33/100, this server carries a high-risk rating. The primary concerns stem from it being a community-maintained project that has not received updates in over 372 days. Potential users should be aware that critical security aspects like OAuth support and read-only mode protocols have not yet been reviewed. Given the lack of active maintenance, it is best suited for experimental environments rather than sensitive or production codebases.

  • Supports comprehensive LSP features including diagnostics and code actions
  • Uses only 3 direct dependencies to minimize supply-chain surface area
  • Includes integration tests for TypeScript LSP operations
  • High-risk due to no commits in over a year
  • Community-maintained without official vendor support
  • Critical security integrations like OAuth remain unreviewed

Setup

Claude Desktop
{
  "mcpServers": {
    "lsp-mcp": {
      "args": [
        "-y",
        "lsp-mcp-server"
      ],
      "command": "npx"
    }
  }
}

Paste into ~/Library/Application Support/Claude/claude_desktop_config.json (macOS) or %APPDATA%\Claude\claude_desktop_config.json (Windows), then restart Claude Desktop. Some servers require API keys or tokens as environment variables — check the project's README and add an "env" object if needed.

  • No read-only mode — running this grants full read/write access.
  • No built-in authentication — anyone with access to this config can invoke every tool it exposes.

Tools

ToolDescriptionRisk
get_info_on_locationGet hover information at a specific location in a filelow
get_completionsGet completion suggestions at a specific location in a filelow
get_code_actionsGet code actions for a specific range in a filelow
open_documentOpen a file in the LSP server for analysismedium
close_documentClose a file in the LSP servermedium
get_diagnosticsGet diagnostic messages (errors, warnings) for open fileslow
start_lspStart the LSP server with a specified root directorymedium
restart_lsp_serverRestart the LSP server without restarting the MCP servermedium
set_log_levelChange the server's logging verbosity level at runtimelow

Compatibility

ClientLocalDockerRemoteRead-only
ChatGPT
Claude Desktop
Cursor
VS Code
Windsurf

Frequently asked questions

What are the prerequisite software requirements?

You need Node.js version 16 or later and npm installed to run the server.

Do I need to start the LSP server manually after connecting?

Yes, as of version 0.2.0, you must explicitly call the start_lsp tool with your project's root directory before any other LSP functionality will work.

How can I change the logging verbosity?

You can use the set_log_level tool at runtime to change the verbosity, or use the --mcp-debug flag when running your client to view full traffic.

What is the difference between MCP tools and resources in this server?

MCP tools perform active requests like retrieving completions or code actions, while MCP resources provide access to information like diagnostic messages with real-time subscription updates.

Can I restart the LSP server without restarting the MCP server itself?

Yes, the server includes a restart_lsp_server tool specifically for this purpose.

Alternatives

Badge

Lsp MCP Server security score, rated on RepoAI

Maintain this server? Add the live badge to your README.