Code Tycoon Get Code Tycoon

Blog / Cost

Cost Per Committed Task: Benchmarking Your Claude Code Use

Cost per session hides what you got. Our 792 sessions show a $3.28 median overall and $6.59 for sessions that committed. How to measure yours, with caveats.

Cost Per Committed Task: Benchmarking Your Claude Code Use

In our transcripts, the median Claude Code session cost $3.28 at API list price. The median session that ended up making a git commit cost $6.59, about twice as much. Cost per session is the number every tool shows. It is the wrong denominator.

Most Claude Code cost reporting divides money by sessions, or by days, or by tokens. None of those tells you whether the money bought anything. A session can cost $40 and produce nothing, or cost $2 and produce a fix you ship before lunch. This post argues for a different unit, cost per committed task, shows what we can and cannot say about it from our own data, and gives you a way to measure your own.

The data is from our own transcripts and is not a benchmark of Claude Code in general. Method and caveats come first, because the numbers mean little without them. Where we do not have a number, we say so and do not make one up.

Table of contents

Key findings

  • Across 792 sessions, the median cost was $3.28, with a 25th percentile of $1.78, a 75th of $7.96, a 90th of $17.35 and a maximum of $144.47. (Our transcript data)
  • 306 of the 792 sessions ran git commit at least once. That is about 39% (306 divided by 792). (Our transcript data)
  • The median cost of a session that committed was $6.59, against $3.28 for all sessions. That is about 2.0 times as much. (Our transcript data)
  • The gap is expected: sessions that produce a commit tend to be bigger, with more prompts, more edits and more context re-read. It is not evidence that spending more makes a commit more likely. (Our reading)
  • A median session had 2 prompts and the mean was 3.5, because many of our sessions are single tasks handed off by a task board. (Our transcript data)
  • We do not have a per-task total for committed work, a cost per commit, or any measure of quality. We say what that would take in the last section.

Methodology

The data comes from the Claude Code transcript files on our own setup. Only aggregates were kept; no prompt text, file names or project names are used here.

  • Period: 2026-10-02 to 2026-11-23, about 7.5 weeks.
  • Who: one small team running its own products, the 17 sites listed on the Code Tycoon homepage plus Code Tycoon itself.
  • Size: 792 sessions with model usage and 54,344 model requests, counted from 1,036 transcript files.
  • Cost: the API list-price equivalent, not what we were billed. We multiplied tokens by Anthropic's published per-million-token prices: Opus 5.5 at $4 input, $20 output and $0.20 cache read; Sonnet 5.5 at $2, $10 and $0.10; Haiku 5.5 at $0.10 input and $0.50 output. Cache writes are 1.25 times input for the 5-minute cache and 2 times for the 1-hour cache. The current price table is on Anthropic's pricing page. Someone on a Pro or Max plan pays a flat fee, so this figure shows the value of the usage and not a bill.
  • Counting: each API message is counted once, deduplicated by message id. Subagent requests are included.
  • A committing session: a session that ran git commit at least once. The measure counts that a commit happened, not what it contained: its size, its files and whether it was kept are not part of it.

Limits to keep in mind:

  1. One team, one setup, about 7.5 weeks.
  2. 99.2% of the cost came from one model, Opus 5.5 ($5,952 of a $5,998 total). A team that uses Sonnet heavily would see a different profile.
  3. Many of our sessions are single tasks, with a median of 2 prompts. If you work in long conversational sessions, session counts and costs will look different.
  4. Cost here is list price. Claude Code's own figure is also an estimate: the costs docs say it "computes the dollar figure locally from token counts at list price", and that on Pro, Max and Ultra plans the figure "isn't relevant for billing purposes".

For the full cost breakdown from the same data, see What does Claude Code really cost per month.

Why cost per session misleads

Per-session cost is easy to compute, and it hides three things.

Sessions are not the same size of work. A session can be one prompt or forty. Our median was 2 prompts and our mean was 3.5, so the mean is pulled up by a long tail. Averaging cost over a mix like that tells you about your habits of splitting work, not about efficiency. If you move to one task per session, your cost per session drops and your cost per task does not move.

Sessions are not all supposed to produce code. Some are research, some are code review, some are a quick question about a repository. Those are legitimate uses and they cost money. A metric that counts only sessions that produced a commit would make them look wasteful. A metric that ignores commits cannot tell them apart from a run that went nowhere.

Cost per session rewards the wrong behavior. Aim at a lower cost per session and you will stop sessions early, split a task in two, or avoid long contexts that were doing real work. Aim at a lower cost per delivered task and the incentive is to finish things. For a deeper look at why long contexts cost what they do, see Claude Code prompt caching and cold resumes.

The unit that matches what you care about is a finished task: something you can point to in git. That is what we mean by a committed task.

What the data shows

Measure All sessions Sessions that committed
Number of sessions 792 306 (about 39%)
Median cost per session (API list price) $3.28 $6.59
Ratio 1.0 about 2.0

Two reads of the table, one safe and one not.

The safe one: in our usage, sessions that committed cost more than the typical session, at the median about twice as much. If you want a cost per committed session for your own work, expect it to be higher than your overall median, and do not be alarmed when it is.

The unsafe one: "spending more makes commits more likely". The table cannot show that. The arrow of cause probably runs the other way. Work that ends in a commit is work with a clear goal: the agent reads code, plans, edits several files, runs tests, fixes failures, and commits. That is more requests and more context than a one-off question. Sessions that do not commit include the cheap ones, such as a quick lookup, and the expensive ones that did not work. The median hides the difference between those two groups.

What we cannot say from this data:

  • Total cost of committed work. We have the median cost of a committing session, not the sum. Dividing total spend by commits would mix in all the sessions that did not commit, so we report the median instead.
  • Cost per commit. A session can make several commits and several sessions can contribute to one. Cost per commit is a different number from cost per committed session, which is what this post measures.
  • Cost per task. A task can span sessions. Our task board hands off many single-session tasks, which makes sessions a decent proxy for us, but the proxy may not hold for you.
  • Quality. A commit says nothing about whether the change was right, reviewed or shipped.

What a commit does and does not prove

A commit is an imperfect marker of completed work, and you should know which way it fails.

It over-counts. Claude Code can commit a half-finished change, a fix that fails in production, or a revert of its own earlier commit. Each is a commit. A session that commits three times in a row because the first two were wrong counts as "committed", and cost per committed session cannot see that.

It under-counts. Some valuable sessions end with no commit: a debugging session that finds the cause and hands you the answer, a design discussion, a review that changes your mind. If part of your work is exploration, your committed share will look low and that is not a problem.

It depends on your habits. If you tell Claude Code to commit as it goes, you will see more commits per session. If you commit by hand at the end of the day, the session transcript may show none at all, and your committed share will be near zero for a reason that has nothing to do with productivity. Check how you work before you compare.

We use "commit" because it is cheap to detect and hard to fake by accident. We would not use it as a performance target. If you reward commits, you will get commits.

For the other half of the picture, whether the commit was any good, see Reviewing what Claude Code changed today.

How to measure your own

You can get a rough cost per committed task from tools you already have. Three levels, from least to most effort.

Level 1: by hand, one week

  1. Pick a week. Write down your Claude Code spend for it. If you use the API or the JSON output of claude -p, total_cost_usd gives a per-run estimate (headless docs). On a subscription, the figure is an estimate of value, not a bill, as above.
  2. Count your commits for the same week and the same repositories:
git log --since="7 days ago" --no-merges --oneline | wc -l
  1. Divide. That is a cost per commit for the week, with all the caveats above. It is crude and it is a start.

Level 2: by session

The transcripts Claude Code writes are the raw material. The docs say where transcripts are stored. For each session you want three things: its cost, whether it ran git commit, and the number of prompts. With those you can compute the median cost of a committing session against the median of all sessions, which is the comparison in this post.

Tools that read transcripts can do this for you, and we compare them in ccusage vs the /cost command vs Code Tycoon. Check what the one you pick actually reports before you rely on it, because per-session cost is common and per-commit is not.

Level 3: by task

If you manage work through a board or a task list, record the task id in your prompts or commit messages. Then group sessions and commits by task id, and sum the cost. That gives you cost per finished task, which is the number this post is really about. It takes discipline, because the grouping is only as good as the habit of tagging. One way to keep the record is a task manager that writes a report for every finished task, as Code Tycoon's does.

What to compare against

You have three honest comparisons, and none of them is another team's number.

Your own history. Track the median cost of a committing session, and the share of sessions that commit, week over week. A change tells you something; the level alone does not.

Your own model choices. Switch a class of task from Opus to Sonnet and see what happens to cost per committed session and to how much of the output you have to redo. We compare the two on cost in Opus vs Sonnet for Claude Code. In our own data one model accounts for 99.2% of cost, so we cannot offer a comparison from it.

Your own habits. Context size and idle gaps change cost. In our data, requests with more than 200k tokens of context were 45.5% of requests and 63.8% of cost, and cold resumes after a gap of more than an hour added $681 of cache rewrites, 11.4% of the total. Fixing those changes cost per committed task without changing what you ship. See what Claude Code costs per month for the breakdown.

We deliberately give no "good" or "bad" threshold. We have one dataset, from one team, mostly on one model. A threshold built on it would be a number invented to look useful. If you want an outside reference for what a developer day costs, the Claude Code docs quote a figure for enterprise use, and you can read it in the costs documentation, but that is a different measure and we do not compare ours to it.

If you are on a plan rather than the API, the constraint is limits, not dollars. In that case the same idea applies with a different currency: how much of your weekly allowance does a committed task use? See Claude Code usage limits explained and Claude Pro vs Max 5x vs Max 20x.

What would make it better

A fuller study would add:

  • Per-task sums, not per-session medians, so a task spanning several sessions counts once.
  • A quality signal, such as whether the commit was later reverted or whether CI passed. Our task log records whether a test or type check passed after a change, which is a start.
  • More than one team and more than one model mix, so the result is not an account of one setup.
  • A longer period. about 7.5 weeks is enough to see a pattern, not enough to see a trend.

Until then, treat the figures in this post as one data point and the method as the useful part.

FAQ

What is cost per committed task?

The money spent on the Claude Code sessions that produced a finished, committed piece of work, divided by the number of such pieces. We use a committing session as a stand-in for a task. It is a rough proxy, and a commit does not prove quality.

How much did a committing session cost in your data?

The median was $6.59 at API list price, against $3.28 for all sessions. 306 of 792 sessions committed. The data is from one team over about 7.5 weeks and is not a general benchmark.

Is a higher cost per committed task bad?

Not by itself. Bigger tasks cost more. Compare against your own history and against the same kind of task, not against another team.

Does a commit mean the work was good?

No. A commit can be half-finished, wrong or reverted later. It is cheap to detect, which is why it is useful as a marker, and why it is a poor performance target.

Can I measure this on a Pro or Max plan?

You can measure sessions, commits and prompts. Dollar figures are estimates of usage value, since you pay a flat fee, so measure against your weekly limits as well.

How do I count commits for a period?

For a repository, git log --since="7 days ago" --no-merges --oneline | wc -l counts non-merge commits in the last week. Run it in each repository you use.

Why not just track tokens?

Tokens are an input. They do not tell you what you got, and the mix matters: in our data most of the cost came from re-reading context, not from output.

Conclusion

Cost per session is easy to compute and easy to misread. Cost per committed task is closer to what you care about, and it takes a little work to measure. In our own 792 sessions the median committing session cost $6.59 against $3.28 overall, which says that work that ends in a commit is bigger work, not that it is wasteful. Measure your own for a week, compare with yourself, and do not use a commit count as a target. To see these numbers for your own sessions, self-host Code Tycoon is free.

Related articles


About this research

Code Tycoon runs Claude Code and Codex sessions on a dedicated server and maps, prices and tracks them. The figures come from one small team's Claude Code transcripts across seventeen products, 2026-10-02 to 2026-11-23, aggregated with a script and kept without prompt text, file names or project names. They are priced at API list rates and are not a bill. The two ratios in this post (39% committed, about 2.0 times) are plain arithmetic on those aggregates. Verify prices on Anthropic's pricing page.

Content reviewed and updated: 2026-11-26


Keep reading