Codex CLI: how many tokens per task, and what does it cost?

Codex CLI uses 3.9M tokens per task and costs $1.50 per task. AgentBurn snapshot 2026-10-27. Every figure carries a provenance label: source-backed, derived, or left empty when no public basis exists.

What it is. OpenAI's sandboxed terminal agent that batches tool calls to keep long tasks cheap

Codex CLI drives a sandboxed workspace from the shell, planning edits, executing commands and running tests in one batched loop instead of one action per turn. On the Artificial Analysis index (GPT-6.1 Sol config) it finishes coding tasks in about 15 minutes at $1.50 per task, with prompt caching doing most of the cost saving.

Per-task metrics for Codex CLI — data snapshot 2026-10-27
Tokens per task3.9MSource-backed
Cost per task$1.50Source-backed
Success ratenot publishedNot published
Cost per solved tasknot published—
Tool calls per tasknot published—
Retry overheadnot published—
Minutes per tasknot published—
Estimated runs per day45,000 (model estimate)Model estimate

Where the tokens go

This is the per-task split AgentBurn records for Codex CLI, step by step.

StepWhat happensShare of tokensTool calls
Read task and repoParses the issue, inspects tree and existing tests10%6
Plan and locateFinds the relevant modules and drafts an edit plan12%5
Patch workspaceApplies file patches inside the sandbox24%12
Build and testRuns build, linters and the test suite in batch28%11
Repair failuresReads failing output and issues targeted fixes18%5
SummariseWrites the final diff summary and command log8%1

What each number is based on

AgentBurn labels every field. Source-backed means the cited page states the figure; derived means a formula on this page produced it; not published means no public basis exists and the field is left empty rather than estimated.

FieldBasisNote
tokensPerTaskSource-backedAA v2.0 — Codex GPT-6.1 Sol (max), 3.9M tokens/task
costPerTaskUsdSource-backedAA v2.0 — Codex GPT-6.1 Sol (max), $1.50/task
successRatePctNot publishedAA publishes benchmark scores (Index 54, FrontierCode 49%), not a task success rate.
runsPerDayModel estimateNo public source publishes daily run volume; this is a model estimate from pricing tiers and community reports, shown only in estimated-volume context.

Frequently asked

How many tokens does Codex CLI use per task?

3.9M tokens per task, per the AgentBurn snapshot dated 2026-10-27.

What does Codex CLI cost per task?

$1.50 per task, based on the source linked in the provenance table.

Is this a vendor list price?

No. It is a per-task figure from a cited source, not a rate card; the two are not comparable.

Sources

Cite this page

AgentBurn (2026-10-27). "Codex CLI". https://getagentburn.com/projects/codex-cli/

Machine-readable: projects.json · Markdown version

Related agents