Skip to content
Aventail™ investigation into UK government AI dependence featured in Computer Weekly.Read the story
Aventail™
All guides

OpenCode vs Claude Code

15 min read

OpenCode vs Claude Code compared on licence, price, models, local model support, permissions, enterprise controls and telemetry, plus a pilot checklist.

OpenCode is a free, MIT-licensed coding agent from Anomaly that works with models from many providers and finds local models from Ollama, LM Studio and vLLM without configuration. Claude Code is Anthropic's proprietary coding agent, included in paid Claude plans from $17 a month. It is built for Claude models, has VS Code and JetBrains integrations and has an operating-system sandbox for shell commands. Choose OpenCode when model choice, local models or an open licence matter most. Choose Claude Code when you want Claude models with Anthropic's support and its managed enterprise settings. Both shipped a release on 13 November 2026: OpenCode v2.3.0 and Claude Code 2.1.325.

The facts below come from each vendor's own pages, read on 15 November 2026.

OpenCode

Claude Code

Made by

Anomaly

Anthropic

Licence

MIT. Source at github.com/anomalyco/opencode, 226,967 GitHub stars on 15 November 2026

Proprietary. "© Anthropic PBC. All rights reserved." Use falls under Anthropic's Commercial or Consumer Terms

Price

Free. Optional OpenCode Go at $10 a month, Go Plus at $40, Go Teams at $20 per member. Otherwise you pay your model provider

Included in paid Claude plans: Pro $20 a month ($17 on annual billing), Max $100, Ultra $200, Team from $25 a seat ($20 annual), Enterprise $20 a seat plus usage at API rates. Not in the Free plan. Or pay per token on an API account

Models

The models.dev catalog, which OpenCode says covers 200+ providers. A set of free models. Sign-in with ChatGPT Plus or Pro and GitHub Copilot. Custom providers

Claude models, through Anthropic, Amazon Bedrock, Google Cloud's Agent Platform, Microsoft Foundry or Claude Platform on AWS

Local model support

Built in. Discovers Ollama, LM Studio and vLLM at their default addresses. Any OpenAI-compatible server through a custom provider

Not supported by Anthropic. It runs against an Anthropic-compatible endpoint set in ANTHROPIC_BASE_URL, which Ollama, LM Studio and llama.cpp document

Terminal and IDE surfaces

Terminal UI, desktop app (macOS, Windows, Linux), mobile app, web through opencode pair, SDK. Editors through ACP (opencode acp), with Zed as the documented example

CLI, desktop app, VS Code extension, JetBrains plugin, web and mobile. Integrations for Chrome, Slack, GitHub Actions and GitLab CI/CD

Permissions and sandbox

Ordered allow, ask and deny rules. The base policy allows every action and asks before reading .env files. No operating-system sandbox in the docs: shell commands run with the user's own authority

Permission modes from Manual, where only reads run without asking, to bypassPermissions, plus allow, ask and deny rules. Operating-system sandbox for shell commands on macOS, Linux and WSL2, off by default

Enterprise controls

Managed configuration and policies through system files or macOS MDM. OpenCode Console workspaces with roles, SSO, SCIM, budgets and workspace policies

Managed settings through files, MDM or the claude.ai console on Team and Enterprise. allowedProviders, the Claude apps gateway with SSO and per-group model access, zero data retention and HIPAA options

Telemetry

No client telemetry reference in the version 2 docs. Privacy policy: prompts pass to the upstream provider and are not stored, except by hosted agents

Usage metrics on by default on Anthropic's API, off by default on Bedrock, Agent Platform and Foundry. DISABLE_TELEMETRY=1 turns them off. Metrics never include code, prompts or file paths

Latest version

v2.3.0, 13 November 2026

2.1.325, 13 November 2026

Frequently asked questions

Is OpenCode better than Claude Code?
This page claims no benchmark. A coding agent's usefulness depends on the model, the project, the tools and the permissions you give it. OpenCode gives you more choice of model and an open licence. Claude Code gives you Anthropic's models, support and a sandbox. Use the pilot checklist below to decide for your own work.

Is OpenCode free?
Yes. OpenCode's site states it is free to use and MIT licensed, and it comes with a set of free models. You pay when you connect a paid provider or subscribe to OpenCode Go ($10 a month), Go Plus ($40) or Go Teams ($20 per member). Check the privacy terms of each free model before you use one at work. OpenCode lists several whose providers retain or train on data during the free period.

Is Claude Code free?
No. Anthropic's pricing page says Claude Code is included in all paid plans and marks it as not included in Free. Pro is $20 a month, or $17 a month on annual billing. You can also pay per token through the Claude Console or a cloud provider.

Can OpenCode use Claude models?
Yes, with an Anthropic API key (opencode auth login anthropic --method key), or through Google Vertex or OpenRouter. OpenCode's provider docs describe plan sign-in for ChatGPT Plus or Pro and GitHub Copilot. They do not describe one for Claude subscriptions, and Anthropic's terms do not permit third-party developers to offer Claude.ai login in their own applications.

Can Claude Code use GPT, Gemini or local models?
Not with Anthropic's support. Claude Code sends Anthropic-format requests to the address in ANTHROPIC_BASE_URL, so a gateway that translates can put another model behind it. Anthropic states it "doesn't support routing Claude Code to non-Claude models through any gateway". Our guide to Claude Code with a local model covers the setup and the limits.

Which is better for local models?
OpenCode needs less work. It discovers Ollama, LM Studio and vLLM by itself and reads context and tool support from the first two. Claude Code needs a server with an Anthropic-compatible endpoint and a few environment variables, and the result is unsupported. In both tools the local model has to handle tool calls. See OpenCode with a local model.

Are both tools limited to the terminal?
No. Both have a desktop app and mobile access as well as the terminal. Claude Code adds VS Code and JetBrains integrations and a web app. OpenCode adds an SDK and editor support through ACP.

Is OpenCode more private than Claude Code because it is open source?
No. An open-source client can call a cloud model, and a client installed on your laptop can send model requests elsewhere. Privacy depends on the destination each request reaches, what the app stores and what else it connects to. Check those for the version you install.

Understand what you are comparing

Choose the coding application and the model request path separately. OpenCode and Claude Code both offer agentic coding workflows, but the client you prefer does not, by itself, determine where your source code is processed or which model can perform the work.

OpenCode is an open-source coding agent with terminal, desktop and mobile interfaces. Its documentation now distinguishes major versions. OpenCode 2.0 shipped in September 2026 with a new native config shape and plugin API, so an older setup recipe may not apply. The version 1 docs remain online under a separate path.

Claude Code is Anthropic's coding agent. Its provider options, account requirements and features depend on the chosen surface and deployment.

Licence and price

OpenCode is MIT licensed, so you can read, modify and redistribute the client. The tool is free. What costs money is the model: your own provider account, OpenCode's pay-as-you-go Console credits, or a Go subscription with monthly usage limits on a curated set of coding models.

Claude Code is proprietary. The price is the Claude plan it comes with, or API usage. Team seats are $25 a month, or $20 on annual billing. Premium seats are $125, or $100 annual. Enterprise is $20 a seat a month plus usage at API rates, with a 20-seat minimum.

Compare the full workflow cost: application access, model or provider charges, machine capacity, support and administration time. Local inference still uses memory, energy and hardware. A cheaper request is not useful if the change takes substantially more review or repeatedly breaks the test suite.

Models and local model support

OpenCode's model documentation explains its provider and model configuration. You connect a provider with /connect and pick a model with /models. A providers entry in opencode.json covers any OpenAI-compatible server that discovery does not find. You still need a model that can follow the tool workflow.

Claude Code's gateway documentation describes third-party gateway connections and their compatibility requirements. Anthropic does not endorse or maintain those gateways, and does not support routing to non-Claude models through them. Treat a third-party integration as its own supported path and test it against the installed application version. Using Claude Code with another supported model does not mean running Anthropic's Claude model weights on your laptop.

OpenCode's Console also documents a Claude Code setup that points ANTHROPIC_BASE_URL at Console to serve GPT, Gemini and open models.

Surfaces

OpenCode ships a terminal UI, a desktop app, a mobile app, a web interface and a TypeScript SDK. For editors, the version 2 docs describe the Agent Client Protocol: opencode acp runs OpenCode as an agent for ACP clients such as Zed. The VS Code extension page sits in the version 1 docs.

Claude Code runs as a CLI, in the Claude desktop app, in VS Code, in JetBrains IDEs, on the web and from the Claude mobile app. Anthropic notes that the CLI is the most complete surface. Scripting and the Agent SDK are CLI-only.

Permissions and sandbox

Both tools need a deliberate policy for edits, shell commands and integrations. OpenCode documents allow, ask and deny permissions as ordered rules where the last match wins. Every agent starts from a base policy that allows all actions and asks before reading .env files. OpenCode's docs warn that shell runs with the host user's filesystem, process and network authority.

Claude Code documents its own permission rules and modes. In Manual mode only reads run without a prompt. Other modes accept edits, plan without editing, or let a classifier review actions. Deny rules block in every mode. Its Bash sandbox is enforced by the operating system on macOS, Linux and WSL2, is off by default, and covers shell commands only. On native Windows, commands run unsandboxed.

For each application, ask who can change the rules, how an approval appears and whether an external tool has broader access than the coding agent itself. Keeping inference private does not make a shell command harmless.

Enterprise controls

OpenCode reads managed settings from a system directory and from macOS managed preferences deployed by MDM. Its policies can deny a provider, a tool, an MCP server, a skill or a plugin. Managed policies outrank user and project files. OpenCode Console adds workspaces, SSO through OpenID Connect or SAML, SCIM directory sync, budgets and workspace policies that reach connected clients within about a minute.

Claude Code applies managed settings above every other level. Administrators deliver them as a file, through MDM, or from the claude.ai console on Team and Enterprise plans. allowedProviders can pin a machine to one endpoint. Anthropic's Claude apps gateway adds SSO sign-in, per-group model access and OpenTelemetry export.

Evaluate application administration separately from model infrastructure. Aventail™ Control manages models, machines and routing configuration, and Aventail™ Connect can be rolled out through Aventail™'s fleet tooling. Those capabilities do not replace either tool's own enterprise administration. Use the enterprise overview and fleet deployment guide to plan those responsibilities together.

Telemetry and data

Claude Code sends usage metrics and error reports. Metrics are on by default when you connect to Anthropic's API and off by default on Bedrock, Google Cloud's Agent Platform and Foundry. DISABLE_TELEMETRY=1 turns metrics off, and CLAUDE_CODE_DISABLE_NONESSENTIAL_TRAFFIC turns off updates, telemetry and error reporting together. Anthropic trains on Free, Pro, Max and Ultra data only when the account setting is on, and does not train on code or prompts sent under commercial terms unless the customer opts in.

OpenCode's version 2 docs have no client telemetry reference. Anomaly's privacy policy says prompts pass through to the upstream model provider and are not stored, except by hosted agents. Console lists the retention and training terms of each model it serves. Ask the vendor before you assume the client sends nothing.

Check application storage and non-inference connections separately. Aventail™'s privacy documentation explains why local execution and a product-analytics preference do not settle every reporting flow. The confidential-code security checklist provides a fuller review process.

Run a fair, useful pilot

Create a synthetic or otherwise approved small repository. Give both tools the same instructions, available context and task. Where both integrations support it, start with the same model and destination so you can observe the client workflow. Then test a model suited to each tool if compatibility differs. Record that difference. Do not present the result as a controlled benchmark.

Try three tasks that resemble your work:

  • Explain a module. Ask for its inputs, outputs and one likely edge case. Check factual accuracy against the code, not the confidence of the answer.

  • Fix a failing test. Introduce a harmless, known bug in a disposable branch. Ask for a small fix, inspect the diff and run the existing tests yourself.

  • Change a small behaviour. Give acceptance criteria and ask for a plan before editing. Check whether the tool stays within the permitted files and explains trade-offs clearly.

For each task, record whether it completed, whether the tests passed, how much manual correction was needed, time to the first useful result, resource use and actual execution destination. An integration working once is a starting point. It is not a general model-quality claim.

Test the restrictions as well as the result

With a local-only test policy, stop serving the local model and send another harmless request. Check that it fails and does not use an unapproved provider. Verify the actual destination for successful requests using the routing guide.

Check permission prompts with a harmless edit in the disposable repository. Review sharing, diagnostic and optional integration settings before introducing sensitive information. For a remote model, have the infrastructure owner validate the endpoint's access controls. Aventail™'s security guidance explains why Aventail™ Control sign-in alone does not secure a serving port.

Keep app and runtime versions in the pilot record. Recheck the relevant behaviours after an update, especially model selection, tool calling and error recovery.

Using both under one set of rules

There are two lanes for a team that wants either tool on its own models.

The tool's own lane. Each developer configures a provider: /connect or opencode.json in OpenCode, environment variables in Claude Code. This works for one person. The request goes wherever that machine's configuration says.

The routed lane. Aventail™ Connect supports OpenCode and Claude Code model requests through Aventail Link. Choose and serve a compatible model in the runtime, then enable the installed app in Connected Apps. For this automatic setup, the OpenCode instructions and Claude instructions do not require you to paste a provider key or edit an endpoint configuration. Do not mix that path with a generic manual provider recipe unless the integration instructions call for it.

With Link, you restrict the eligible destinations and fallback routes for the workflow. A request may execute locally, on another approved reachable machine running Link, or through an approved external API when policy permits. Peer and hosted routing are currently described as beta on the Connect page. If no destination is permitted, the request fails with an error.

This standardises the request policy for both tools. It does not replace either application's permissions or administration.

Which to choose

Choose OpenCode if its provider flexibility and workflow fit your team and the pilot demonstrates that it supports your tasks. Choose Claude Code if your developers prefer its workflow and the supported provider or third-party integration meets the same tests. Existing enterprise agreements, operating systems and support requirements may decide the question before a feature comparison does.

If the bigger question is which infrastructure to operate behind the tools, read LLM gateway vs inference engine.

Technical references were checked on 15 November 2026. No performance ranking is claimed here. The pilot is a repeatable method for making your own decision.

Sources

  1. OpenCode, site index and product FAQ: https://opencode.ai/llms.txt and https://opencode.ai/product

  2. OpenCode, Press (licence, maker, milestones, Go prices): https://opencode.ai/press

  3. OpenCode, Changelog (v2.3.0, 13 November 2026): https://opencode.ai/changelog

  4. OpenCode on GitHub (licence, star count, releases): https://github.com/anomalyco/opencode

  5. OpenCode docs, Intro, Providers, Models, Config: https://opencode.ai/docs/ and https://opencode.ai/docs/providers/ and https://opencode.ai/docs/models/ and https://opencode.ai/docs/config/

  6. OpenCode docs, Permissions and Policies: https://opencode.ai/docs/permissions/ and https://opencode.ai/docs/policies/

  7. OpenCode docs, ACP and provider accounts: https://opencode.ai/docs/cli/acp/ and https://opencode.ai/docs/cli/providers/

  8. OpenCode docs, Console, SSO, SCIM, budgets, Go, model privacy, Claude Code harness: https://opencode.ai/docs/console/ and https://opencode.ai/docs/console/sso/ and https://opencode.ai/docs/console/scim/ and https://opencode.ai/docs/console/budgets/ and https://opencode.ai/docs/console/go/ and https://opencode.ai/docs/console/models/ and https://opencode.ai/docs/console/harnesses/claude-code/

  9. OpenCode docs, Migrate from V1, and the version 1 IDE page: https://opencode.ai/docs/migrate-v1/ and https://opencode.ai/v1/docs/ide/

  10. Anomaly, OpenCode privacy policy: https://opencode.ai/legal/privacy-policy

  11. Anthropic, Claude Code changelog (2.1.325, 13 November 2026): https://code.claude.com/docs/en/changelog

  12. Anthropic, Claude Code on GitHub, licence file: https://github.com/anthropics/claude-code/blob/main/LICENSE.md

  13. Anthropic, Legal and compliance: https://code.claude.com/docs/en/legal-and-compliance

  14. Anthropic, Plans and pricing: https://claude.com/pricing

  15. Anthropic, Platforms and integrations: https://code.claude.com/docs/en/platforms

  16. Anthropic, Gateways: https://code.claude.com/docs/en/gateways and https://code.claude.com/docs/en/llm-gateway and https://code.claude.com/docs/en/llm-gateway-protocol

  17. Anthropic, Permissions, permission modes and sandboxing: https://code.claude.com/docs/en/permissions and https://code.claude.com/docs/en/permission-modes and https://code.claude.com/docs/en/sandboxing

  18. Anthropic, Managed settings and server-managed settings: https://code.claude.com/docs/en/managed-settings and https://code.claude.com/docs/en/server-managed-settings

  19. Anthropic, Data usage: https://code.claude.com/docs/en/data-usage

  20. Ollama, LM Studio and llama.cpp, Anthropic-compatible endpoints: https://docs.ollama.com/integrations/claude-code and https://lmstudio.ai/docs/integrations/claude-code and https://github.com/ggml-org/llama.cpp/blob/master/tools/server/README.md

  21. Aventail™, live guide "OpenCode vs Claude Code: choosing an AI coding tool for your team" (26 October 2026): https://aventail.co.uk/guides/opencode-vs-claude-code

  22. Aventail™, Connect overview and Connect page: https://docs.aventail.co.uk/docs/connect/overview and https://aventail.co.uk/connect

  23. Aventail™, Routing: https://docs.aventail.co.uk/docs/fleet/routing

All sources were read on 15 November 2026.

We use optional cookies and tracking to identify visiting companies, load our contact form, measure Google Ads download clicks and understand page use with PostHog on our homepage, Connect and How it works pages, Ollama and LM Studio comparison guides and campaign pages. Cookie policy