How to Integrate Claude With IntelliJ
IntelliJ IDEA doesn't ship with Claude support out of the box, but you can wire it in three practical ways: install an AI plugin that supports bring-your-own-key model providers (Continue.dev is the most reliable option), enable JetBrains AI Assistant's third-party provider setting if your license tier supports it, or call the Claude API directly from IntelliJ's built-in HTTP Client for testing and building your own tooling.
Which path you pick depends on what you actually want. If you want inline chat, code completion, and refactoring suggestions inside the editor, use a plugin. If you're building a feature that calls Claude from your own application and just want to test requests from inside the IDE, the HTTP Client is faster and doesn't require installing anything extra. Both paths need a working API key, and that's where a service like SubToAPI becomes useful if you want a single, team-manageable key instead of juggling raw credentials per developer.
Option 1: Continue.dev plugin
Continue.dev is an open-source AI coding assistant plugin available for the full JetBrains IDE family, including IntelliJ IDEA (Community and Ultimate). It supports custom model providers, which means you can point it at any Anthropic-compatible endpoint.
- Open Settings → Plugins, search for "Continue," and install it.
- Restart IntelliJ when prompted.
- Open the Continue sidebar (usually bound to a keyboard shortcut shown in the plugin's onboarding).
- Edit the plugin's
config.json(accessible from the gear icon in the sidebar) and add a model block:
{
"models": [
{
"title": "Claude via SubToAPI",
"provider": "anthropic",
"model": "claude-sonnet-4",
"apiKey": "sub_live_your_key_here",
"apiBase": "https://api.subtoapi.app/v1"
}
]
}
- Save the file and reload the plugin. You should now see Claude responses in the chat panel, inline edit suggestions, and code explanations pulled directly from your model.
This setup works whether you're calling Anthropic's API directly with your own key or routing through SubToAPI. The advantage of routing through SubToAPI is that the key is scoped to your application, shows up in a shared usage dashboard, and can be rotated or revoked per project without touching your personal Claude account.
Option 2: JetBrains AI Assistant with a custom provider
JetBrains AI Assistant is built into recent IntelliJ IDEA releases and supports configuring alternative model providers on some plans. If your version exposes this setting:
- Go to Settings → Tools → AI Assistant → Models.
- Look for a "Custom provider" or "Bring your own key" section.
- Enter your Anthropic-compatible base URL and API key.
- Save and switch the active chat model to the custom entry.
Availability of this option varies by JetBrains AI Assistant subscription tier and IDE version, so check your current plugin version before relying on it. If it's not available in your build, Continue.dev is the more consistent fallback.
Option 3: Built-in HTTP Client for direct API calls
IntelliJ's built-in HTTP Client (the same tool used for .http scratch files) is useful if you're not looking for an editor assistant but instead need to test Claude API calls while building a feature — for example, a code review bot, a documentation generator, or a support tool that uses Claude under the hood.
Create a file named claude-test.http:
POST https://api.subtoapi.app/v1/messages
Authorization: Bearer {{subtoapi_key}}
Content-Type: application/json
{
"model": "claude-sonnet-4",
"max_tokens": 512,
"messages": [
{"role": "user", "content": "Summarize this diff in two sentences."}
]
}
Set subtoapi_key in IntelliJ's HTTP Client environment file (http-client.env.json) so it's not hardcoded:
{
"dev": {
"subtoapi_key": "sub_live_your_key_here"
}
}
Run the request with the green arrow next to POST, and IntelliJ shows the response inline, including headers and timing. This is the fastest way to prototype a Claude-backed feature without leaving the IDE, and it's how most teams validate prompt structure before wiring it into actual application code.
Why route the key through SubToAPI
If you're integrating Claude into a plugin, a build tool, or a backend service that your IntelliJ project talks to, you generally don't want to hand every teammate a raw provider credential. SubToAPI turns your existing Claude access into a standard HTTPS API with sub_live_... application keys, streaming support, tool use, and usage metadata per key — so you can issue a separate key for local development, CI, and production without exposing account-level credentials.
Setup is the same regardless of which IntelliJ integration path you use: generate a key from the dashboard after signup, swap it into your config.json, .env, or http-client.env.json, and point requests at https://api.subtoapi.app/v1/messages. The quickstart covers the request format, and the streaming docs and tools docs are worth reading if your IntelliJ-based tooling needs partial responses or function calling. Pricing starts at €9/month for solo use, with team seats at €19 and €49 for larger usage tiers — see pricing for details.
questions
Does IntelliJ IDEA have native Claude support? Not out of the box. You need either a plugin like Continue.dev that supports custom model providers, JetBrains AI Assistant's third-party provider option (where available), or manual API calls via the built-in HTTP Client.
Can I use Claude for code completion in IntelliJ, not just chat? Yes, plugins like Continue.dev provide inline completion and edit suggestions in addition to chat, as long as the configured model supports it. Completion quality depends on the model you select, not the IDE itself.
Do I need a raw Anthropic API key, or can I use a service like SubToAPI? Either works, since both expose an Anthropic-compatible messages endpoint. SubToAPI is useful when you want scoped application keys, team-level usage visibility, and easier key rotation instead of sharing one account credential across a team. See the messages API docs for the request format.