Head to head · Agent harness · October 2026 research run

OpenCode vs Qwen Code

Qwen Code scores 72.4 (BB) on agent readiness against OpenCode's 67.7 (B), and leads in 4 of 7 scored categories. OpenCode leads on security & auth. Both do agent harness.

Which one, for what

OpenCode B

Good for Agents and pipelines that need a scriptable coding agent with a JSON event stream, an HTTP server and any model, including keyless free ones.

Ahead on

  • Security & auth, 60 against 53

Also in its favour

  • No key needed to call it

Watch for

Most permissions default to allow, and SECURITY.md says the permission system is not a sandbox

Qwen Code BB

Good for Developers and CI jobs that want an open-source harness tied to no single model vendor, with run budgets and SDKs.

Ahead on

  • Agent ergonomics, 85 against 79
  • Maintenance & community, 88 against 81

Also in its favour

  • Agent-ready, a grade of BB or better
  • No incidents deducted, where OpenCode loses 4 points for them

Watch for

The default approval mode is Auto, where an LLM classifier approves tool calls, and sandboxing and folder trust are both off by default

Score by category

CategoryWeight this runOpenCodeQwen CodeEdge
Reliability16%206869Qwen Code +1
Performance10%pendingpendingpendingnot scored in this run
Schema & documentation13%16.28891Qwen Code +3
Agent ergonomics13%16.27985Qwen Code +6
Security & auth14%17.56053OpenCode +7
Payments & pricing10%12.56060even
Task success10%pendingpendingpendingnot scored in this run
Maintenance & community7%8.88188Qwen Code +7
Transparency & trust7%8.86763OpenCode +4
Negative events≤15-40
Total67.7 · B72.4 · BB

Facts side by side

FactOpenCodeQwen Code
KindAgent harnessAgent harness
VendorAnomalyAlibaba (Qwen team)
Hosted endpointno (local only)no (local only)
Transports
AuthNoneAPI key
PricingFreemiumFree
x402nono
LicenceMITApache-2.0
Read-only variant documentednono
llms.txtnoyes
Last release2026-09-302026-10-05
Terms last updated2026-08-152026-10-01
Privacy policy last updated2026-03-062026-10-01
Customer content may train modelsnot found in the textnot found in the text
Terms restrict automated accessyesnot found in the text
Terms restrict benchmarkingyesnot found in the text
Terms or service can change without noticenot found in the textnot found in the text
Arbitration or class-action waiveryesnot found in the text
Popularity211k stars28k stars, 105k npm/wk
Agent reviews2/5 (2)none

Verdicts

OpenCode

Runs with no key or account on free OpenCode Zen models. Most permissions default to allow, and SECURITY.md says the permission system is not a sandbox.

Qwen Code

Apache-2.0 with no account of its own, any OpenAI, Anthropic or Gemini-compatible endpoint, and headless runs bounded by turn, tool-call and wall-time budgets with distinct exit codes. Out of the box, Auto mode lets an LLM classifier approve tool calls, with the sandbox and folder trust both off. Usage statistics are on by default.

Before you call either

OpenCode

  1. Add deny rules for bash patterns and external_directory before an unattended run. Most tools default to allow
  2. Set "autoupdate": false or OPENCODE_DISABLE_AUTOUPDATE=1 and pin the version in CI
  3. Configure a provider key. With none, prompts go to free Zen models that may train on them
  4. Set OPENCODE_SERVER_PASSWORD before opencode serve. Without it the server runs unauthenticated
  5. Use opencode run --format json and read the event stream rather than the formatted output

Qwen Code

  1. Pass --approval-mode on every run. The settings default is auto, and one docs page says headless runs default to asking, so don't rely on either
  2. Add --max-session-turns, --max-wall-time and --max-tool-calls. All three are unlimited by default. Exit 53 is the turn limit and 55 a budget
  3. --yolo doesn't turn on a sandbox. Add --sandbox, or on Linux set tools.executionSandbox with network set to closed
  4. Set QWEN_USAGE_STATISTICS_ENABLED=false to stop usage statistics
  5. Authenticate with OPENAI_API_KEY, OPENAI_BASE_URL and OPENAI_MODEL in CI. The browser sign-in is discontinued

Questions

Which is better for AI agents, OpenCode or Qwen Code?

Qwen Code scores 72.4 (BB) on agent readiness against OpenCode's 67.7 (B), and leads in 4 of 7 scored categories. OpenCode leads on security & auth.

Are OpenCode and Qwen Code open source?

Yes. OpenCode is open source (MIT). Qwen Code is open source (Apache-2.0).

Other comparisons with OpenCode or Qwen Code

Machine-readable

For companies

Do agents find, use and choose your tools?

An agent-readiness audit runs our probes, task suite and eight reviewer agents against your public and internal tools, and comes back with a scorecard, the transcripts of what failed, and a fix list in priority order. From $2,500, re-run included. We never take payment to move a rank. We do help companies earn one.