The JetBrains plugin brings Claude Code into IntelliJ IDEA, PyCharm, WebStorm, GoLand, and other JetBrains IDEs. Like the VS Code extension, it is a graphical layer on the same CLI session. The terminal still runs the model.
Install the plugin
- Open Settings (Cmd+, on Mac, Ctrl+Alt+S on Windows/Linux)
- Go to Plugins
- Search “Claude Code”
- Install and restart the IDE
Or install from the command line if you have the JetBrains CLI:
jetbrains plugin install com.anthropic.claude-code
Open the panel
Cmd+Esc (Mac) or Ctrl+Esc (Windows/Linux) opens the Claude Code panel. Same shortcut closes it or returns focus to the editor.
Insert file and selection references
Place your cursor in a file or select a code range, then press Cmd+Option+K (Mac) or Ctrl+Alt+K (Windows/Linux). This inserts an @-mention into the Claude Code input:
@src/payments/processor.kt#42-67
Claude sees the exact range you selected without you copying and pasting.
Connect from an external terminal using /ide
If you run Claude Code in a standalone terminal (iTerm2, Windows Terminal, etc.) rather than the embedded JetBrains terminal, you can still connect to the IDE:
/ide
Running /ide from any Claude Code session connects it to the running JetBrains IDE’s MCP server. Claude can then call mcp__ide__getDiagnostics to read live errors from the IDE’s language server without running a build in the shell.
The IDE must be open and the plugin installed for /ide to find it. If multiple JetBrains IDEs are running, /ide prompts you to choose.
Configure in Settings
Go to Settings > Tools > Claude Code [Beta] to:
- Set the default working directory for new sessions
- Configure permission prompts (automatic vs manual)
- Enable or disable the plugin per project
WSL2: fix the firewall
On Windows with WSL2, the IDE MCP server binds to a random TCP port on the Windows host. WSL2’s firewall blocks inbound connections to that port by default.
Fix it by adding a Windows Firewall rule. In an elevated PowerShell:
New-NetFirewallRule -DisplayName "Claude Code IDE MCP" -Direction Inbound -Protocol TCP -LocalPort 32000-35000 -Action Allow
Adjust the port range to match what the plugin actually uses. Check the plugin logs under Help > Show Log to find the exact port.
Without this rule, /ide from a WSL2 terminal will time out or fail silently.
Remote development (SSH / Dev Container)
JetBrains remote development runs the IDE backend on the remote host and streams the UI to your local machine. Claude Code must be installed on the remote host, not the local one.
# SSH into the remote host and install:
curl -fsSL https://storage.googleapis.com/claude-code-releases/latest/install.sh | bash
After installation on the remote side, the plugin finds the CLI automatically. If you installed Claude Code only locally, the plugin will not work in remote dev sessions.
Footguns
The IDE MCP server starts on a random port per session. Do not hardcode this port anywhere. Use the mcp__ide__* tool name in hook matchers rather than relying on port-based identification.
Cmd+Esc conflicts with system shortcuts on some macOS configurations. If the shortcut does not work, check System Settings > Keyboard > Keyboard Shortcuts for conflicts. Remap either the system shortcut or the plugin shortcut.
The embedded terminal and the panel are independent sessions. Running claude in the JetBrains embedded terminal does not connect it to the panel. If you start a session in the embedded terminal and open the panel, you have two separate sessions.
Plugin updates can reset the Settings > Tools > Claude Code pane. After a plugin update, verify your configured working directory and permission settings are intact.
When NOT to use the JetBrains plugin
- You need
/mcp,/plugin, or/resume. These open interactive terminal pickers that do not render in the panel. Run the CLI directly. - You work exclusively in the terminal. The plugin adds overhead without benefit if you never look at the panel.
- You are on a remote server without a JetBrains license for remote development. The plugin requires the IDE’s remote backend, which needs a valid license.