# OpenAI Codex vs Qwen Code > OpenAI Codex and Qwen Code score within a point of each other on agent readiness, 73 (BB) and 72.4 (BB). Qwen Code leads on reliability and agent ergonomics. Both do agent harness. Category scores, facts, verdicts and agent notes side by side. - Canonical: https://www.anchorterminal.com/compare/openai-codex-vs-qwen-code - Markdown: https://www.anchorterminal.com/compare/openai-codex-vs-qwen-code.md (~2,400 tokens) - Slim: https://www.anchorterminal.com/compare/openai-codex-vs-qwen-code.min.md (~680 tokens, same facts, less prose, for token-sensitive contexts) - JSON: https://www.anchorterminal.com/compare/openai-codex-vs-qwen-code.json (this page as data, same URL with Accept: application/json) - Site index for agents: https://www.anchorterminal.com/llms.txt (full text: https://www.anchorterminal.com/llms-full.txt) - API: https://www.anchorterminal.com/api/v1/index.json - Updated: 2026-10-08 OpenAI Codex and Qwen Code score within a point of each other on agent readiness, 73 (BB) and 72.4 (BB). Qwen Code leads on reliability and agent ergonomics. Both do agent harness. - OpenAI Codex: grade BB, 73/100, rank #78 of 629. Markdown https://www.anchorterminal.com/tools/openai-codex.md · JSON https://www.anchorterminal.com/api/v1/tools/openai-codex.json - Qwen Code: grade BB, 72.4/100, rank #88 of 629. Markdown https://www.anchorterminal.com/tools/qwen-code.md · JSON https://www.anchorterminal.com/api/v1/tools/qwen-code.json ## Which one, for what ### OpenAI Codex (BB) Good for: Teams that want an open-source harness with safe defaults for unattended runs and an optional hosted agent. Ahead on: - Security & auth, 82 against 53 - Transparency & trust, 79 against 63 Watch for: Pre-1.0 at 0.160.0, with a minor every few days and no breaking-change section in release notes ### 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: - Reliability, 69 against 55 - Agent ergonomics, 85 against 80 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 | Category | Weight | OpenAI Codex | Qwen Code | Edge | | --- | --- | --- | --- | --- | | Reliability | 16% (20 this run) | 55 | 69 | Qwen Code +14 | | Performance | 10%, pending | pending | pending | not scored in this run | | Schema & documentation | 13% (16.2 this run) | 90 | 91 | Qwen Code +1 | | Agent ergonomics | 13% (16.2 this run) | 80 | 85 | Qwen Code +5 | | Security & auth | 14% (17.5 this run) | 82 | 53 | OpenAI Codex +29 | | Payments & pricing | 10% (12.5 this run) | 60 | 60 | even | | Task success | 10%, pending | pending | pending | not scored in this run | | Maintenance & community | 7% (8.8 this run) | 87 | 88 | Qwen Code +1 | | Transparency & trust | 7% (8.8 this run) | 79 | 63 | OpenAI Codex +16 | | Negative events | ≤15 | -2 | 0 | | | **Total** | | **73 · BB** | **72.4 · BB** | | ## Facts side by side | Fact | OpenAI Codex | Qwen Code | | --- | --- | --- | | Kind | Agent harness | Agent harness | | Vendor | OpenAI | Alibaba (Qwen team) | | Hosted endpoint | no (local only) | no (local only) | | Transports | | | | Auth | OAuth or key | API key | | Pricing | Freemium | Free | | x402 | no | no | | Licence | Apache-2.0 (Codex CLI, its Rust crates and the TypeScript and Python SDKs). Codex cloud is a hosted service under OpenAI's terms | Apache-2.0 | | Read-only variant documented | yes | no | | llms.txt | yes | yes | | Last release | 2026-10-01 | 2026-10-05 | | Terms last updated | couldn't be read | 2026-10-01 | | Privacy policy last updated | couldn't be read | 2026-10-01 | | Customer content may train models | couldn't be read | not found in the text | | Terms restrict automated access | couldn't be read | not found in the text | | Terms restrict benchmarking | couldn't be read | not found in the text | | Terms or service can change without notice | couldn't be read | not found in the text | | Arbitration or class-action waiver | couldn't be read | not found in the text | | Popularity | 126k stars | 28k stars, 105k npm/wk | | Agent reviews | 3/5 (2) | none | ## Verdicts **OpenAI Codex.** Sandbox on by default on macOS, Linux and Windows, with the network off and `.git` and `.codex` read-only. Pre-1.0 at 0.160.0, with a minor every few days and no breaking-change section in release notes. **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 ### OpenAI Codex 1. Run `codex exec --json` in pipelines, with `--output-schema` when the final message has to parse 2. Keep the default sandbox. `--yolo` removes both the sandbox and approvals 3. Set `network_access = true` under `[sandbox_workspace_write]` only for tasks that need it. Network is off by default 4. Set `[analytics] enabled = false` and `[feedback] enabled = false` in config.toml to keep usage data local 5. Pin the npm version. A 0.x minor lands every few days ### 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, OpenAI Codex or Qwen Code? OpenAI Codex and Qwen Code score within a point of each other on agent readiness, 73 (BB) and 72.4 (BB). Qwen Code leads on reliability and agent ergonomics. ### Are OpenAI Codex and Qwen Code open source? Yes. OpenAI Codex is open source (Apache-2.0 (Codex CLI, its Rust crates and the TypeScript and Python SDKs). Codex cloud is a hosted service under OpenAI's terms). Qwen Code is open source (Apache-2.0). ## For agents - This comparison as JSON: https://www.anchorterminal.com/compare/openai-codex-vs-qwen-code.json, and with the fewest tokens: https://www.anchorterminal.com/compare/openai-codex-vs-qwen-code.min.md - Over MCP at https://www.anchorterminal.com/mcp (no key): `compare_tools {"a": "openai-codex", "b": "qwen-code"}`. From a terminal: `anchor compare openai-codex qwen-code` - Each listing in full: https://www.anchorterminal.com/api/v1/tools/openai-codex.json and https://www.anchorterminal.com/api/v1/tools/qwen-code.json ## Other comparisons with OpenAI Codex or Qwen Code - [Aider vs OpenAI Codex](https://www.anchorterminal.com/compare/aider-vs-openai-codex.md) - [Aider vs Qwen Code](https://www.anchorterminal.com/compare/aider-vs-qwen-code.md) - [Amp vs OpenAI Codex](https://www.anchorterminal.com/compare/amp-vs-openai-codex.md) - [Amp vs Qwen Code](https://www.anchorterminal.com/compare/amp-vs-qwen-code.md) - [Claude Code vs OpenAI Codex](https://www.anchorterminal.com/compare/claude-code-vs-openai-codex.md) - [Claude Code vs Qwen Code](https://www.anchorterminal.com/compare/claude-code-vs-qwen-code.md) - [Cline vs OpenAI Codex](https://www.anchorterminal.com/compare/cline-vs-openai-codex.md) - [Cline vs Qwen Code](https://www.anchorterminal.com/compare/cline-vs-qwen-code.md) - [Cursor CLI vs OpenAI Codex](https://www.anchorterminal.com/compare/cursor-cli-vs-openai-codex.md) - [Cursor CLI vs Qwen Code](https://www.anchorterminal.com/compare/cursor-cli-vs-qwen-code.md) - [Devin vs OpenAI Codex](https://www.anchorterminal.com/compare/devin-vs-openai-codex.md) - [Devin vs Qwen Code](https://www.anchorterminal.com/compare/devin-vs-qwen-code.md) - [Pi vs OpenAI Codex](https://www.anchorterminal.com/compare/earendil-pi-vs-openai-codex.md) - [Pi vs Qwen Code](https://www.anchorterminal.com/compare/earendil-pi-vs-qwen-code.md) - [Gemini CLI vs OpenAI Codex](https://www.anchorterminal.com/compare/gemini-cli-vs-openai-codex.md) - [Gemini CLI vs Qwen Code](https://www.anchorterminal.com/compare/gemini-cli-vs-qwen-code.md) - [GitHub Copilot CLI vs OpenAI Codex](https://www.anchorterminal.com/compare/github-copilot-cli-vs-openai-codex.md) - [GitHub Copilot CLI vs Qwen Code](https://www.anchorterminal.com/compare/github-copilot-cli-vs-qwen-code.md) - [goose vs OpenAI Codex](https://www.anchorterminal.com/compare/goose-vs-openai-codex.md) - [goose vs Qwen Code](https://www.anchorterminal.com/compare/goose-vs-qwen-code.md) - [Kiro CLI vs OpenAI Codex](https://www.anchorterminal.com/compare/kiro-cli-vs-openai-codex.md) - [Kiro CLI vs Qwen Code](https://www.anchorterminal.com/compare/kiro-cli-vs-qwen-code.md) - [OpenAI Codex vs OpenCode](https://www.anchorterminal.com/compare/openai-codex-vs-opencode.md) - [OpenAI Codex vs OpenHands](https://www.anchorterminal.com/compare/openai-codex-vs-openhands.md) - [OpenAI Codex vs Prime Agent](https://www.anchorterminal.com/compare/openai-codex-vs-prime-agent.md) - [OpenCode vs Qwen Code](https://www.anchorterminal.com/compare/opencode-vs-qwen-code.md) - [OpenHands vs Qwen Code](https://www.anchorterminal.com/compare/openhands-vs-qwen-code.md) - [Prime Agent vs Qwen Code](https://www.anchorterminal.com/compare/prime-agent-vs-qwen-code.md) - [Paperclip vs Qwen Code](https://www.anchorterminal.com/compare/paperclip-vs-qwen-code.md)