OpenCode
An open coding agent for the terminal: the agent itself is free, and you connect any model.
Sign in $0
The agent itself is free, you pay for the model
Any model
75+ providers, your own key
Works from Russia
Installation and local models
Open source
MIT license, the entire agent
Choose it if you want freedom: any model with your own key, open source, works fully locally too. Do not choose it if you need the most out of the box — Claude Code has the best benchmark pairing, and you cannot connect a Claude subscription here.
OpenCode is a coding agent that lives in the terminal and is not tied to a single vendor. Install it with one command, describe a task in words — the agent reads the project, edits files, and runs tests until it gets the result. What sets it apart from Claude Code and Codex is its design: the code is open, and you choose the model under the hood, from GPT to a free local one. In just over a year, the repository grew from four thousand to two hundred thousand GitHub stars.
1. Should you get it
The choice is simple: OpenCode is bought for freedom, not quality. Consider what matters more to you.
Who it is for. For those who want to decide which model writes their code and what it costs. Your own key from any of 75+ providers, a ChatGPT or Copilot subscription, a free local model — one agent, any engine. The agent's code is open: you can see what it does, and nobody can raise the price of the tool itself — its price is zero.
Who it is not for. For those who need maximum quality without setup. The top benchmark pairing belongs to Claude Code — 77 points versus 65 for the OpenCode + Opus 4.7 pairing, and it works faster. And you cannot connect a Claude Pro/Max subscription to OpenCode: Anthropic prohibits it, and the plugins were removed starting with version 1.3.0.
No coding at all? Then a terminal agent is not the first door: it expects you to read what it writes. Start with the vibecoding page — the link below — then come back here for a tool.
OpenCode does not build this site. We vibecode vibecoding.tech in Claude Code and Codex: as of September 8, 2026, the former made nine tenths of merged changes, the latter the rest. Which machine is working right now is shown by live.
If it fits, install it in section 3. Choosing between it and Claude Code — see the choice in section 7.
2. What it can do
The workflow looks like this: describe a task in words, walk away — the agent returns with a finished result.
It works in a loop. There are two modes inside: Plan reads the project and suggests a strategy, Build executes it — edits files, runs commands, runs tests, and fixes what it broke. Every action goes through permissions: what to ask about, allow, or forbid is up to you.
Any engine works. Connect a model through your own API key (75+ providers), a ChatGPT Plus/Pro or GitHub Copilot subscription, the Zen gateway — or entirely locally through Ollama or LM Studio, so code never leaves your machine. There is no Claude subscription here: Anthropic prohibits it in third-party agents.
It sees code like an IDE. Under the hood are language servers (LSP): the agent does not just read file text, it follows definitions and references like a programmer in an editor. This is its signature difference — the community calls it the reason OpenCode works more accurately with equal models.
It extends like building blocks. MCP servers connect databases, the browser, and external APIs; plugins and subagents are assembled in config; with the `opencode serve` command, the agent becomes a server — you can assign tasks from your phone.
3. Where it works and how to install
The terminal is its main home; the other surfaces grew around it.
You can install it from Russia. Installation through curl, npm, or brew does not check your country, and the MIT license carries no restrictions. With a local model, the agent runs entirely on your machine — with no foreign access or cards needed; paying for cloud models is a separate question, covered in section 5.
Terminal. The main surface: a text interface in any modern terminal emulator. There is a desktop app (macOS, Windows, Linux), an editor extension, and server mode — manage sessions from a browser or phone.
How to install
Step 1. Install the agent with one command — or through npm and brew if that is more familiar:
curl -fsSL https://opencode.ai/install | bashStep 2. Run `opencode` in the project folder and use `/connect` to connect a model: a provider key, a ChatGPT or Copilot subscription, Zen, or local Ollama.
opencodeStep 3. Give it the first task in words and watch the plan: Plan mode shows the strategy before Build starts changing files.
Commands checked 21.08.2026 against opencode.ai/docs
4. What the tests show
An agent without a model cannot be benchmarked: every measurement is always an “agent + model” pairing.
In the table. The OpenCode + Opus 4.7 pairing holds 65 points on the AA Coding Agent Index (snapshot 05.07.2026) — the middle of the table. The best Claude Code pairing has 77: OpenCode's ceiling equals the ceiling of the model you put into it.
Community measurement. Where benchmarks are silent, the market speaks: 199.7 thousand GitHub stars and 1.7 million weekly npm installs (13–19.08.2026) — it is the fastest-growing open agent of the year. Stars do not measure code quality, but they do measure developer trust well.
Agent table: weight - editorial · AA score - best pairing · Artificial Analysis · “—” - pairing not measured
5. How much it costs
The agent itself is entirely free. The money goes not to OpenCode, but to the model — and there are four paths.
Your own key (BYOK). Connect a provider key and pay them directly at their rates. Straightforward, but with no cap: a Hacker News user accidentally spent $6 on one small feature through an Anthropic key (Feb. 2026). Watch your spending yourself.
Zen — pay as you go. A gateway with a curated model list: add at least $20 to your balance and pay for tokens with no markup. Claude Sonnet 5 — $2/$10 per million tokens, Opus 5 — $5/$25. Seven models are free — the vendor labels them “for a limited time.”
Go — subscription to open models. $5 for the first month, then $10 per month: DeepSeek, Qwen, and other open-source models with limits in five-hour windows. Practitioners build a working setup on this for a tenner: “a task costs $0.4–1.”
Local — $0. Ollama or LM Studio on your own machine: free, private, slower than top cloud models.
Paying from Russia. Installation and local mode work without restrictions, but Zen and Go do not accept Russian cards. Options: your own key from a third-party provider, free models, or a foreign card, how to get one — payment guide.
Payment options and what they offer
Prices checked 21.08.2026 · opencode.ai/zen · opencode.ai/go · the list of free Zen models changes weekly
What we checked and how
| Fact | What we know | Verified |
|---|---|---|
| The agent itself — $0, MIT license | GitHub API: MIT license; no subscription for the agent (opencode.ai) | 21.08.2026 |
| Zen: balance from $20, auto-reload at $5, no token markup | opencode.ai/docs/zen; anchor prices: Sonnet 5 $2/$10, Opus 5 $5/$25 per 1M tokens | 21.08.2026 |
| Go: $5 for the first month, then $10/mo | opencode.ai/go; open-source models, limits in five-hour windows | 21.08.2026 |
| Zen has 7 free models, all "for a limited time" | opencode.ai/docs/zen as of 08/21/2026; the lineup changes | 21.08.2026 |
| Russian cards do not work with Zen or Go | Payment guides on vc.ru/dtf.ru (interested intermediaries - medium confidence) | 21.08.2026 |
6. Can you trust it with code
We look at three things: where the code goes, what researchers have found, and what the agent can do to your machine.
Where the code goes. The agent runs locally and connects directly to the selected model provider — there are no intermediary servers by default, and with a local model the code never leaves the machine. Caveat: the /share command (off by default) publishes the conversation to opencode.ai, and Zen traffic goes through the vendor's gateway.
The vulnerability was serious. In January 2026, CVE-2026-22812 (8.8 out of 10) was published: the agent started a local server without authentication, allowing a malicious website to run commands on the machine directly from the browser. Fixed in version 1.0.216 — older versions are vulnerable, update immediately.
Permissions are not a cage. The permissions system shows what the agent is doing, but researchers have demonstrated ways to bypass command text filters. Run unfamiliar code and autonomous marathons in Docker or a VM — that is user discipline, not a setting.
Telemetry. Users report telemetry being sent to the vendor's servers even with local models; the project has no separate public telemetry policy page. The code is open — you can check exactly what is sent yourself.
What we checked and how
| Fact | What we know | Verified |
|---|---|---|
| CVE-2026-22812: RCE through a local server, CVSS 8.8 | GHSA-vxw4-wv6m-9hhh, published 01/12/2026; fixed in version 1.0.216 | 21.08.2026 |
| Code and context are not stored on the agent's servers | Runs locally, requests go directly to the model provider (opencode.ai); /share is opt-in | 21.08.2026 |
| Permissions are awareness, not a sandbox | Community demonstrations of text-filter bypasses (HN, DeepWiki); mitigation: Docker/VM | 21.08.2026 |
| Telemetry: practitioner reports, no official policy | HN/Habr reports of telemetry with local models; no policy page found | 21.08.2026 |
7. OpenCode or Claude Code
The most common fork in the road. Short answer: OpenCode is freedom, Claude Code is out-of-the-box quality.
A different trade-off. Claude Code delivers the better pair of scores (77 versus 65) and more speed: in Builder.io's controlled run (one model, four tasks), it finished in 9 minutes versus OpenCode's 16 — but OpenCode wrote more tests. One is built for speed, the other for thoroughness.
Subscription math. Claude Code runs on a Claude Pro/Max subscription — and Anthropic prohibits using it in third-party agents, so Claude models in OpenCode are available only through a paid-per-token API key. The low-cost OpenCode setup works differently: Go for $10 with open-source models or Zen's free models.
The common pattern is using both at once. Heavy users keep OpenCode for everyday work with cheap models and Claude Code for tasks that demand the maximum. There are other open neighbors too: Cline in the editor, aider in the terminal.
What to choose for the task
AA Coding Agent Index - snapshot 07/05/2026 · Builder.io run - Firecrawl, 06/01/2026
8. History
The project is a year and a half old, and for half that time it has lived with a scandal in its past: the OpenCode name is the trophy of a public breakup between two teams.
04
Developer Kuytim Khodzha builds the terminal agent TermAI; the SST team joins, and the project gets the name opencode and the opencode.ai domain.
30.04
The current repository is created: a TypeScript rewrite of the agent under SST's wing (later — Anomaly).
31.07
Split with Charm: the company takes the Go branch and its author under the name Crush, while SST retains the opencode name.
12.01
Critical vulnerability CVE-2026-22812 published: the agent's local server lacks authentication; fixed in version 1.0.216.
21.03
First place on the Hacker News front page: 126 thousand GitHub stars and, according to the vendor, 5 million monthly users.
20.08
Version 1.18.19, with releases almost daily; 199,7 thousand GitHub stars and 1,7 million npm installs per week.
9. Frequently asked questions
What is OpenCode in plain English?+
A coding agent for the terminal: describe a task in words, and it edits files, runs commands, and checks the result itself. Open-source and free (MIT), it works with any model — your own key, a ChatGPT or Copilot subscription, or a local model. Built by Anomaly, formerly known as SST.
Is OpenCode free?+
The agent itself is fully free: no subscription or seat fee. You only pay for the model: your provider key, the pay-as-you-go Zen gateway, or a Go subscription for $10 per month. You can also use it with no bill at all: a local model through Ollama or free Zen models (as of 21.08.2026, there are seven; the vendor labels them “for a limited time”).
Can I connect a Claude Pro or Max subscription?+
No. Anthropic explicitly prohibits using Claude subscriptions in third-party agents, and OpenCode removed such plugins starting with version 1.3.0. Claude models remain available with an Anthropic API key or through the Zen gateway — charged by tokens. ChatGPT Plus/Pro and GitHub Copilot subscriptions connect normally.
Does OpenCode work from Russia?+
It installs and works: installation through curl, npm, or brew does not check your country, and with a local model the agent does not access the internet at all. The only barrier is payment: Zen and Go do not accept Russian cards, so you need a foreign one. Workarounds without a card: your own key from a third-party provider, or free and local models.
What are OpenCode Zen and OpenCode Go?+
Two ways to avoid dealing with keys. Zen is a gateway with a curated model list and pay-as-you-go billing: add at least $20 to your balance and pay for tokens with no markup. Go is a subscription to open-source models (DeepSeek, Qwen, and others): $5 for the first month, then $10 per month. Both are optional — your own key from any provider works without them.
OpenCode or Claude Code — which should you choose?+
OpenCode is for freedom: open source, any model, local mode, $0 for the agent itself. Claude Code is for out-of-the-box quality: the best benchmark pairing (77 versus 65 on the AA Index) and speed — in a controlled Builder.io run, it completed the same tasks nearly twice as fast. Heavy users often keep both: OpenCode for everyday work with inexpensive models, Claude Code for complex tasks.
Are OpenCode and Crush the same thing?+
No, they are two branches of one early project. In summer 2025, the team split: the author of the original code joined Charm, and their branch became known as Crush, while the OpenCode name and opencode.ai domain stayed with the SST team, now Anomaly. This card is about opencode.ai.
Useful reading before you start
- What is vibecoding: starting from scratch.
- Claude Code: the main competitor from section 7.
- MCP: how an agent connects to your services.
- The full AI agent ranking.

