Use /model in Kilo Code
Add /model to Kilo Code as a custom provider, in VS Code, in JetBrains or in its CLI.
Checked November 24, 2026
Kilo Code takes /model as a custom provider. In VS Code you add it in the extension's settings; the CLI and the JetBrains plugin read it from a config file.
Before you start
- A /model API key: create one on the API keys page and add credit on the credits page.
VS Code
- Open Kilo Code's settings with the gear icon and go to the Providers tab.
- At the bottom, choose Custom provider.
- Give it an id and a name, such as
slashmodel, and keep Provider API at OpenAI Compatible. - Set Base URL to the base URL below and API key to your /model key.
- Choose the models you want from the list Kilo Code loads from /model; Fetch models loads it again.
- Click Submit.
Base URL
https://api.slashmodel.com/v1The dialog doesn't ask for a model's limits. Add them in the config file below, which the extension reads too.
The config file: CLI, JetBrains and limits
Every Kilo Code client reads ~/.config/kilo/kilo.jsonc, or kilo.jsonc in a project. Put your key in the SLASHMODEL_API_KEY environment variable and add the provider:
{
"model": "slashmodel/claude-sonnet-5-5",
"provider": {
"slashmodel": {
"env": ["SLASHMODEL_API_KEY"],
"options": { "baseURL": "https://api.slashmodel.com/v1" },
"models": {
"claude-sonnet-5-5": { "name": "Claude Sonnet 5.5", "limit": { "context": 1000000, "output": 64000 } },
"claude-opus-5-5": { "name": "Claude Opus 5.5", "limit": { "context": 1000000, "output": 128000 } },
"gpt-6.1-sol": { "name": "GPT-6.1 Sol", "limit": { "context": 1050000, "output": 128000 } }
}
}
}
}- A model is then
slashmodel/followed by its id.kilo modelslists the ones Kilo Code found. Restart the CLI after you change the file. - Give each model its context window, from its page under Models. Without it Kilo Code can't tell when a long conversation needs shortening.
- Kilo Code asks for at most 32,000 tokens an answer, whatever the model's own limit.
- A custom model takes text only until you say otherwise: Kilo Code's documentation on custom models has the settings for images.
Claude in Anthropic's format
To send Claude requests in Anthropic's format, add a second custom provider, with an id of its own, Provider API set to Anthropic Messages and the same base URL, with /v1. Type the model ids there: that kind of provider doesn't load a list.