August 23, 2026 · 8 min read

opencode Alternative: We Measured the Cost per Task, and It Is 40 Percent Lower

Every coding agent claims to be efficient. Almost nobody publishes the bill. So we ran the experiment that settles it for at least one task: the same bugfix, the same model, the same API, the same prices, and a byte identical prompt, once through opencode and once through the coding agent inside Locally Uncensored.

The short version: opencode averaged 2157 credits across three runs. Locally Uncensored 2.6.6 finished the identical task for 1298. That is roughly 40 percent less, and even the cheapest opencode run was 29 percent above our number.

The longer version, including the reason, the raw counts and everything this measurement does not prove, is below.

The Setup

A cost comparison is only worth reading if the things that drive cost are held still. Here is what was fixed:

Held constantValue
TaskFix a failing test in a small npm repository, then commit
RepositoryThree files, a one line bug in add.js, tests red at the start
PromptByte identical, sha256 29cec6c3...cf62687
Modeldeepseek-ai/DeepSeek-V3.2
EndpointThe same OpenAI compatible API for both agents
PricesSame account, same tier, same per token rate
CountingOne wire proxy in front of the API, credits read before and after each run
opencode version1.18.21, installed from npm, default settings

Success was defined before the runs, not after: npm test has to pass, there has to be exactly one commit with the required message, only add.js may change, and the working tree has to be clean at the end. All four runs met that bar. Nobody failed and nobody cheated, so cost is the only variable that moved.

The Numbers

RunCreditsRequestsPrompt tokensSuccess
opencode, run 11679898,789yes
opencode, run 2243311146,058yes
opencode, run 3235811146,387yes
Locally Uncensored 2.6.612981674,629yes
Locally Uncensored 2.6.5439530257,270yes

Read the last row before you read anything else. Our own agent from one release earlier was the most expensive thing in this table by a wide margin. We are not printing a chart where we happen to win by design. We are printing a chart that shows what an efficiency pass is worth, and the version of our own software that predates it is the loser.

Across the three opencode runs the mean is 2157 credits. Against 1298, that makes opencode cost 1.66 times as much for the same finished work.

Why the Gap Exists

The tempting explanation is that one agent is smarter and needs fewer steps. That is not what happened, and the direction is the opposite of what you would guess.

opencode took fewer turns than we did. Eight to eleven requests against our sixteen. If you counted steps, opencode wins. The bill went the other way because of what each individual request carries.

Per requestopencodeLocally Uncensored 2.6.6
Prompt tokens per request12,349 to 13,3084,664
Tool catalogue size21,188 bytes7,703 bytes
Credits per prompt token0.01700 / 0.01666 / 0.016110.01739

That last row is the honest part. The billing rate is the same. Nobody is getting a secret discount. Credits per token are within a few percent of each other in every run, and ours is marginally the highest of the four. The entire difference in the final bill is the number of tokens pushed through, not the price of a token.

Two things drive that volume. The first is the fixed block that rides along on every single call. A tool catalogue of 21,188 bytes against 7,703 bytes is roughly three times the standing overhead, paid again on every request in the loop, whether the model needs those tools or not. The second is context decay: as an agent works, the transcript grows, and old tool output that no longer matters keeps getting resent at full length unless something actively trims it.

Put together, a fixed block that large pushes every opencode request above 12,000 tokens. Six agent steps at that weight already approach our total consumption for the whole task.

What Changed Between 2.6.5 and 2.6.6

The 4395 in the table is not a strawman, it is our shipped agent from the previous release. Between 2.6.5 and 2.6.6 we went after exactly the two things above: the size of the fixed block and the length of what gets resent. Measured across the same set of tool driven runs, that cut credit consumption by 78.6 percent, and on the longest run in the set by 80.4 percent. The comparison above is what fell out of that work when we pointed it at somebody else.

Limits of This Benchmark

This is where most vendor benchmarks stop talking. We would rather you know exactly how far the number carries.

What the measurement does support is a narrower claim than the headline suggests: on short, well scoped agent tasks, opencode can hardly land below us, because the fixed per request overhead sets a floor. Even its best run, with only eight requests, still needed 98,789 tokens.

Credit Where It Is Due

opencode finished the job three times out of three, took fewer turns than we did, and produced clean diffs with the right commit message each time. It is a genuinely good agent and it is open source. The numbers here are about token accounting inside the loop, not about whether it works. If you use it and you are happy, this article is not an argument that you should stop.

It is an argument that you should measure. Agent bills are made of tokens you never see, and the difference between two tools that both look fast can be a factor of 1.66 on the invoice.

Where This Fits

The coding agent is one lane inside Locally Uncensored, a desktop AI studio that also runs chat, image and video locally. You can point the agent at a hosted model like the DeepSeek V3.2 we benchmarked here, or at a model on your own GPU with no API bill at all. If you want the local route, the Qwen 3.8 27B guide covers the size that fits a 24 GB card, and the 2026 model roundup covers what else is worth your VRAM. The setup guide walks the install from zero.

FAQ

Is there a cheaper alternative to opencode?

On the task we measured, yes. Locally Uncensored 2.6.6 finished for 1298 credits against an opencode average of 2157, about 40 percent less, and the cheapest opencode run still sat 29 percent above us. One scenario, so treat it as a data point rather than a law.

How much does opencode cost per task?

opencode is free software. The bill is the model. On this one line bugfix with DeepSeek V3.2 the three runs cost 1679, 2433 and 2358 credits, a spread of 45 percent between cheapest and dearest.

Why does opencode use so many tokens?

Not through extra steps, it used fewer than we did. Each request carries more: 12,349 to 13,308 prompt tokens against our 4,664, with a tool catalogue of 21,188 bytes against 7,703 resent on every call.

Is the billing rate the same for both agents?

Yes, which is the point. Credits per prompt token came out at 0.01739 for us and 0.01700, 0.01666 and 0.01611 for opencode. Effectively identical, so the gap is volume, not price.

Does a cheaper coding agent do worse work?

Not here. All four runs passed the same bar: test green, one correct commit, only the intended file touched, clean tree. On a harder task the picture could differ, and we did not measure that.

Can I reproduce this benchmark myself?

Yes. Three file npm repo with a red test, prompt pinned at sha256 29cec6c3...cf62687, model deepseek-ai/DeepSeek-V3.2, opencode 1.18.21 at defaults, requests counted through a wire proxy and credits read before and after each run.

Getting Started

The agent ships inside the app, and the app is free and open source. Point it at a hosted model or at one running on your own card:

git clone https://github.com/PurpleDoubleD/locally-uncensored.git
cd locally-uncensored
# Windows: setup.bat | Linux: ./setup.sh

Or take the installer from the releases page. No account is required for the local path, and nothing leaves your machine.


Locally Uncensored is AGPL-3.0 licensed and free to use. Built by PurpleDoubleD.

An agent that reads your codebase without reading your wallet.

Get Started on GitHub