Get the FREE Ultimate OpenClaw Setup Guide →

cclsp

Claude Code LSP: enhance your Claude Code experience with non-IDE dependent LSP integration.

Installation
Run this command in your terminal to add the MCP server to Claude Code.
Run in terminal:
Command
claude mcp add --transport stdio ktnyt-cclsp cclsp \
  --env CCLSP_CONFIG_PATH="path/to/your/cclsp.json"

How to use

cclsp is an MCP server that bridges LLM-powered coding agents with LSP servers. It helps AI assistants navigate codebases by providing robust symbol resolution, go-to-definition, and find-references functionality across multiple languages. When run as an MCP server, it loads a configuration that maps language servers to your project and exposes MCP tools such as find_definition, find_references, rename_symbol, get_diagnostics, and more, enabling an AI agent to interact with language servers through MCP semantics. To use it, install the npm package and start the server, then configure your MCP client to point at the cclsp command and supply the path to your cclsp.json config via CCLSP_CONFIG_PATH. The server will coordinate with the appropriate language servers you’ve configured during setup and present unified results to the MCP client.

In practice, you will typically install cclsp globally, run the interactive setup to detect and configure language servers for your project, and then reference the tool from your Claude MCP client configuration. The MCP tools exposed by cclsp let you locate symbol definitions, gather all references, perform safe renames, and receive diagnostics from the underlying language servers, all while handling position and symbol resolution in a way that is friendly to LLMs.

How to install

Prerequisites:

  • Node.js 18+ (or Bun runtime)
  • Basic network access to install npm packages
  • A project with the language servers you want to use (or the ability to install them)

Installation steps:

  1. Install the cclsp package globally:
npm install -g cclsp
  1. Optional: run the interactive setup to auto-detect languages and generate a configuration:
npx cclsp@latest setup
  • Or, if you already have a configuration, you can generate it manually or place your cclsp.json in a desired location.
  1. Ensure a Claude MCP configuration points to cclsp. For example, in Claude MCP, use:
{
  "mcpServers": {
    "cclsp": {
      "command": "cclsp",
      "env": {
        "CCLSP_CONFIG_PATH": "/path/to/your/cclsp.json"
      }
    }
  }
}
  1. (Optional) If you prefer local execution without global install, you can run cclsp via node or a local path after building, depending on your setup.

Additional notes

Tips and troubleshooting:

  • Always set CCLSP_CONFIG_PATH to the path of your cclsp.json so the MCP server knows where to load its configuration.
  • Ensure Node.js 18+ (or Bun) is installed and the required language servers are installed as per the setup output.
  • If you modify the configuration, restart the MCP server to pick up changes.
  • Some editors or environments may require explicit path mappings for non-global installs; use absolute paths where possible.
  • The interactive setup can auto-detect languages and prompt for installation steps; use it to minimize manual configuration.
  • When using the MCP client, reference the cclsp server by its name (e.g., cclsp) and provide any necessary environment variables your setup requires.

Related MCP Servers

Sponsor this space

Reach thousands of developers