# OpenRouter

> One SDK, one key, every model. Usually cheaper than running the same open models elsewhere.

- Verdict: My default
- Vendor: OpenRouter
- Layer: [AI](https://cloudlesslabs.com/stack/layers/ai.md). Job: LLM access for client systems
- Last reviewed: 18 October 2026, by Nicolas Dao (Cloudless Labs, Sydney)
- Web page: https://cloudlesslabs.com/stack/openrouter/. The whole stack in one file: https://cloudlesslabs.com/stack/brief.md

OpenRouter lets me pick the best cost-per-intelligence model per feature and change my mind later with one string. Same SDK, same key, every provider.

## Use it when

- Any AI feature in a client system: switch models without changing code.

## Pricing

Model prices pass through; OpenRouter adds 5.5% on credit purchases. Example: DeepSeek V4 Pro at $0.66 / $1.98 per million tokens vs $1.32 / $3.96 on Cloudflare Workers AI.

## Gotchas, with fixes

- **Gotcha:** Calling it from the browser exposes your API key.
  **Fix:** Always go through a server-side proxy. A Cloudflare Worker is ideal: see the LLM proxy guide.

## Provisioning

Pulumi via a Terraform provider · Community Terraform provider

Vendor-published Terraform provider (OpenRouterTeam/openrouter): API keys, guardrails, workspaces, BYOK. Hosted MCP server available.

## Instead, consider

- [Anthropic API (for client systems)](https://cloudlesslabs.com/stack/anthropic-api/index.md): Not for client systems.

## Worked examples

- [The LLM streaming proxy](https://cloudlesslabs.com/stack/guides/llm-proxy/index.md): How do I add an AI chat feature without leaking my API key or paying for the model's thinking time?

## Where it fits

- [An AI chat or LLM feature](https://cloudlesslabs.com/stack/use-cases/ai-chat.md): pick 2. Every model behind one key. Pick by cost per intelligence.

## In The Stack Weekly

- [Week 43: Decision models (Jev, and Cloudflare's Clef)](https://cloudlesslabs.com/weekly/2026-w43/index.md), watching
- [Week 43: DeepSeek V4.1 Flash 1017](https://cloudlesslabs.com/weekly/2026-w43/index.md), worth a pilot

## Sources

- [OpenRouter](https://openrouter.ai/)

## Related

- [AI](https://cloudlesslabs.com/stack/layers/ai.md): every tool in this layer, with its verdict
- [The whole stack in one file](https://cloudlesslabs.com/stack/brief.md): every use case and tool, for questions that span many
- [Map of every Markdown file on cloudlesslabs.com, with what each one answers](https://ask.cloudlesslabs.com)
