Overview
JetBrains IDEs provide a built-in MCP (Model Context Protocol) Server that allows external AI clients (such as Claude Desktop) to securely connect to your IDE and interact with your project.
This enables AI clients to:
- Access project context (files, structure, etc.)
- Execute supported IDE-side tools
- Provide more accurate, context-aware assistance
For a full list of currently supported MCP tools, see: MCP Available Tools.
For complete documentation and general information about the feature, see the MCP Server page.
Enabling the MCP Server in the IDE
- Open your JetBrains IDE
- Go to Settings | Tools | MCP Server
- Enable MCP Server
Once enabled, the IDE will start a local server.
How port assignment works
The IDE automatically finds the next available port, starting from 64342.
If the default port is already in use, the IDE selects the next available port (for example, 64343, 64344, and so on). The assigned port is reused in future sessions.
As of January 2026, the MCP server port is not user-configurable. Support for custom port configuration is tracked under Configurable MCP Server Port.
How to configure Claude Desktop
Claude Desktop can be configured for a single IDE instance or for multiple IDE instances.
Single IDE instance configuration
- In the IDE, go to Settings | Tools | MCP Server
- Under Claude App click Auto-Configure
For Claude Desktop this creates or updates the claude_desktop_config.json file. To open this file from the IDE, expand the Auto-configure menu and select Open Client Settings File.
Multiple IDE instances configuration
By default, Auto-Configure action creates a server entry named jetbrains in claude_desktop_config.json.
Since all IDE instances use the same configuration file, running Auto-Configure in another IDE will overwrite the existing jetbrains entry unless it has been renamed. To connect multiple IDEs to Claude, each must use a unique server name.
Support for configuring a custom server name is tracked under Configurable MCP server name. Until this is implemented, the server names must be adjusted manually:
-
Disable the MCP Server in all IDEs
-
In the first IDE, enable the MCP Server and click Auto-Configure
-
Open
claude_desktop_config.json, rename thejetbrainsentry to a unique name, and save the file -
In each additional IDE, repeat steps 2–3
The goal is to ensure that each IDE has a unique MCP Server name before enabling the next one. This ensures all server entries remain in the configuration file, allowing Claude to connect to all IDE instances simultaneously.
Verifying the connection in Claude Desktop
- Open Claude Desktop
- Go to Settings | Developer
All servers defined in claude_desktop_config.json are listed on this page, along with their current status (running, failed). If the status is running, Claude is successfully connected to your IDE and can execute all supported MCP tools in it.
Comments
0 comments
Please sign in to leave a comment.