# Run Claude Code for less

Updated November 14, 2026

Point Claude Code at **OpenCheap** with three environment variables and you choose the model per task, on one key with a spend limit. Claude models go to their cheapest provider: Claude Opus 5.5 costs 45 % less than its list price here right now. Claude Opus 5.5 is 45 % below list, Claude Sonnet 5.5 is 10 % below list, Claude Sonnet 5 is 45 % below list, Claude Opus 5 is 45 % below list, Claude Haiku 5.5 is 25 % below list. The bigger saving is the model: open coding models such as Kimi K3, Kimi K2.7 Code and GLM 5.3 cost a fraction of Claude Sonnet 5.5's price per token. Claude Code works with all of them, because OpenCheap answers Anthropic's Messages API for every model.

[Get API key](https://opencheap.si/start?onboarding=signin)

**5** Claude models, at the cheapest provider's price

**7** coding models below Claude Sonnet 5.5's price

**3** environment variables to switch

## Set up Claude Code in a minute

In your shell profile, or under "env" in ~/.claude/settings.json. The base URL has no /v1: Claude Code adds /v1/messages itself.

shell

```
export ANTHROPIC_BASE_URL=https://api.opencheap.si
export ANTHROPIC_API_KEY=<your OpenCheap key>
export ANTHROPIC_MODEL=claude-sonnet-5.5

# Optional: a cheaper model for background work and subagents
export ANTHROPIC_DEFAULT_HAIKU_MODEL=claude-haiku-5.5
export CLAUDE_CODE_SUBAGENT_MODEL=kimi-k3
```

~/.claude/settings.json

```
{
  "env": {
    "ANTHROPIC_BASE_URL": "https://api.opencheap.si",
    "ANTHROPIC_API_KEY": "<your OpenCheap key>",
    "ANTHROPIC_MODEL": "kimi-k3"
  }
}
```

The console's setup page shows the same lines with your key filled in. Codex and Cursor are in the [quickstart](https://docs.opencheap.si/quickstart).

## Claude models, live

Our price per million input and output tokens, as of 2026-12-04 11:48 UTC, and how it compares with each model's list price.

| Model | OpenCheap / 1M in · out | Versus list |
| --- | --- | --- |
| [Claude Opus 5.5](https://opencheap.si/models/claude-opus-5.5) | $2.20 · $11.00 | 45 % below list |
| [Claude Sonnet 5.5](https://opencheap.si/models/claude-sonnet-5.5) | $1.80 · $9.00 | 10 % below list |
| [Claude Sonnet 5](https://opencheap.si/models/claude-sonnet-5) | $1.10 · $5.50 | 45 % below list |
| [Claude Opus 5](https://opencheap.si/models/claude-opus-5) | $2.75 · $13.75 | 45 % below list |
| [Claude Haiku 5.5](https://opencheap.si/models/claude-haiku-5.5) | $0.075 · $0.375 | 25 % below list |

## Cheaper models that run Claude Code

Coding models you can set as ANTHROPIC_MODEL or for subagents, cheapest first. The share compares the price per token with Claude Sonnet 5.5's on a 1 : 3 input : output blend; it says nothing about quality.

| Model | OpenCheap / 1M in · out | Share of Claude Sonnet 5.5's price |
| --- | --- | --- |
| [GLM 5.3](https://opencheap.si/models/glm-5.3) | $0.121 · $0.037 | under 1 % |
| [Qwen 3 Coder 480B](https://opencheap.si/models/qwen3-coder) | $0.075 · $0.250 | 3 % |
| [DeepSeek V4 Pro](https://opencheap.si/models/deepseek-v4-pro) | $0.396 · $0.792 | 10 % |
| [MiniMax M3](https://opencheap.si/models/minimax-m3) | $0.241 · $1.01 | 11 % |
| [Kimi K2.7 Code](https://opencheap.si/models/kimi-k2.7-code) | $0.249 · $1.08 | 12 % |
| [Kimi K3](https://opencheap.si/models/kimi-k3) | $1.57 · $0.945 | 15 % |
| [Gemini 3.5 Flash](https://opencheap.si/models/gemini-3.5-flash) | $1.50 · $9.00 | 99 % |

## Three ways to spend less

1. **Pay the cheapest provider for Claude** Every request goes to the cheapest healthy provider of the model, and every answer reports what it cost in usage.cost.
2. **Use a cheaper model where Claude is not needed** Keep Claude for planning and hard edits, and set a cheaper model for background calls and subagents, or for whole sessions on routine work.
3. **Cap the key** A daily limit on the key Claude Code uses stops it at the amount you choose. See [spend limits per key](https://opencheap.si/guides/llm-api-spend-limits).

Claude Code also reads `ANTHROPIC_DEFAULT_OPUS_MODEL` and `ANTHROPIC_DEFAULT_SONNET_MODEL`, so the opus and sonnet aliases can point at any model you choose.

## Questions, answered

### Can I run Claude Code with a cheaper model?

Yes. Claude Code reads ANTHROPIC_BASE_URL, ANTHROPIC_API_KEY and ANTHROPIC_MODEL. Point them at OpenCheap (https://api.opencheap.si, your key, and a model id) and Claude Code runs on that model: Claude, GPT, Gemini, or an open coding model such as Kimi K3, GLM or DeepSeek.

### Is Claude Opus cheaper on OpenCheap?

Claude Opus 5.5 costs 45 % less than its list price here right now. Claude Opus 5.5 is 45 % below list, Claude Sonnet 5.5 is 10 % below list, Claude Sonnet 5 is 45 % below list, Claude Opus 5 is 45 % below list, Claude Haiku 5.5 is 25 % below list. Each request goes to the cheapest provider of the model, so when a provider prices it lower, you pay that.

### Will Claude Code work with non-Claude models?

Yes. OpenCheap answers Anthropic's Messages API for every chat model, so Claude Code's requests, streaming and tool calls reach the model you set. How well a model handles Claude Code's tools and long sessions varies by model: try it on a real task before you switch a whole team.

### Can I keep Claude for the hard parts and a cheap model for the rest?

Yes. Claude Code takes a model per role: ANTHROPIC_MODEL for the session, ANTHROPIC_DEFAULT_HAIKU_MODEL for the small background calls, CLAUDE_CODE_SUBAGENT_MODEL for subagents (Claude Code's docs as of November 14, 2026). Any OpenCheap model id works in each, and /model switches mid-session.

### Is a Claude subscription cheaper than paying per token?

It can be. With a Claude Pro or Max plan, Claude Code's usage is part of the plan; through an API key you pay per token. Per token wins when you use cheaper models, use Claude Code unevenly, or need it inside agents and CI with a spend limit.

### How do I stop Claude Code from spending too much?

Give the key it uses a daily limit that refuses requests once reached. See the spend limits guide; the limit covers every model the key calls.

## More guides

- [Cheapest LLM API (Live Prices, Updated Daily)](https://opencheap.si/guides/cheapest-llm-api): Live prices per 1M tokens for popular models, routed to the cheapest healthy provider. One OpenAI-compatible key. Pay as you go; no monthly fee.
- [A cheaper DeepSeek API, with official prices side by side](https://opencheap.si/guides/cheapest-deepseek-api): Official DeepSeek API prices next to live OpenCheap rates for V4.1 Flash, V4 Pro and other DeepSeek models. One OpenAI-compatible key. Prices move; the tables are dated.
- [An LLM router that sends each request to the cheapest provider](https://opencheap.si/guides/cheapest-llm-router): OpenCheap routes each request to the cheapest healthy provider of your model, fails over before the first byte, and bills that provider's price.
- [One API key for all AI models](https://opencheap.si/guides/openai-compatible-api): One OpenCheap key calls Anthropic, Google, OpenAI, DeepSeek, Moonshot, Qwen and more through the OpenAI SDK: change the base URL and the key.
- [Pay for LLM API calls with USDC, without an account or an API key](https://opencheap.si/guides/pay-for-llm-api-with-usdc): An AI agent can pay OpenCheap for one completion in USDC on Base with x402: call with no key, read the 402 price, sign, and get the answer in the same request.
- [Set a daily spend limit on each API key your agents use](https://opencheap.si/guides/llm-api-spend-limits): Give each OpenCheap key a daily, weekly, monthly or lifetime spend limit, so an agent left running overnight can't spend more than you allow.
- [Connect Cursor, LiteLLM or the OpenAI SDK with the base URL](https://opencheap.si/guides/cursor-litellm-openai-sdk): Connect Cursor, LiteLLM and the OpenAI SDK to OpenCheap with a base URL, a key and a model id. Steps, env variables, code and common errors.
- [OpenCheap vs OpenRouter for cheapest pricing and failover](https://opencheap.si/guides/opencheap-vs-openrouter): OpenCheap routes to the cheapest provider by default; OpenRouter balances price, speed and uptime. Compare live prices, failover and fees.
- [A cheap Claude API, with official prices side by side](https://opencheap.si/guides/cheapest-claude-api): Anthropic's list prices next to live OpenCheap rates for Claude. One OpenAI-compatible key. Prices move; both tables are dated.
- [GPT API pricing, and the cheapest way to call it](https://opencheap.si/guides/cheapest-gpt-api): GPT API pricing per 1M tokens: OpenAI's list rates for GPT-6, GPT-5 and GPT-4 models next to live OpenCheap prices, on one OpenAI-compatible key.
- [The cheapest way to use Gemini through an API](https://opencheap.si/guides/cheapest-gemini-api): Gemini chat models on OpenCheap, with today's price per million input and output tokens from the same book as the pricing page.
- [The cheapest Qwen API, with official prices side by side](https://opencheap.si/guides/cheapest-qwen-api): Qwen API pricing per 1M tokens: Alibaba Cloud's list rates next to live OpenCheap prices for Qwen4 Max, Qwen3 Coder and more. One OpenAI-compatible key.
- [The cheapest Llama API, priced live](https://opencheap.si/guides/cheapest-llama-api): Llama API pricing per 1M tokens for Llama 4 Maverick, Scout, 3.3 70B and 3.1 8B, at the cheapest healthy provider. One OpenAI-compatible key.
- [The cheapest Kimi API, with official prices side by side](https://opencheap.si/guides/cheapest-kimi-api): Kimi API pricing per 1M tokens: Moonshot's list rates next to live OpenCheap prices for Kimi K3.1 Pro, K3 and K2.6. One OpenAI-compatible key.

---

Source: https://opencheap.si/guides/claude-code-cheaper · All models: https://opencheap.si/models · Prices as JSON: https://api.opencheap.si/v1/prices · Index for agents: https://opencheap.si/llms.txt
