DEV Community

ToolPotion
ToolPotion

Posted on

Claude Code vs Codex on Terminal-Bench 4.0: A Tie That Still Forces a Choice

If you only read the leaderboard headline, Claude Code and Codex look interchangeable. On Terminal-Bench 4.0 they basically are. The buy still hinges on models, permissions, and how your team burns credits.

Disclosure: ToolPotion Media Team; ToolPotion is our product. Numbers below come from our terminal coding agents comparison.

Terminal-Bench 4.0 low vs max effort

The scoreboard is a coin flip

Terminal-Bench (Stanford, Harbor, Laude Institute) scores agent–model pairs on hard tasks inside a real terminal. On the current 4.0 board, Codex with GPT-6 Astra at max reasoning effort leads at 58.2%, and Claude Code with Fable 5.1 at max effort sits at 57.9% (Terminal-Bench via ToolPotion). Each entry runs 330 trials with a confidence interval of roughly three points either way, so call it a tie.

The effort dial matters as much as the brand. Dropping from max to low effort costs Codex with Astra under 8 points and Claude Code with Fable 5.1 nearly 15 (Opus 5 falls about 17) (same guide). Default settings can move you as much as switching vendors.

Cost logged on the board is the second story: about $3,267 for Codex with Astra at max effort against about $6,244 for Claude Code with Fable 5.1 at max in the leaderboard spend column we cite (guide). Quality can tie while invoices diverge.

Claude Code vs Codex at a glance

What actually differs

Both sit on roughly a $20/month plan class, both can push work to the cloud, and both grow plugins/subagents (guide). Differences:

  • Models: Claude Code stays on Anthropic models (default Opus 5.5; Fable 5.1 as an explicit opt-in that can hit extra usage credits). Codex defaults to GPT-6.1 Sol with Astra available for harder runs.
  • Permissions: Codex ships safer defaults and an open-source client story; Claude Code's interactive sessions have moved toward auto modes that need team policy (from v2.1.283 notes in the guide).
  • Credits: usage often meters at $0.01 per credit-class packaging for overages — read the vendor card before you leave max effort on overnight.

Gemini CLI's path into Antigravity is a third lane if you are Google-stack native; treat it as a different product family rather than a drop-in third place on the same bench (guide).

How we would pick this week

  1. Run the same three repo tasks at low and max effort on both tools.
  2. Log wall time, tokens/credits, and whether a human still had to finish the PR.
  3. Check who can tighten permissions for juniors.
  4. Prefer the tool whose default effort setting matches your budget — not the one that wins a three-point bench gap.

Browse the live AI coding assistants board after you shortlist. For agent platforms beyond the terminal, see the agent platform buyer's guide.

Practical takeaways

  • Treat 58.2% vs 57.9% as a tie; decide on permissions and spend.
  • Measure low vs max effort yourself: defaults move scores by ~8–15 points.
  • Budget for the logged spend gap (~$3.3k vs ~$6.2k on the cited max-effort runs).
  • Keep a human on merges; terminal agents amplify both speed and blast radius.

Full comparison: Claude Code vs Codex vs Gemini CLI.

Permission tiers before overnight runs

Terminal agents fail in public when they can rm, push, or exfiltrate. Codex's safer defaults are a feature, not a vibe. Claude Code can be configured tightly, but only if someone on your team owns the policy. Before you leave max effort on overnight, freeze: which directories are writable, which hosts are reachable, and whether network is off by default. Pair this with our containment guide if the agent also holds deploy keys.

A 90-minute bake-off script

  1. Clone a throwaway fork of a real service repo (not a toy).
  2. Ask each agent for the same three tasks: fix a failing test, add a small endpoint, and explain a flaky flake without changing code.
  3. Run each task at low effort and at max effort.
  4. Record Terminal-Bench-style judgment yourself: did it finish, did it need a human, how many dollars of credits burned?
  5. Prefer the tool that stays correct when you turn effort down: that is the setting juniors will leave on.

If both tools finish and the spend gap matches the board's ~$3k vs ~$6k pattern on hard max-effort work, pick the cheaper stack unless Anthropic-only or OpenAI-only model preference is a hard constraint (terminal agents guide).

What we are not claiming

We are not claiming Terminal-Bench predicts your backlog. We are claiming that a sub-one-point gap at max effort is not a reason to ignore permissions, credit meters, or the effort dial. Read the full head-to-head before you standardize: terminal coding agents compared.

API vs seat economics

Anthropic lists about $4 per million input tokens and $20 per million output for Opus 5.5, and $2 / $10 for Sonnet 5.5; OpenAI lists about $2 / $10 for GPT-6.1 Sol and $10 / $50 for GPT-6 Astra in the packaging we cite (terminal agents guide). In the Terminal-Bench run above, about 96% of Codex's input tokens were cache reads — that discount is why seat vs API math can flip after you measure your own cache hit rate. Rough guide math: a heavy month on Opus 5.5 via API can land near $126, while the same Astra-class workload can approach $401 (guide). Compare Claude Pro and ChatGPT Plus at $20 against that projected API bill before you standardize.

Related reading

After you pick a terminal agent, revisit how you route model tiers so max effort is not the default on every call (which model tier). And if the agent grows tools beyond the repo, re-read agents in production for step caps and human gates.

Top comments (0)