Cursor Configuration
Configure Any API in Cursor to use AI coding features.
Recommendation
We recommend using VS Code + Continue for a better experience. Continue is a free, open-source AI coding assistant that integrates perfectly with VS Code. View Continue Configuration
Step 1: Install Cursor
- Visit https://cursor.com to download the installer for your system
- Install and open Cursor
Step 2: Configure API
Configure through the settings interface:
- Open Cursor Settings: click the gear icon in the top-right corner, or press
Ctrl+Shift+J(Mac:Cmd+Shift+J) - Select "Models" in the left navigation
- Scroll down to the "OpenAI API Key" section
- Fill in the following:
- OpenAI API Key: Enter your API key
- Enable Override OpenAI Base URL:
https://anyapi.pro
- Click "Verify" to test the connection
- Check the models you want to use in the model list above
WARNING
After configuration, we recommend disabling Cursor's built-in cloud models (uncheck them) on the Models page to use only your custom API and avoid extra charges.
Step 3: Start Using
| Feature | Shortcut (Windows/Linux) | Shortcut (Mac) | Description |
|---|---|---|---|
| Inline Generate/Edit | Ctrl+K | Cmd+K | Generate or edit code directly in the editor |
| AI Chat Panel | Ctrl+L | Cmd+L | Open the AI chat panel on the right |
| Composer Mode | Ctrl+I | Cmd+I | Make changes across multiple files |
| Context Menu | — | — | Select code, right-click for AI options |
| Code Completion | Tab | Tab | Accept auto-completion suggestions |
