Claude Code in Cursor: setup, models, and checks
Run the Claude Code extension inside Cursor with one AI in IDE API key, while keeping Cursor's own AI features and billing separate.
Cursor is a VS Code fork, so the extension and the settings file are the same as in VS Code. What differs is Cursor's extension registry, its settings sync, and its built-in AI. The full reference is Claude Code in Cursor; this page is the condensed path.
Setup at a glance
- Check the Cursor build. Cursor → About Cursor shows the VS Code base; it must be 1.94.0 or later.
- Install the extension. Use the direct link,
Cmd+Shift+X/Ctrl+Shift+Xand search Claude Code, or install from Open VSX Registry when Cursor's marketplace view is filtered. Run Developer: Reload Window if the Spark icon does not appear. - Create the API key. Open API Keys, create a key, and choose AWSQ or CCMAX. A Codex or Gemini key authenticates against a different endpoint and fails here.
- Write the connection settings. Create or merge
~/.claude/settings.json(macOS/Linux) orC:/Users/<UserName>/.claude/settings.json(Windows):
1 {2 "$schema": "https://json.schemastore.org/claude-code-settings.json",3 "env": {4 "ANTHROPIC_BASE_URL": "https://api.aiinide.com",5 "ANTHROPIC_AUTH_TOKEN": "YOUR_DASHBOARD_API_KEY",6 "API_TIMEOUT_MS": "600000",7 "CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC": "1"8 }9 }
Keep the base URL at the bare host. Cursor and the CLI both read this file, and it survives Cursor updates, profile switches, and window reloads.
- Disable the sign-in prompt. Add
"claudeCode.disableLoginPrompt": trueto Cursor's usersettings.json. - Verify. Call
GET /v1/modelswith your key andanthropic-version: 2023-06-01; 200 lists models, 401 means a bad key, 400 means another channel. Then open the panel, run/status, and send a short prompt. Check Usage against that key.
What differs inside Cursor
- Two panels, two billing paths. Cursor's built-in chat and tab completion are separate products and do not share this key. Cursor's own Claude access is billed by Cursor; the Claude Code panel is billed by AI in IDE against your key quota. Use one consistently per task or usage data will look wrong in both dashboards.
- Profile settings can disappear. Cursor stores extension settings in its own profile, and a profile switch can silently drop
claudeCode.*values. Re-check after switching. - Proxy settings are separate. Cursor's HTTP proxy and
HTTPS_PROXYare configured separately, so one AI client can work while the other fails. - Updates can reset the extension. If the extension disappears after a Cursor update, reinstall it from the Extensions view and re-add the
claudeCode.*settings. - Indexing competes for resources. A very slow first response that becomes normal later usually means Cursor's indexer is saturating CPU and network.
Supported models
| Model | Channel | Best for |
|---|---|---|
claude-opus-5-5 (alias claude-opus-5.5) | AWSQ, CCMAX | complex refactors, long autonomous runs |
claude-sonnet-5-5 (alias claude-sonnet-5.5) | AWSQ, CCMAX | the everyday default |
claude-haiku-4-5-20251001 | AWSQ, CCMAX | quick edits, cheap checks |
Leave model out to use the picker, or switch with /model. Use an exact ID from GET /v1/models; a mistyped claude-* name can resolve to the default Claude model and incur charges at that model's rate. Plans and current rates are on pricing.
Troubleshooting essentials
API Error: 404—ANTHROPIC_BASE_URLincludes/v1. Use the bare host.API Error: 400— Cursor installed a stale build, orsettings.jsonis malformed. Cursor ignores a broken file without warning; open it in Cursor so the$schemaline surfaces validation errors.- Sign-in still appears — sign out with
/logout, setdisableLoginPrompt, then reload. - An old token wins — run
echo $ANTHROPIC_AUTH_TOKENin Cursor's integrated terminal. If it prints an old value, that one takes precedence.
FAQ
Is the extension officially supported in Cursor?
Anthropic publishes it to the Visual Studio Marketplace and Open VSX and documents Cursor as a supported install target. Installs still go through a marketplace Anthropic does not operate.
Should I install both Cursor's Claude access and this extension?
Only if you want both billing paths. For consistent usage numbers, pick one and use it for a task.
Can I reuse my VS Code key and settings?
Yes. Cursor runs the same extension, so the same key, settings.json, and claudeCode.* settings apply. The differences are Cursor's profile handling and its separate AI features.
Does Cursor's tab completion use this key?
No. Cursor's built-in AI and the Claude Code extension are separate products with separate billing.