Reference articles on history, science, culture and more
Encyclopedia

OpenCode

Artificial intelligence coding agent

OpenCode is a free and open-source artificial intelligence coding agent developed by Anomaly. It connects large language models with software projects and development tools, allowing users to inspect, modify, optimize source code, run script commands, tests, and perform other programming tasks through natural-language instructions. OpenCode can be used through a terminal, desktop application, or integrated development environment (IDE), and supports models from more than 75 providers, including Anthropic, Google, and OpenAI, as well as locally hosted models.

01History

OpenCode is developed by Anomaly, the team behind the serverless development framework SST. The active version of OpenCode is primarily written in TypeScript and uses Bun. It is distinct from an earlier Go-based project of the same name that was archived in September 2025. In February 2026, Anthropic clarified that consumer Claude subscriptions could not be used through unauthorized third-party harnesses. OpenCode subsequently removed support for using Claude Pro and Max subscription credentials, while continuing to support access to models through other methods and providers.

02Features

OpenCode is model-agnostic, allowing users to select between different cloud-hosted and locally run language models without changing the coding-agent interface. It can connect to locally hosted language models with llama.cpp, LM Studio, and Ollama. The software can read and edit files, execute shell commands, run tests, and use Language Server Protocol servers to receive information such as compiler and linter diagnostics. It also supports the Model Context Protocol for connecting external tools and services. OpenCode includes separate planning and building modes, with the planning mode restricting file modifications by default. In addition to its command-line interface, it has a desktop application, and extensions for development environments such as Cursor, VSCodium, VS Code, and Windsurf. OpenCode can connect to model aggregation services such as OpenRouter, allowing users to access models from multiple artificial intelligence providers through a single API.

03Use

In 2026, Cloudflare used OpenCode with Anthropic's Claude while developing Vinext, an experimental implementation of much of the Next.js application programming interface using Vite. Cloudflare engineering director Steve Faulkner said the agent was used to plan the project's architecture and implement parts of the API against the existing Next.js test suite.

Watch videos about OpenCodeExplainers and documentaries on YouTube (opens in a new tab)

Sources and credits

This article is adapted from the Wikipedia article OpenCode, written by its contributors and licensed under CC BY-SA 4.0. Fathomly has changed the layout, removed citation markers, navigation and maintenance notices, and adjusted punctuation. This adapted version is shared under the same license. For references, see the original article.

Fathomly is not affiliated with or endorsed by the Wikimedia Foundation. Spotted a problem? Tell us.