Connect Claude API to Windsurf
Setup takes a few minutes. Windsurf sends requests through the Claude API Tech OpenAI-compatible endpoint, and usage appears in your dashboard.
Windsurf, formerly Codeium, is an AI IDE with the Cascade agent. This guide applies to versions that expose an OpenAI Compatible or Custom Provider option.
Official Windsurf website ↗Time
2 to 3 minutes
Provider
OpenAI Compatible
Authentication
API key
Before you start
- Create a Claude API Tech key or open an existing key.
- Update Windsurf if OpenAI Compatible or Custom Provider is missing from Settings.
- Do not put the API key in your repository, project settings.json, or a public screenshot.
Configuration
Open Settings
Press Cmd + , on macOS or Ctrl + , on Windows and Linux. You can also open Settings from the gear icon in the bottom-left corner.
Find the AI provider
Search Settings for AI or API. Open the provider section and select OpenAI Compatible. If that option is not present, look for Custom Provider with Base URL and API Key fields.
Enter the endpoint and key
Copy the Base URL exactly as shown. Paste the key from your dashboard into API Key. A leading or trailing space causes authentication to fail.
Values for Windsurf
Windsurf
Save and test
Apply the settings and quit Windsurf completely. Open it again, launch Cascade in any project, and send a short test request.
Alternative: settings.json
You can also configure Windsurf manually through its settings.json file:
{
"ai.provider": "openai-compatible",
"ai.baseUrl": "https://api.llm-gate.tech/v1",
"ai.apiKey": "sk-cs2-YOUR_API_KEY"
}Confirm the connection
The connection is ready when all three checks pass:
Cascade responds
The test request completes without a provider error.
Usage appears
The request is visible in your Claude API Tech dashboard.
The model resolves
The response has no unknown model or model not found error.
If the connection fails
| Symptom | What to check |
|---|---|
| 401 or 403 | Copy the API key again and remove whitespace. |
| 404 or endpoint error | The Base URL must be exactly https://api.llm-gate.tech/v1. |
| Unknown model | Select an exact ID from the supported model list. |
| Settings were ignored | Quit Windsurf completely and open it again. |
| Custom Provider is missing | Update Windsurf and check whether your version or account exposes this option. |