DeepSeek V4 Flash vs. Claude Haiku, Sonnet, and Opus: A Coding Review
The question isn’t which model wins
DeepSeek pushed the official deepseek-v4-flash API into public beta on July 31, 2026, and immediately claimed its cheap tier now beats DeepSeek’s own more expensive V4-Pro-Preview on agent benchmarks. Then, on August 13, 2026 (the announcement that landed in most feeds on Friday, August 14), DeepSeek took V4-Pro to general availability and, in the same update, gave both V4-Pro and V4-Flash a shared low, high, and max thinking effort control and moved both models onto a new peak and off peak pricing schedule that takes effect August 16. Worth being precise about that last update: it changed how Flash is priced and controlled, not the model itself. The version string is still DeepSeek-V4-Flash-0731, so Flash’s own weights and agent benchmarks haven’t moved since July 31. This review covers Flash as it stands today, which means the July post training numbers plus the pricing and control changes that shipped around Friday’s announcement.
That invites the obvious framing: does the cheapest serious coding model on the market beat Anthropic’s three tier Claude lineup of Haiku 4.5, Sonnet 5, and Opus 5?
That framing is the wrong one, and this review ends up arguing against it. Opus 5 is currently positioned by Anthropic as its strongest generally available model for difficult, long running agentic work, and nothing here disputes that. DeepSeek is simultaneously demonstrating that surprisingly capable agentic execution can be delivered at a small fraction of the token price. Those two facts don’t compete with each other so much as answer different questions. The interesting question isn’t “is DeepSeek better than Claude.” It’s closer to “why would you pay Opus prices for work that Flash can do,” and, just as importantly, “why would you save pennies on inference on work where a wrong answer costs hours of engineering time.” By the end, that tension matters more than any single benchmark score.
A note on methodology before the numbers. Public benchmark reporting in this space is messy, since different outlets run the same model through different harnesses, temperatures, and problem subsets, and scores for the same model can vary by 10 to 20 points across trackers. Where possible, the figures below come from the model vendors’ own announcements (Anthropic’s launch posts, DeepSeek’s API changelog) or from a single consistent third party source, and are marked accordingly. Treat any single number as directional, not gospel, and treat any table that mixes sources as a rough sketch rather than a leaderboard.
The lineup
| Model | Vendor claim to fame | Released |
|---|---|---|
| DeepSeek V4 Flash (0731) | Cheap MoE model, given a fresh round of post training for agentic and coding gains, 1M context | Public beta July 31, 2026; pricing and thinking effort controls updated August 13 to 16, 2026 |
| Claude Haiku 4.5 | Fastest/cheapest Claude, “near-frontier” at a fraction of the cost | Oct 2025 |
| Claude Sonnet 5 | Mid tier workhorse, closes most of the gap to Opus | June 2026 |
| Claude Opus 5 | Anthropic’s flagship, frontier agentic coding | July 24, 2026 |
The extraordinary price gap
This is where the story gets lopsided. DeepSeek announced a new peak and off peak pricing model alongside V4-Pro’s GA launch on August 13, and it takes effect at 16:00 UTC on August 16, 2026. Anthropic’s pricing stays flat by comparison, with no time of day component at all. The rates below are DeepSeek’s own numbers from its API pricing page.
| Model | Input | Cache hit input | Output |
|---|---|---|---|
| DeepSeek V4 Flash, off peak | $0.22 | $0.007 | $0.66 |
| DeepSeek V4 Flash, peak (01:00 to 04:00 and 06:00 to 10:00 UTC) | $0.44 | $0.014 | $1.32 |
| Claude Haiku 4.5 | $1.00 | $0.10 | $5.00 |
| Claude Sonnet 5 | $2.00 | $0.20 | $10.00 |
| Claude Opus 5 | $5.00 | $0.50 | $25.00 |
Even at peak pricing, DeepSeek V4 Flash’s output rate runs roughly 4x cheaper than Haiku 4.5, 7.5x cheaper than Sonnet 5, and 19x cheaper than Opus 5. Off peak, those gaps widen to roughly 7.5x, 15x, and 38x. All four models support prompt caching, and Anthropic also offers batch processing at a further 50% off, and while those discounts compound, they don’t change the relative ordering.
Anthropic’s Sonnet 5 pricing is worth flagging on its own. The $2/$10 rate launched as “introductory” through August 31, 2026, and Anthropic has since confirmed the scheduled increase to $3/$15 will not happen, so $2/$10 is now the standard price.
One caveat that makes this section harder to attack: token prices aren’t perfectly fungible across models. Anthropic notes that Sonnet 5’s newer tokenizer produces roughly 30% more tokens for the same text than the previous generation, so a lower rate per token doesn’t translate one to one into a proportionally lower workload cost. Treat the numbers above as API rate comparisons, not guaranteed workload cost ratios.
Terminal-Bench: cheap models are getting seriously agentic
This is arguably the strongest comparison in the whole piece, so it comes first. Terminal-Bench 2.1 is the closest thing to a “Linux and Bash” benchmark in wide use. It scores models on long horizon tasks executed inside a real terminal.
| Model | Terminal-Bench 2.1 | Source |
|---|---|---|
| Claude Opus 4.8 | 84.6% | Third party leaderboard (BenchLM.ai / CodingFleet) |
| DeepSeek V4 Flash | 82.7% | DeepSeek’s own reported figure (harness: DeepSeek Harness minimal mode, max tier) |
| Claude Sonnet 5 | 80.4% to 80.5% | Anthropic’s own figure, corroborated by third party leaderboard |
| Claude Sonnet 4.6 | 57.3% | Third party leaderboard |
| DeepSeek V4 Pro (GA, 0813) | 87.9% | DeepSeek’s own August 13 GA benchmark table, reported by the vendor and not yet independently verified |
| Claude Haiku 4.5 | roughly 40% to 42% | Anthropic’s own figure, but measured on a different harness (Terminus-2, 11 runs), so not directly comparable to the numbers above |
On this benchmark, DeepSeek’s cheap model edges out Claude’s own mid tier Sonnet 5 and comes within two points of the much pricier Opus 4.8. That undercuts the assumption that frontier terminal and shell competence requires a frontier price tag, and it is probably the single most useful data point in this whole comparison. Anthropic’s newer Opus 5 wasn’t run on Terminal-Bench 2.1 directly. It was evaluated on FrontierBench v0.1, a harder successor benchmark, where it scored 43.3% against Opus 4.8’s 18.7%, so the two aren’t comparable on the same scale.
Notice the V4 Pro jump: DeepSeek’s own figure from the preview era sat around 50%, and the GA figure it published on August 13 claims 87.9%, a gain of nearly 38 points reported by the vendor in a few months. No independent evaluator has reproduced that number yet, so treat it the same way you’d treat any of DeepSeek’s other self reported figures in this review, as a claim rather than a confirmed result. V4 Flash didn’t get a new checkpoint alongside it, but it did pick up the same low, high, and max thinking effort control that Pro got, which is a genuinely useful lever for coding work: run simple tasks at low effort to save tokens, and reserve max for anything that resembles the harder end of Terminal-Bench.
SWE-bench Verified: why the public numbers are hard to compare
SWE-bench Verified is the most cited coding benchmark, though it’s still Python heavy rather than a true multi language test. Here’s what gets reported for each model.
Reported SWE-bench Verified results, not directly comparable
| Model | SWE-bench Verified | Source |
|---|---|---|
| Claude Opus 5 | 96.0% | Anthropic launch post, via MarkTechPost |
| Claude Sonnet 5 | 72.7% | MarkTechPost |
| Claude Haiku 4.5 | 73.3% | Anthropic’s own announcement (averaged over 50 trials, 128K thinking budget) |
| DeepSeek V4 Flash | roughly 74% to 79% (trackers disagree) | Third party aggregators (BenchLM.ai and others) |
That table should not be read as a four way shootout. Anthropic’s own Sonnet 5 launch comparison actually leads with SWE-bench Pro, a different and harder benchmark, where Sonnet 5 scores 63.2% against Opus 4.8’s 69.2%, rather than the Verified figure above. And Anthropic’s Opus 5 material emphasizes newer evaluations, including FrontierBench and SWE-bench Pro, rather than treating the 96% Verified figure as its headline coding comparison. Mixing a Verified score for one model with a Pro score reported elsewhere for another is exactly the kind of mismatched comparison that makes these tables unreliable, and it’s why the numbers above shouldn’t be ranked against each other at all.
The interesting thing here isn’t the ranking, because these numbers weren’t produced under a common evaluation harness. It’s that relatively inexpensive models are now appearing in the same broad capability range that was frontier territory surprisingly recently.
Java, PHP, SQL, and other specific languages: the data we don’t have
This is the part of the review that matters most for the original question, and it’s the part where public benchmarking genuinely falls short. Here’s what actually exists.
- SWE-bench Multilingual covers real GitHub issues in Java (43 tasks), PHP (43), Go (42), JS/TS (43), Ruby (44), Rust (43), C (30), and C++ (12), but no publicly available leaderboard currently reports Claude Haiku, Sonnet, Opus, and DeepSeek V4 Flash side by side on this specific split. It exists, but the four way comparison you’d want doesn’t.
- Aider’s Polyglot benchmark tests six languages (C++, Go, Java, JavaScript, Python, Rust) and notably misses PHP, Bash, and SQL entirely. On it, Claude Opus 4.6 leads at 82.1%, and the most recent DeepSeek score available in this benchmark’s public results is for the prior generation DeepSeek V3.2 (74.2%), not V4 Flash specifically.
- SQL has no head to head data for these four models at all. The public Text-to-SQL leaderboards (BIRD-SQL, Spider) are dominated by specialized multi agent pipelines built on top of base models (for example, XiYan-SQL at roughly 75.6% on BIRD), not by general chat or coding models evaluated directly, so there’s no clean “Claude Opus 5 scored X on BIRD-SQL” figure to report.
- Bash and Linux are reasonably well covered by Terminal-Bench 2.1 above, since that benchmark’s tasks run inside real Linux shells.
If a “common language benchmark” claiming to score all of Java, PHP, Bash, Linux, and SQL for these exact four models exists somewhere, we didn’t find a credible one in current public leaderboards. Most of what’s indexed for this pairing is comparison content built for search engines rather than accuracy, repeating the same handful of aggregate scores rather than genuine per language breakdowns, so it’s worth being skeptical of any blog claiming otherwise without a link to raw per language data.
Hands on evidence, with a timing caveat
Outside formal benchmarks, an independent hands on test from Kilo Code scored a real backend build task out of 100.
| Model | Score | Cost | Notes |
|---|---|---|---|
| Claude Opus 4.7 | 91/100 | n/a | Best output |
| DeepSeek V4 Pro | 77/100 | n/a | Solid, middle of the pack |
| DeepSeek V4 Flash | 60/100 | $0.02 | Build failed, missing key pieces, needed a cleanup pass |
This test is worth keeping, but it needs a real caveat. Kilo’s test was published on May 13, 2026, against the original April build of V4 Flash, not against the current DeepSeek-V4-Flash-0731 released on July 31, which DeepSeek says received additional post training specifically aimed at agentic performance. That means the 60/100 result cannot be treated as a direct evaluation of the model this review is otherwise comparing. It predates the July 31 round of post training, so it shouldn’t be read as a test of V4 Flash 0731 specifically.
It’s still useful for a different reason. It shows the kind of gap that can exist between strong agent benchmarks and first pass production correctness, including a failed build, incorrect routing, broken workflow behavior, and test coverage that missed externally visible failures. The current model may have closed some of that gap since May, but there isn’t public evidence yet either way, and it’s worth noting that DeepSeek’s own model version page still lists the Flash checkpoint as DeepSeek-V4-Flash-0731 as of this week, so the underlying model behind this test hasn’t changed since July even though pricing and controls have.
The missing metric: cost per accepted change
Everything above compares token prices or benchmark points, and that framing understates the real argument. One tracker estimated DeepSeek V4 Flash returns roughly 263 SWE-bench points per output dollar spent, versus roughly 2.8 for Claude Opus 4.8, which is nearly a 100x difference in benchmark points per dollar. That number is real, but it’s also slightly artificial, because it assumes a benchmark point and a dollar are the only things that matter.
The more useful question isn’t how many benchmark points a dollar buys. It’s how much a correct, shippable unit of engineering work actually costs once you count everything around the model call. A model that costs a twentieth as much but needs two extra rounds of developer review might not be twenty times cheaper in practice. Conversely, a cheap model that succeeds outright on most routine work can be transformative if it’s routed to the right tasks.
A rough version of that framework looks like this: model cost, plus retry cost, plus review cost, plus remediation cost, equals actual engineering cost. Under that framing, DeepSeek doesn’t need to match Opus on raw capability. It only needs the combined cost of inference, retries, and human correction to stay below the extra inference cost of running Opus on everything. That’s a more interesting economic argument than a straight benchmark comparison, and it’s the one this piece has been circling the whole time.
So which model should actually get the job
Once cost per accepted change is the real metric, the practical answer stops being “pick a model” and starts being “build a routing policy.”
| Work | Model |
|---|---|
| Boilerplate, transformations, simple fixes | V4 Flash |
| PR summaries, routine review, cheap agents | V4 Flash or Haiku 4.5 |
| Normal feature development | Sonnet 5 |
| Difficult debugging | Opus 5 |
| Large architectural changes | Opus 5 |
| Correctness critical code | Opus 5, plus verification |
| Huge parallel workloads | V4 Flash |
| First pass cheap, escalate on failure | Flash, then Sonnet, then Opus |
The winner in this comparison probably isn’t a single model. It’s the escalation pattern in that last row: run the cheap model first, and only pay for Sonnet or Opus when the cheap pass fails or the task is flagged as high stakes going in.
Verdict
For the hardest frontier problems, long agentic sessions where a wrong turn compounds, or anything security critical or correctness critical, Opus 5 is worth its price, and nothing here suggests otherwise. For everyday coding, PR review, refactoring, and most agentic terminal and shell work, Sonnet 5, or even Haiku 4.5, which punches well above its price on SWE-bench Verified, is the sensible default if you’re inside the Claude ecosystem. If cost is the binding constraint, for high volume tasks where imperfect first passes are economically tolerable, such as internal tooling or experimentation at scale, DeepSeek V4 Flash is a legitimately strong option that beats its own price class on agentic and terminal benchmarks, provided you budget for a review or cleanup pass on anything that ships to production.
One practical note if you’re actually going to route work to DeepSeek: its new peak and off peak pricing, effective August 16, 2026, means the same job costs twice as much if you run it between 01:00 and 04:00 or 06:00 and 10:00 UTC. Anthropic’s pricing has no such time of day variable.
Sources
- DeepSeek API Change Log, DeepSeek
- DeepSeek-V4-Pro GA Release, DeepSeek API Docs
- Models & Pricing, DeepSeek API Docs
- DeepSeek V4 Pro 0813 Goes GA: Benchmark Claims Await Independent Proof, Tech Times
- DeepSeek-V4-Flash Goes Official: Agent Benchmarks Beat V4-Pro-Preview
- DeepSeek V4 Flash 0731 (max): Intelligence, Performance & Price Analysis
- Claude Platform Pricing docs, Anthropic
- Meet the New Claude Opus 5, MarkTechPost
- Anthropic Claude Sonnet 5 vs Sonnet 4.6 vs Opus 4.8, MarkTechPost
- Introducing Claude Haiku 4.5, Anthropic
- Introducing Claude Opus 5, Anthropic
- What’s new in Claude Sonnet 5, Anthropic
- Terminal-Bench 2.1 Leaderboard, BenchLM.ai
- SWE-bench Multilingual
- Aider Polyglot Leaderboard 2026, AgentMarketCap
- We Tested DeepSeek V4 Pro and Flash Against Claude Opus 4.7 and Kimi K2.6, Kilo Code
- BIRD-SQL benchmark