Gray vs OpenCode: which open-source agent should you use?

Last updated

Short answer

Choose OpenCode if you want a polished, dedicated terminal coding UI that speaks to 75+ providers. Choose Gray if you want an even smaller MIT harness — one static binary, bash as the only default tool — that is a general always-on agent rather than a dedicated coding interface.

GrayOpenCode
What it isMinimal, always-on AI harness: one Rust binary, open source (MIT)Open-source (MIT) terminal coding agent with a full TUI
InterfaceTerminal REPL and headless print mode; Discord and other apps through pluginsRich terminal UI with sessions, diffs and built-in LSP
ProvidersAny OpenAI-compatible provider with your own API key; local models through Ollama; Claude Pro/Max and ChatGPT plans through official plugins75+ providers through Models.dev, including Claude Pro/Max and ChatGPT sign-in, plus its own Zen service
DataConversations, sessions and credentials stay on your machine under ~/.grayIts documentation states OpenCode stores none of your code or context data
Extends withPlugins and skills; MCP servers through the official pluginCustom agents, commands, plugins and MCP servers
Security modelRuns the model's shell commands with your user's privileges; no sandbox or approval prompt by default. The official permissions plugin adds approvalsIts plan agent is read-only by default and asks before running bash commands
Runs 24/7Yes — the gateway runs Gray as a user service, with cron and app connectionsInteractive sessions plus a serve/run mode for scripts
PriceFree (MIT); you pay your model provider. Hosted Voyager plan $77/month, not yet openFree (MIT); optional paid services, or pay your provider

Is Gray more minimal than OpenCode?

Yes. OpenCode ships a full terminal UI with LSP, sessions and diff views; Gray is deliberately smaller — one static binary, a REPL and headless mode, with everything else added as a plugin or skill.

Aider vs OpenCode vs Gray — which should I pick?

Pick Aider for Git-first pair programming, OpenCode for a polished terminal coding UI, and Gray for a minimal always-on harness that isn't limited to coding tasks. All three are open source and work with your own provider keys.

Which is better for privacy, Gray or OpenCode?

Both keep your code off vendor servers: OpenCode's docs state it stores none of your code or context data, and Gray keeps conversations and credentials on your machine under ~/.gray. With a cloud model, your code still goes to whichever provider you configure — pair either with Ollama for fully local runs; see Privacy.

When should you choose OpenCode instead?

Choose OpenCode if a rich coding TUI is the point — visual diffs, LSP-aware edits and session management — or you want its 75+ provider catalog and Zen service out of the box.

Sources

Competitor details are taken from the sources above as of the date at the top of this page. Products change quickly — if something here is out of date, open an issue on GitHub.