Get Started

Integrating the Pieces MCP with JetBrains IDEs brings your workflow context directly into IntelliJ IDEA, PyCharm, WebStorm, GoLand, and other JetBrains editors. The AI Assistant can access your past work, similar code, and historical context.

**Minimum version:** JetBrains 2025.2 or later is required for MCP support. SSE has limited/deprecated support—use Streamable HTTP for best results.

Prerequisites

There are two prerequisites for integrating Pieces with JetBrains as an MCP—an active instance of PiecesOS and the fully-enabled Long-Term Memory engine.

Make sure that PiecesOS is installed and running. This is *required* for the MCP server to communicate with your workflow data. Enable the Long-Term Memory Engine (LTM-2.7) through the Pieces Desktop App or the [PiecesOS Quick Menu](/products/core-dependencies/pieces-os/quick-menu) in your toolbar.

Installing PiecesOS & Configuring Permissions

Follow the instructions below for a detailed guide on setting up and configuring PiecesOS to correctly pass captured workflow context to the Pieces MCP server.

Setting Up JetBrains IDEs

JetBrains provides an MCP setup UI in Settings. You do not need to edit config files manually.

Setup via Settings UI

Go to **Settings** (`Cmd+,` on macOS, `Ctrl+Alt+S` on Windows/Linux). Go to **Tools > AI Assistant > Model Context Protocol (MCP)**. Click `+` (Add) to create a new server. In the **New MCP Server** dialog, enter the Pieces MCP URL: ```plaintext http://localhost:39300/model_context_protocol/2025-03-26/mcp ``` Select **Streamable HTTP** as the transport type. Optionally set a working directory. Click `OK` to apply your changes.

Brave Mode (Auto-Execute Tools)

By default, JetBrains prompts for confirmation before executing tools. To enable auto-execution:

Go to Settings > Tools > AI Assistant > MCP > Brave Mode = enabled

Use Brave Mode with caution in production environments.

Using Pieces MCP Server in JetBrains

Once integrated, you can utilize Pieces LTM directly in the AI Assistant panel.

Open the **AI Assistant** panel in your JetBrains IDE. Check that Pieces tools appear in the available tools list. Ask the AI Assistant to query your Pieces Long-Term Memory. For example: *"What was I working on yesterday?"* Check out this [MCP-specific prompting guide](/products/mcp/prompting) if you want to effectively utilize the Long-Term Memory Engine (LTM-2.7) with your new Pieces MCP server.

Updating

Go to Settings > Tools > AI Assistant > MCP, select the pieces server, click Edit, update the URL, and apply.

Troubleshooting

If you're experiencing issues integrating Pieces MCP with JetBrains:

  1. Verify PiecesOS Status: Ensure PiecesOS is actively running on your system.

  2. Update JetBrains: MCP support requires JetBrains 2025.2 or later. If the MCP option is not visible, update your IDE.

  3. Use Streamable HTTP: JetBrains has limited/deprecated SSE support. Use the Streamable HTTP endpoint (/model_context_protocol/2025-03-26/mcp).

  4. AI Not Using Tools Automatically: Enable Brave Mode in MCP settings if the AI is not executing tools automatically.


You're now set to enhance your JetBrains workflow with powerful context retrieval through Pieces MCP. Happy coding!