What it does
An open-source AI coding agent with a terminal UI, plus a desktop app and IDE support. It works with API keys from many LLM providers. It has a full-access build agent and a read-only plan agent you switch between with Tab. MIT licensed.
Who it's for
Terminal users who want an open-source agent and the freedom to pick their own model provider.
How to set it up
OpenCode 2 (what opencode.ai/download offers now):
bashcurl -fsSL https://opencode.ai/v2/install | bash # or npm install -g @opencode/cliOpenCode 1 (the install the GitHub README still shows):
bashcurl -fsSL https://opencode.ai/install | bash # or brew install anomalyco/tap/opencodeBoth versions use the opencode command and aren't installed side by side by default; the V2 installer replaces a V1 binary. If you're moving from V1, read opencode.ai/v2/docs/migrate-v1 first (V1 plugins don't run in V2).
cd into your project, run opencode, and add API keys for the providers you want to use.
bashopencode
Check the official OpenCode docs for the latest steps.
Example prompts
Switch to plan mode and explain how authentication works in this repo.Add pagination to the /api/posts endpoint and update the tests.@general find every place we call the payments API.Demo
Demo coming soon
A short walkthrough of OpenCode in action.
More Coding Agents
- Aider
Aider
Open-source AI pair programming in your terminal. It edits code in your local git repo and works with many LLMs (Claude, DeepSeek, OpenAI models and more).
- Anthropic
Claude Code
Anthropic's agentic coding tool. It reads your codebase, edits files, runs commands, works with git and connects to MCP servers. It runs in the terminal, with VS Code/JetBrains extensions, a desktop app and a web version too.
- OpenAI
Codex CLI
OpenAI's open-source coding agent that runs locally in your terminal. It reads and edits your code, runs commands and connects to MCP servers. Codex also comes as an IDE extension (VS Code, Cursor, Windsurf), a desktop app and a cloud version. Apache-2.0.
- Agentic AI Foundation (Linux Foundation)
goose
An open-source, general-purpose AI agent that runs on your machine as a desktop app (macOS, Linux, Windows), a CLI and an API. It isn't only for code: it also handles research, writing and automation. It supports 15+ model providers and connects to tools through MCP extensions. Originally from Block, now part of the Agentic AI Foundation. Apache-2.0.
- OpenHands
OpenHands
An open-source platform for running coding agents. Its Agent Canvas app (labeled beta) is a self-hosted control center where you start agent conversations and set up automations (for example with Slack, GitHub or Linear). It runs the OpenHands agent by default and can also run Claude Code, Codex, OpenCode and other ACP-compatible agents, locally, in Docker, on VMs or in OpenHands Cloud. MIT licensed.