Update: more runs per setting (2026-10-23 top-up)
Browse files- README.md +18 -13
- claude-code-vs-codex-tokens.csv +22 -0
- claude-code-vs-codex-tokens.json +213 -23
README.md
CHANGED
|
@@ -18,27 +18,26 @@ configs:
|
|
| 18 |
- split: train
|
| 19 |
path: claude-code-vs-codex-tokens.csv
|
| 20 |
---
|
| 21 |
-
|
| 22 |
# Claude Code vs Codex: startup tokens, MCP tools and the same coding task
|
| 23 |
|
| 24 |
Input tokens Claude Code and Codex use before doing any work, what adding 1 to 30 MCP tools adds, and tokens, time and output for the same browser-game task at medium effort.
|
| 25 |
|
| 26 |
-
**Headline:** a one-word reply costs 35,
|
| 27 |
|
| 28 |
- Source page, chart and method: https://tokensave.app/data/claude-code-vs-codex-tokens
|
| 29 |
- Related: Claude effort levels (https://tokensave.app/data/claude-effort-cost)
|
| 30 |
- DOI (Zenodo): [10.5281/zenodo.23448342](https://doi.org/10.5281/zenodo.23448342)
|
| 31 |
- Also on: [Hugging Face](https://huggingface.co/datasets/JOHNISKING/claude-code-vs-codex-tokens) · [Kaggle](https://www.kaggle.com/datasets/johnisking/claude-code-vs-codex-startup-and-task-tokens)
|
| 32 |
-
- Measured: 2026-10-18
|
| 33 |
- License: CC BY 4.0
|
| 34 |
|
| 35 |
## Key findings
|
| 36 |
|
| 37 |
-
- Claude Code starts
|
| 38 |
-
- Adding MCP tools barely changed startup tokens. The full definitions of our 30 test tools are 4,541 tokens, but adding them raised Claude Code by
|
| 39 |
-
- Using the tools is what costs: asked to list the 10 test tools and call one, Codex used 47,876 input tokens (+
|
| 40 |
-
- Same task,
|
| 41 |
-
- Claude Code wrote more code:
|
| 42 |
|
| 43 |
## Files
|
| 44 |
|
|
@@ -50,10 +49,10 @@ Input tokens Claude Code and Codex use before doing any work, what adding 1 to 3
|
|
| 50 |
|
| 51 |
| Setup | Claude Code (Opus 5.5) | Codex (gpt-6-luna) |
|
| 52 |
|---|---:|---:|
|
| 53 |
-
| 0 MCP tools | 35,
|
| 54 |
-
| 1 MCP tool | 35,
|
| 55 |
-
| 10 MCP tools | 35,
|
| 56 |
-
| 30 MCP tools | 36,
|
| 57 |
|
| 58 |
## The same coding task
|
| 59 |
|
|
@@ -65,6 +64,12 @@ Prompt: "Make a brick-breaker game that runs in the browser as a single file nam
|
|
| 65 |
| Claude Code · run 2 | 79,213 | 7,870 | 63 s | 527 | $0.39 |
|
| 66 |
| Codex · run 1 | 47,954 | 2,872 | 33 s | 49 | – |
|
| 67 |
| Codex · run 2 | 48,815 | 3,803 | 41 s | 117 | – |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 68 |
|
| 69 |
## Method
|
| 70 |
|
|
@@ -75,7 +80,7 @@ Prompt: "Make a brick-breaker game that runs in the browser as a single file nam
|
|
| 75 |
|
| 76 |
## Limitations
|
| 77 |
|
| 78 |
-
-
|
| 79 |
- Default models and per-token prices differ, so fewer tokens is not automatically cheaper.
|
| 80 |
- Startup tokens include each tool's installed skills and plugins on this machine.
|
| 81 |
- Cursor will be added when its free-plan limit resets.
|
|
|
|
| 18 |
- split: train
|
| 19 |
path: claude-code-vs-codex-tokens.csv
|
| 20 |
---
|
|
|
|
| 21 |
# Claude Code vs Codex: startup tokens, MCP tools and the same coding task
|
| 22 |
|
| 23 |
Input tokens Claude Code and Codex use before doing any work, what adding 1 to 30 MCP tools adds, and tokens, time and output for the same browser-game task at medium effort.
|
| 24 |
|
| 25 |
+
**Headline:** a one-word reply costs 35,776 input tokens in Claude Code (Opus 5.5) and 14,748 in Codex (gpt-6-luna). On the same coding task Codex used 40% fewer input tokens and 47% fewer output tokens (5 runs each). Adding 30 MCP tools barely changed either.
|
| 26 |
|
| 27 |
- Source page, chart and method: https://tokensave.app/data/claude-code-vs-codex-tokens
|
| 28 |
- Related: Claude effort levels (https://tokensave.app/data/claude-effort-cost)
|
| 29 |
- DOI (Zenodo): [10.5281/zenodo.23448342](https://doi.org/10.5281/zenodo.23448342)
|
| 30 |
- Also on: [Hugging Face](https://huggingface.co/datasets/JOHNISKING/claude-code-vs-codex-tokens) · [Kaggle](https://www.kaggle.com/datasets/johnisking/claude-code-vs-codex-startup-and-task-tokens)
|
| 31 |
+
- Measured: 2026-10-18 and 2026-10-22 (v2: 4 startup and 5 task runs per tool)
|
| 32 |
- License: CC BY 4.0
|
| 33 |
|
| 34 |
## Key findings
|
| 35 |
|
| 36 |
+
- Claude Code starts 143% heavier: 35,776 vs 14,748 (average of 4 runs) input tokens for a one-word reply. That fixed amount is sent with every request (mostly cached).
|
| 37 |
+
- Adding MCP tools barely changed startup tokens. The full definitions of our 30 test tools are 4,541 tokens, but adding them raised Claude Code by 391 tokens (about 13 per tool) and Codex by nothing measurable. Both load a tool's details only when needed.
|
| 38 |
+
- Using the tools is what costs: asked to list the 10 test tools and call one, Codex used 47,876 input tokens (+225% over its plain startup).
|
| 39 |
+
- Same task, fewer tokens on Codex: Claude Code averaged 87,779 input and 7,669 output tokens (62 s, $0.39 at API prices); Codex 52,762 input and 4,073 output tokens (56 s). All 10 games worked.
|
| 40 |
+
- Claude Code wrote more code: 474 lines on average vs 58 for Codex, which wrote denser code.
|
| 41 |
|
| 42 |
## Files
|
| 43 |
|
|
|
|
| 49 |
|
| 50 |
| Setup | Claude Code (Opus 5.5) | Codex (gpt-6-luna) |
|
| 51 |
|---|---:|---:|
|
| 52 |
+
| 0 MCP tools | 35,776 | 14,748 |
|
| 53 |
+
| 1 MCP tool | 35,792 (+16) | 14,648 (-100) |
|
| 54 |
+
| 10 MCP tools | 35,915 (+139) | 14,648 (-100) |
|
| 55 |
+
| 30 MCP tools | 36,167 (+391) | 14,648 (-100) |
|
| 56 |
|
| 57 |
## The same coding task
|
| 58 |
|
|
|
|
| 64 |
| Claude Code · run 2 | 79,213 | 7,870 | 63 s | 527 | $0.39 |
|
| 65 |
| Codex · run 1 | 47,954 | 2,872 | 33 s | 49 | – |
|
| 66 |
| Codex · run 2 | 48,815 | 3,803 | 41 s | 117 | – |
|
| 67 |
+
| Claude Code · run 3 (2026-10-22) | 79,316 | 7,897 | 62 s | 513 | $0.39 |
|
| 68 |
+
| Claude Code · run 4 | 77,868 | 6,595 | 52 s | 421 | $0.35 |
|
| 69 |
+
| Claude Code · run 5 | 78,830 | 7,447 | 60 s | 420 | $0.38 |
|
| 70 |
+
| Codex · run 3 (2026-10-22) | 70,704 | 7,118 | 75 s | 29 | – |
|
| 71 |
+
| Codex · run 4 | 48,362 | 3,468 | 72 s | 46 | – |
|
| 72 |
+
| Codex · run 5 | 47,975 | 3,103 | 57 s | 51 | – |
|
| 73 |
|
| 74 |
## Method
|
| 75 |
|
|
|
|
| 80 |
|
| 81 |
## Limitations
|
| 82 |
|
| 83 |
+
- Four startup and five task runs per tool, one task. One Claude Code task run took an extra step (123,666 input tokens) and one Codex run read 70,704.
|
| 84 |
- Default models and per-token prices differ, so fewer tokens is not automatically cheaper.
|
| 85 |
- Startup tokens include each tool's installed skills and plugins on this machine.
|
| 86 |
- Cursor will be added when its free-plan limit resets.
|
claude-code-vs-codex-tokens.csv
CHANGED
|
@@ -1,21 +1,43 @@
|
|
| 1 |
test,tool,model,mcp_tools,run,input_tokens,cached_input_tokens,output_tokens,seconds,api_cost_usd,file_lines
|
| 2 |
startup,claude_code,"claude-opus-5-5 (default, Max plan)",0,1,35765,,,,,
|
| 3 |
startup,claude_code,"claude-opus-5-5 (default, Max plan)",0,2,35777,,,,,
|
|
|
|
|
|
|
| 4 |
startup,claude_code,"claude-opus-5-5 (default, Max plan)",1,1,35790,,,,,
|
| 5 |
startup,claude_code,"claude-opus-5-5 (default, Max plan)",1,2,35790,,,,,
|
|
|
|
|
|
|
| 6 |
startup,claude_code,"claude-opus-5-5 (default, Max plan)",10,1,35913,,,,,
|
| 7 |
startup,claude_code,"claude-opus-5-5 (default, Max plan)",10,2,35913,,,,,
|
|
|
|
|
|
|
| 8 |
startup,claude_code,"claude-opus-5-5 (default, Max plan)",30,1,36165,,,,,
|
| 9 |
startup,claude_code,"claude-opus-5-5 (default, Max plan)",30,2,36165,,,,,
|
|
|
|
|
|
|
| 10 |
startup,codex,"gpt-6-luna, reasoning effort low (ChatGPT plan)",0,1,14678,,,,,
|
| 11 |
startup,codex,"gpt-6-luna, reasoning effort low (ChatGPT plan)",0,2,14678,,,,,
|
|
|
|
|
|
|
| 12 |
startup,codex,"gpt-6-luna, reasoning effort low (ChatGPT plan)",1,1,14678,,,,,
|
| 13 |
startup,codex,"gpt-6-luna, reasoning effort low (ChatGPT plan)",1,2,14678,,,,,
|
|
|
|
|
|
|
| 14 |
startup,codex,"gpt-6-luna, reasoning effort low (ChatGPT plan)",10,1,14678,,,,,
|
| 15 |
startup,codex,"gpt-6-luna, reasoning effort low (ChatGPT plan)",10,2,14678,,,,,
|
|
|
|
|
|
|
| 16 |
startup,codex,"gpt-6-luna, reasoning effort low (ChatGPT plan)",30,1,14678,,,,,
|
| 17 |
startup,codex,"gpt-6-luna, reasoning effort low (ChatGPT plan)",30,2,14678,,,,,
|
|
|
|
|
|
|
| 18 |
same_task,claude_code,"claude-opus-5-5, effort medium",0,1,123666,95504,8537,73,0.42,487
|
| 19 |
same_task,claude_code,"claude-opus-5-5, effort medium",0,2,79213,51762,7870,63,0.39,527
|
| 20 |
same_task,codex,"gpt-6-luna, reasoning effort medium",0,1,47954,29824,2872,33,,49
|
| 21 |
same_task,codex,"gpt-6-luna, reasoning effort medium",0,2,48815,37504,3803,41,,117
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
test,tool,model,mcp_tools,run,input_tokens,cached_input_tokens,output_tokens,seconds,api_cost_usd,file_lines
|
| 2 |
startup,claude_code,"claude-opus-5-5 (default, Max plan)",0,1,35765,,,,,
|
| 3 |
startup,claude_code,"claude-opus-5-5 (default, Max plan)",0,2,35777,,,,,
|
| 4 |
+
startup,claude_code,"claude-opus-5-5 (default, Max plan)",0,3,35781,,,,,
|
| 5 |
+
startup,claude_code,"claude-opus-5-5 (default, Max plan)",0,4,35781,,,,,
|
| 6 |
startup,claude_code,"claude-opus-5-5 (default, Max plan)",1,1,35790,,,,,
|
| 7 |
startup,claude_code,"claude-opus-5-5 (default, Max plan)",1,2,35790,,,,,
|
| 8 |
+
startup,claude_code,"claude-opus-5-5 (default, Max plan)",1,3,35794,,,,,
|
| 9 |
+
startup,claude_code,"claude-opus-5-5 (default, Max plan)",1,4,35794,,,,,
|
| 10 |
startup,claude_code,"claude-opus-5-5 (default, Max plan)",10,1,35913,,,,,
|
| 11 |
startup,claude_code,"claude-opus-5-5 (default, Max plan)",10,2,35913,,,,,
|
| 12 |
+
startup,claude_code,"claude-opus-5-5 (default, Max plan)",10,3,35917,,,,,
|
| 13 |
+
startup,claude_code,"claude-opus-5-5 (default, Max plan)",10,4,35917,,,,,
|
| 14 |
startup,claude_code,"claude-opus-5-5 (default, Max plan)",30,1,36165,,,,,
|
| 15 |
startup,claude_code,"claude-opus-5-5 (default, Max plan)",30,2,36165,,,,,
|
| 16 |
+
startup,claude_code,"claude-opus-5-5 (default, Max plan)",30,3,36169,,,,,
|
| 17 |
+
startup,claude_code,"claude-opus-5-5 (default, Max plan)",30,4,36169,,,,,
|
| 18 |
startup,codex,"gpt-6-luna, reasoning effort low (ChatGPT plan)",0,1,14678,,,,,
|
| 19 |
startup,codex,"gpt-6-luna, reasoning effort low (ChatGPT plan)",0,2,14678,,,,,
|
| 20 |
+
startup,codex,"gpt-6-luna, reasoning effort low (ChatGPT plan)",0,3,15018,,,,,
|
| 21 |
+
startup,codex,"gpt-6-luna, reasoning effort low (ChatGPT plan)",0,4,14618,,,,,
|
| 22 |
startup,codex,"gpt-6-luna, reasoning effort low (ChatGPT plan)",1,1,14678,,,,,
|
| 23 |
startup,codex,"gpt-6-luna, reasoning effort low (ChatGPT plan)",1,2,14678,,,,,
|
| 24 |
+
startup,codex,"gpt-6-luna, reasoning effort low (ChatGPT plan)",1,3,14618,,,,,
|
| 25 |
+
startup,codex,"gpt-6-luna, reasoning effort low (ChatGPT plan)",1,4,14618,,,,,
|
| 26 |
startup,codex,"gpt-6-luna, reasoning effort low (ChatGPT plan)",10,1,14678,,,,,
|
| 27 |
startup,codex,"gpt-6-luna, reasoning effort low (ChatGPT plan)",10,2,14678,,,,,
|
| 28 |
+
startup,codex,"gpt-6-luna, reasoning effort low (ChatGPT plan)",10,3,14618,,,,,
|
| 29 |
+
startup,codex,"gpt-6-luna, reasoning effort low (ChatGPT plan)",10,4,14618,,,,,
|
| 30 |
startup,codex,"gpt-6-luna, reasoning effort low (ChatGPT plan)",30,1,14678,,,,,
|
| 31 |
startup,codex,"gpt-6-luna, reasoning effort low (ChatGPT plan)",30,2,14678,,,,,
|
| 32 |
+
startup,codex,"gpt-6-luna, reasoning effort low (ChatGPT plan)",30,3,14618,,,,,
|
| 33 |
+
startup,codex,"gpt-6-luna, reasoning effort low (ChatGPT plan)",30,4,14618,,,,,
|
| 34 |
same_task,claude_code,"claude-opus-5-5, effort medium",0,1,123666,95504,8537,73,0.42,487
|
| 35 |
same_task,claude_code,"claude-opus-5-5, effort medium",0,2,79213,51762,7870,63,0.39,527
|
| 36 |
same_task,codex,"gpt-6-luna, reasoning effort medium",0,1,47954,29824,2872,33,,49
|
| 37 |
same_task,codex,"gpt-6-luna, reasoning effort medium",0,2,48815,37504,3803,41,,117
|
| 38 |
+
same_task,claude_code,"claude-opus-5-5, effort medium",0,3,79316,51766,7897,62,0.39,513
|
| 39 |
+
same_task,claude_code,"claude-opus-5-5, effort medium",0,4,77868,51766,6595,52,0.35,421
|
| 40 |
+
same_task,claude_code,"claude-opus-5-5, effort medium",0,5,78830,51766,7447,60,0.38,420
|
| 41 |
+
same_task,codex,"gpt-6-luna, reasoning effort medium",0,3,70704,60032,7118,75,,29
|
| 42 |
+
same_task,codex,"gpt-6-luna, reasoning effort medium",0,4,48362,37248,3468,72,,46
|
| 43 |
+
same_task,codex,"gpt-6-luna, reasoning effort medium",0,5,47975,37248,3103,57,,51
|
claude-code-vs-codex-tokens.json
CHANGED
|
@@ -2,8 +2,8 @@
|
|
| 2 |
"title": "Claude Code vs Codex: startup tokens, MCP tools and the same coding task",
|
| 3 |
"url": "https://tokensave.app/data/claude-code-vs-codex-tokens",
|
| 4 |
"license": "CC BY 4.0",
|
| 5 |
-
"measured": "2026-10-18",
|
| 6 |
-
"citation": "TokenSave (2026). Claude Code vs Codex: startup tokens, MCP tools and the same coding task [Data set]. https://
|
| 7 |
"startup": {
|
| 8 |
"prompt": "Reply with the single word OK.",
|
| 9 |
"mcp_server": "Self-written stdio MCP server (mcp_dummy.js) exposing N tracker tools, each with a one-sentence description and a 5-property input schema. Full definitions: 151 o200k tokens per tool, 4,541 for 30 tools.",
|
|
@@ -23,8 +23,20 @@
|
|
| 23 |
"mcp_tools": 0,
|
| 24 |
"run1": 35765,
|
| 25 |
"run2": 35777,
|
| 26 |
-
"avg":
|
| 27 |
-
"added_vs_no_mcp": 0
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 28 |
},
|
| 29 |
{
|
| 30 |
"tool": "claude_code",
|
|
@@ -33,8 +45,20 @@
|
|
| 33 |
"mcp_tools": 1,
|
| 34 |
"run1": 35790,
|
| 35 |
"run2": 35790,
|
| 36 |
-
"avg":
|
| 37 |
-
"added_vs_no_mcp":
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 38 |
},
|
| 39 |
{
|
| 40 |
"tool": "claude_code",
|
|
@@ -43,8 +67,20 @@
|
|
| 43 |
"mcp_tools": 10,
|
| 44 |
"run1": 35913,
|
| 45 |
"run2": 35913,
|
| 46 |
-
"avg":
|
| 47 |
-
"added_vs_no_mcp":
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 48 |
},
|
| 49 |
{
|
| 50 |
"tool": "claude_code",
|
|
@@ -53,8 +89,20 @@
|
|
| 53 |
"mcp_tools": 30,
|
| 54 |
"run1": 36165,
|
| 55 |
"run2": 36165,
|
| 56 |
-
"avg":
|
| 57 |
-
"added_vs_no_mcp":
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 58 |
},
|
| 59 |
{
|
| 60 |
"tool": "codex",
|
|
@@ -63,8 +111,20 @@
|
|
| 63 |
"mcp_tools": 0,
|
| 64 |
"run1": 14678,
|
| 65 |
"run2": 14678,
|
| 66 |
-
"avg":
|
| 67 |
-
"added_vs_no_mcp": 0
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 68 |
},
|
| 69 |
{
|
| 70 |
"tool": "codex",
|
|
@@ -73,8 +133,20 @@
|
|
| 73 |
"mcp_tools": 1,
|
| 74 |
"run1": 14678,
|
| 75 |
"run2": 14678,
|
| 76 |
-
"avg":
|
| 77 |
-
"added_vs_no_mcp":
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 78 |
},
|
| 79 |
{
|
| 80 |
"tool": "codex",
|
|
@@ -83,8 +155,20 @@
|
|
| 83 |
"mcp_tools": 10,
|
| 84 |
"run1": 14678,
|
| 85 |
"run2": 14678,
|
| 86 |
-
"avg":
|
| 87 |
-
"added_vs_no_mcp":
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 88 |
},
|
| 89 |
{
|
| 90 |
"tool": "codex",
|
|
@@ -93,13 +177,25 @@
|
|
| 93 |
"mcp_tools": 30,
|
| 94 |
"run1": 14678,
|
| 95 |
"run2": 14678,
|
| 96 |
-
"avg":
|
| 97 |
-
"added_vs_no_mcp":
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 98 |
}
|
| 99 |
]
|
| 100 |
},
|
| 101 |
"same_task": {
|
| 102 |
-
"measured": "2026-10-18",
|
| 103 |
"prompt": "Make a brick-breaker game that runs in the browser as a single file named index.html in the current folder. It needs 2 levels, a score display and 3 lives, and it must be playable with the keyboard and the mouse. Write the file and finish.",
|
| 104 |
"setup": "Each run in its own empty folder, no MCP servers. Claude Code: claude -p --effort medium --permission-mode acceptEdits --output-format json; tokens from modelUsage, cost is Claude Code list API cost. Codex: codex exec --json -s workspace-write -c model_reasoning_effort=\"medium\"; tokens from turn.completed. Time is wall-clock. Every game loaded without errors and showed 2 levels, score and 3 lives in a headless browser check.",
|
| 105 |
"rows": [
|
|
@@ -115,7 +211,8 @@
|
|
| 115 |
"api_cost_usd": 0.42,
|
| 116 |
"file_lines": 487,
|
| 117 |
"file_chars": 14992,
|
| 118 |
-
"works": true
|
|
|
|
| 119 |
},
|
| 120 |
{
|
| 121 |
"tool": "claude_code",
|
|
@@ -129,7 +226,8 @@
|
|
| 129 |
"api_cost_usd": 0.39,
|
| 130 |
"file_lines": 527,
|
| 131 |
"file_chars": 15088,
|
| 132 |
-
"works": true
|
|
|
|
| 133 |
},
|
| 134 |
{
|
| 135 |
"tool": "codex",
|
|
@@ -143,7 +241,8 @@
|
|
| 143 |
"api_cost_usd": null,
|
| 144 |
"file_lines": 49,
|
| 145 |
"file_chars": 7566,
|
| 146 |
-
"works": true
|
|
|
|
| 147 |
},
|
| 148 |
{
|
| 149 |
"tool": "codex",
|
|
@@ -157,7 +256,98 @@
|
|
| 157 |
"api_cost_usd": null,
|
| 158 |
"file_lines": 117,
|
| 159 |
"file_chars": 10045,
|
| 160 |
-
"works": true
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 161 |
}
|
| 162 |
]
|
| 163 |
}
|
|
|
|
| 2 |
"title": "Claude Code vs Codex: startup tokens, MCP tools and the same coding task",
|
| 3 |
"url": "https://tokensave.app/data/claude-code-vs-codex-tokens",
|
| 4 |
"license": "CC BY 4.0",
|
| 5 |
+
"measured": "2026-10-18 and 2026-10-22",
|
| 6 |
+
"citation": "TokenSave (2026). Claude Code vs Codex: startup tokens, MCP tools and the same coding task [Data set]. Zenodo. https://doi.org/10.5281/zenodo.23448342",
|
| 7 |
"startup": {
|
| 8 |
"prompt": "Reply with the single word OK.",
|
| 9 |
"mcp_server": "Self-written stdio MCP server (mcp_dummy.js) exposing N tracker tools, each with a one-sentence description and a 5-property input schema. Full definitions: 151 o200k tokens per tool, 4,541 for 30 tools.",
|
|
|
|
| 23 |
"mcp_tools": 0,
|
| 24 |
"run1": 35765,
|
| 25 |
"run2": 35777,
|
| 26 |
+
"avg": 35776,
|
| 27 |
+
"added_vs_no_mcp": 0,
|
| 28 |
+
"runs": [
|
| 29 |
+
35765,
|
| 30 |
+
35777,
|
| 31 |
+
35781,
|
| 32 |
+
35781
|
| 33 |
+
],
|
| 34 |
+
"run_dates": [
|
| 35 |
+
"2026-10-18",
|
| 36 |
+
"2026-10-18",
|
| 37 |
+
"2026-10-22",
|
| 38 |
+
"2026-10-22"
|
| 39 |
+
]
|
| 40 |
},
|
| 41 |
{
|
| 42 |
"tool": "claude_code",
|
|
|
|
| 45 |
"mcp_tools": 1,
|
| 46 |
"run1": 35790,
|
| 47 |
"run2": 35790,
|
| 48 |
+
"avg": 35792,
|
| 49 |
+
"added_vs_no_mcp": 16,
|
| 50 |
+
"runs": [
|
| 51 |
+
35790,
|
| 52 |
+
35790,
|
| 53 |
+
35794,
|
| 54 |
+
35794
|
| 55 |
+
],
|
| 56 |
+
"run_dates": [
|
| 57 |
+
"2026-10-18",
|
| 58 |
+
"2026-10-18",
|
| 59 |
+
"2026-10-22",
|
| 60 |
+
"2026-10-22"
|
| 61 |
+
]
|
| 62 |
},
|
| 63 |
{
|
| 64 |
"tool": "claude_code",
|
|
|
|
| 67 |
"mcp_tools": 10,
|
| 68 |
"run1": 35913,
|
| 69 |
"run2": 35913,
|
| 70 |
+
"avg": 35915,
|
| 71 |
+
"added_vs_no_mcp": 139,
|
| 72 |
+
"runs": [
|
| 73 |
+
35913,
|
| 74 |
+
35913,
|
| 75 |
+
35917,
|
| 76 |
+
35917
|
| 77 |
+
],
|
| 78 |
+
"run_dates": [
|
| 79 |
+
"2026-10-18",
|
| 80 |
+
"2026-10-18",
|
| 81 |
+
"2026-10-22",
|
| 82 |
+
"2026-10-22"
|
| 83 |
+
]
|
| 84 |
},
|
| 85 |
{
|
| 86 |
"tool": "claude_code",
|
|
|
|
| 89 |
"mcp_tools": 30,
|
| 90 |
"run1": 36165,
|
| 91 |
"run2": 36165,
|
| 92 |
+
"avg": 36167,
|
| 93 |
+
"added_vs_no_mcp": 391,
|
| 94 |
+
"runs": [
|
| 95 |
+
36165,
|
| 96 |
+
36165,
|
| 97 |
+
36169,
|
| 98 |
+
36169
|
| 99 |
+
],
|
| 100 |
+
"run_dates": [
|
| 101 |
+
"2026-10-18",
|
| 102 |
+
"2026-10-18",
|
| 103 |
+
"2026-10-22",
|
| 104 |
+
"2026-10-22"
|
| 105 |
+
]
|
| 106 |
},
|
| 107 |
{
|
| 108 |
"tool": "codex",
|
|
|
|
| 111 |
"mcp_tools": 0,
|
| 112 |
"run1": 14678,
|
| 113 |
"run2": 14678,
|
| 114 |
+
"avg": 14748,
|
| 115 |
+
"added_vs_no_mcp": 0,
|
| 116 |
+
"runs": [
|
| 117 |
+
14678,
|
| 118 |
+
14678,
|
| 119 |
+
15018,
|
| 120 |
+
14618
|
| 121 |
+
],
|
| 122 |
+
"run_dates": [
|
| 123 |
+
"2026-10-18",
|
| 124 |
+
"2026-10-18",
|
| 125 |
+
"2026-10-22",
|
| 126 |
+
"2026-10-22"
|
| 127 |
+
]
|
| 128 |
},
|
| 129 |
{
|
| 130 |
"tool": "codex",
|
|
|
|
| 133 |
"mcp_tools": 1,
|
| 134 |
"run1": 14678,
|
| 135 |
"run2": 14678,
|
| 136 |
+
"avg": 14648,
|
| 137 |
+
"added_vs_no_mcp": -100,
|
| 138 |
+
"runs": [
|
| 139 |
+
14678,
|
| 140 |
+
14678,
|
| 141 |
+
14618,
|
| 142 |
+
14618
|
| 143 |
+
],
|
| 144 |
+
"run_dates": [
|
| 145 |
+
"2026-10-18",
|
| 146 |
+
"2026-10-18",
|
| 147 |
+
"2026-10-22",
|
| 148 |
+
"2026-10-22"
|
| 149 |
+
]
|
| 150 |
},
|
| 151 |
{
|
| 152 |
"tool": "codex",
|
|
|
|
| 155 |
"mcp_tools": 10,
|
| 156 |
"run1": 14678,
|
| 157 |
"run2": 14678,
|
| 158 |
+
"avg": 14648,
|
| 159 |
+
"added_vs_no_mcp": -100,
|
| 160 |
+
"runs": [
|
| 161 |
+
14678,
|
| 162 |
+
14678,
|
| 163 |
+
14618,
|
| 164 |
+
14618
|
| 165 |
+
],
|
| 166 |
+
"run_dates": [
|
| 167 |
+
"2026-10-18",
|
| 168 |
+
"2026-10-18",
|
| 169 |
+
"2026-10-22",
|
| 170 |
+
"2026-10-22"
|
| 171 |
+
]
|
| 172 |
},
|
| 173 |
{
|
| 174 |
"tool": "codex",
|
|
|
|
| 177 |
"mcp_tools": 30,
|
| 178 |
"run1": 14678,
|
| 179 |
"run2": 14678,
|
| 180 |
+
"avg": 14648,
|
| 181 |
+
"added_vs_no_mcp": -100,
|
| 182 |
+
"runs": [
|
| 183 |
+
14678,
|
| 184 |
+
14678,
|
| 185 |
+
14618,
|
| 186 |
+
14618
|
| 187 |
+
],
|
| 188 |
+
"run_dates": [
|
| 189 |
+
"2026-10-18",
|
| 190 |
+
"2026-10-18",
|
| 191 |
+
"2026-10-22",
|
| 192 |
+
"2026-10-22"
|
| 193 |
+
]
|
| 194 |
}
|
| 195 |
]
|
| 196 |
},
|
| 197 |
"same_task": {
|
| 198 |
+
"measured": "2026-10-18 (runs 1-2) and 2026-10-22 (runs 3-5)",
|
| 199 |
"prompt": "Make a brick-breaker game that runs in the browser as a single file named index.html in the current folder. It needs 2 levels, a score display and 3 lives, and it must be playable with the keyboard and the mouse. Write the file and finish.",
|
| 200 |
"setup": "Each run in its own empty folder, no MCP servers. Claude Code: claude -p --effort medium --permission-mode acceptEdits --output-format json; tokens from modelUsage, cost is Claude Code list API cost. Codex: codex exec --json -s workspace-write -c model_reasoning_effort=\"medium\"; tokens from turn.completed. Time is wall-clock. Every game loaded without errors and showed 2 levels, score and 3 lives in a headless browser check.",
|
| 201 |
"rows": [
|
|
|
|
| 211 |
"api_cost_usd": 0.42,
|
| 212 |
"file_lines": 487,
|
| 213 |
"file_chars": 14992,
|
| 214 |
+
"works": true,
|
| 215 |
+
"measured": "2026-10-18"
|
| 216 |
},
|
| 217 |
{
|
| 218 |
"tool": "claude_code",
|
|
|
|
| 226 |
"api_cost_usd": 0.39,
|
| 227 |
"file_lines": 527,
|
| 228 |
"file_chars": 15088,
|
| 229 |
+
"works": true,
|
| 230 |
+
"measured": "2026-10-18"
|
| 231 |
},
|
| 232 |
{
|
| 233 |
"tool": "codex",
|
|
|
|
| 241 |
"api_cost_usd": null,
|
| 242 |
"file_lines": 49,
|
| 243 |
"file_chars": 7566,
|
| 244 |
+
"works": true,
|
| 245 |
+
"measured": "2026-10-18"
|
| 246 |
},
|
| 247 |
{
|
| 248 |
"tool": "codex",
|
|
|
|
| 256 |
"api_cost_usd": null,
|
| 257 |
"file_lines": 117,
|
| 258 |
"file_chars": 10045,
|
| 259 |
+
"works": true,
|
| 260 |
+
"measured": "2026-10-18"
|
| 261 |
+
},
|
| 262 |
+
{
|
| 263 |
+
"tool": "claude_code",
|
| 264 |
+
"tool_name": "Claude Code 2.1.295",
|
| 265 |
+
"model": "claude-opus-5-5, effort medium",
|
| 266 |
+
"run": 3,
|
| 267 |
+
"input_tokens": 79316,
|
| 268 |
+
"cached_input_tokens": 51766,
|
| 269 |
+
"output_tokens": 7897,
|
| 270 |
+
"seconds": 62,
|
| 271 |
+
"api_cost_usd": 0.3887,
|
| 272 |
+
"file_lines": 513,
|
| 273 |
+
"file_chars": 14756,
|
| 274 |
+
"works": true,
|
| 275 |
+
"measured": "2026-10-22"
|
| 276 |
+
},
|
| 277 |
+
{
|
| 278 |
+
"tool": "claude_code",
|
| 279 |
+
"tool_name": "Claude Code 2.1.295",
|
| 280 |
+
"model": "claude-opus-5-5, effort medium",
|
| 281 |
+
"run": 4,
|
| 282 |
+
"input_tokens": 77868,
|
| 283 |
+
"cached_input_tokens": 51766,
|
| 284 |
+
"output_tokens": 6595,
|
| 285 |
+
"seconds": 52,
|
| 286 |
+
"api_cost_usd": 0.3511,
|
| 287 |
+
"file_lines": 421,
|
| 288 |
+
"file_chars": 12034,
|
| 289 |
+
"works": true,
|
| 290 |
+
"measured": "2026-10-22"
|
| 291 |
+
},
|
| 292 |
+
{
|
| 293 |
+
"tool": "claude_code",
|
| 294 |
+
"tool_name": "Claude Code 2.1.295",
|
| 295 |
+
"model": "claude-opus-5-5, effort medium",
|
| 296 |
+
"run": 5,
|
| 297 |
+
"input_tokens": 78830,
|
| 298 |
+
"cached_input_tokens": 51766,
|
| 299 |
+
"output_tokens": 7447,
|
| 300 |
+
"seconds": 60,
|
| 301 |
+
"api_cost_usd": 0.3758,
|
| 302 |
+
"file_lines": 420,
|
| 303 |
+
"file_chars": 13618,
|
| 304 |
+
"works": true,
|
| 305 |
+
"measured": "2026-10-22"
|
| 306 |
+
},
|
| 307 |
+
{
|
| 308 |
+
"tool": "codex",
|
| 309 |
+
"tool_name": "Codex CLI 0.162",
|
| 310 |
+
"model": "gpt-6-luna, reasoning effort medium",
|
| 311 |
+
"run": 3,
|
| 312 |
+
"input_tokens": 70704,
|
| 313 |
+
"cached_input_tokens": 60032,
|
| 314 |
+
"output_tokens": 7118,
|
| 315 |
+
"seconds": 75,
|
| 316 |
+
"api_cost_usd": null,
|
| 317 |
+
"file_lines": 29,
|
| 318 |
+
"file_chars": 9756,
|
| 319 |
+
"works": true,
|
| 320 |
+
"measured": "2026-10-22"
|
| 321 |
+
},
|
| 322 |
+
{
|
| 323 |
+
"tool": "codex",
|
| 324 |
+
"tool_name": "Codex CLI 0.162",
|
| 325 |
+
"model": "gpt-6-luna, reasoning effort medium",
|
| 326 |
+
"run": 4,
|
| 327 |
+
"input_tokens": 48362,
|
| 328 |
+
"cached_input_tokens": 37248,
|
| 329 |
+
"output_tokens": 3468,
|
| 330 |
+
"seconds": 72,
|
| 331 |
+
"api_cost_usd": null,
|
| 332 |
+
"file_lines": 46,
|
| 333 |
+
"file_chars": 9368,
|
| 334 |
+
"works": true,
|
| 335 |
+
"measured": "2026-10-22"
|
| 336 |
+
},
|
| 337 |
+
{
|
| 338 |
+
"tool": "codex",
|
| 339 |
+
"tool_name": "Codex CLI 0.162",
|
| 340 |
+
"model": "gpt-6-luna, reasoning effort medium",
|
| 341 |
+
"run": 5,
|
| 342 |
+
"input_tokens": 47975,
|
| 343 |
+
"cached_input_tokens": 37248,
|
| 344 |
+
"output_tokens": 3103,
|
| 345 |
+
"seconds": 57,
|
| 346 |
+
"api_cost_usd": null,
|
| 347 |
+
"file_lines": 51,
|
| 348 |
+
"file_chars": 8660,
|
| 349 |
+
"works": true,
|
| 350 |
+
"measured": "2026-10-22"
|
| 351 |
}
|
| 352 |
]
|
| 353 |
}
|