> For the complete documentation index, see [llms.txt](/llms.txt).
> Markdown versions of each page are available by appending .md to any URL.

# Models and usage in the {{WARP_CLI}}

Choose models in the {{WARP_CLI}}, bring your own API key, and track credit usage and per-response cost.

The Warp CLI gives you the same model options as the Warp app: pick the model that powers your conversations, bring your own provider API keys, route requests through custom model routers, and see what every response costs as you work.

## Choosing a model

Run `/model` to open the model picker. You can also click the model name in the footer to open the same picker.

The picker lists every model available to your account, with the active model preselected. Type to filter the list, press `↑` and `↓` to move through it, and press `Enter` to switch. Models that your plan or your team’s settings don’t allow appear in the list as disabled.

Your choice is saved as the base model of your active profile, so it persists across sessions. See [permissions and profiles](/cli/permissions-and-profiles/) for how profiles work in the CLI, and [Model choice](/agent-platform/inference/model-choice/) for the full list of supported models and how Warp’s Auto models pick one for you.

## Bring your own API key

The Warp CLI supports [Bring Your Own API Key (BYOK)](/agent-platform/inference/bring-your-own-api-key/) for OpenAI, Anthropic, and Google models. When you select a model covered by one of your keys, requests are billed through your provider account and don’t consume your Warp [credits](/support-and-community/plans-and-billing/credits/).

To store a key, run `/add-api-key` with one of `openai`, `anthropic`, or `google`:

```
/add-api-key anthropic
```

The CLI prompts for the key with masked input, so the key never appears in your transcript or shell history, and saves it to your device’s secure storage. Warp does not store provider keys on its servers.

To remove a stored key, run `/clear-provider-api-key` with the same provider name. Both commands are also available outside a session as the `--set-provider-api-key` and `--clear-provider-api-key` flags; see the [Warp CLI reference](/cli/reference/#command-line-flags).

Note

Warp’s built-in Auto models always consume Warp credits, even with BYOK configured. To bill through your own account, select a specific provider model, or use a [custom router](/agent-platform/inference/custom-routers/#using-your-own-api-keys-byok) whose targets your keys cover. See [BYOK usage and billing behavior](/agent-platform/inference/bring-your-own-api-key/#byok-usage-and-billing-behavior) for the full rules.

## Custom model routing

[Custom routers](/agent-platform/inference/custom-routers/) appear in the `/model` picker alongside individual models. Select one and each prompt resolves to a concrete model using the routing logic you defined.

The CLI loads the same router definitions as the Warp app: YAML files in `~/.warp/custom_model_routers/`, plus any team-synced routers your admin shares. See [authoring a router as a file](/agent-platform/inference/custom-routers/#author-a-router-as-a-file) for the file format.

## Usage and cost

The Warp CLI shows usage at two levels: a running total for the conversation, and a per-response breakdown.

-   **Conversation total** - Once a conversation has reported any usage, the footer shows its accumulated credits (for example, `2.5 credits`). Click the entry to switch between credits and the equivalent provider cost in dollars; the choice persists across sessions.
-   **Per-response details** - Run `/cost` to toggle a summary row under the latest response showing how long it took and how many credits it spent (for example, `12s • 1.2 credits`). The summary appears once the response finishes.

Credits are Warp’s unit of usage for agent requests. For what credits cover and how plans differ, see [Credits](/support-and-community/plans-and-billing/credits/).

## Related pages

-   [Model choice](/agent-platform/inference/model-choice/) - Supported models and how automatic model selection works.
-   [Bring Your Own API Key](/agent-platform/inference/bring-your-own-api-key/) - How BYOK works, key storage, and billing behavior.
-   [Custom routers](/agent-platform/inference/custom-routers/) - Define routing logic that picks a model per task.
-   [Warp CLI reference](/cli/reference/) - Flags and slash commands, including the API key commands.
