Claude is the default model in a lot of coding agents, and it isn’t cheap. DeepSeek V4.1 Flash 1017 is one of the cheapest capable models you can run, so the question is how much you give up on quality, cost and time if you switch. We ran it through the same long coding sessions, prompts and grading we use for every model, next to Claude Opus 5.5, Sonnet 5.5 and Haiku 5.5.
Short answer: DeepSeek V4.1 Flash 1017 codes about as well as Claude Sonnet 5.5 and Haiku 5.5 at their default settings, for a fraction of the price. Claude Opus 5.5 is still clearly better, by about 10 points on long agentic sessions. On quick one-shot coding questions, DeepSeek matched Opus.
| Model | Long agentic sessions | Cost per session | One-shot questions | Cost per question |
|---|---|---|---|---|
| ClaudeOpus 5.5, medium (default) | 87% | $5.42 | 90% | $0.32 |
| NewDeepSeek V4.1 Flash 1017 | 77% | $0.14 | 90% | $0.013 |
| ClaudeSonnet 5.5, medium (default) | 77% | $1.28 | ||
| ClaudeSonnet 5.5, high | 77% | $0.15 | ||
| ClaudeHaiku 5.5, medium (default) | 76% | $0.69 | 79% | $0.009 |
| ClaudeHaiku 5.5, high | 87% | $0.014 |
Best value in each column in bold. Blank cells are settings we did not run for that kind of session.
Scores are percentages of the maximum on our benchmark. DeepSeek V4.1 Flash 1017 came out on October 17 at $0.15 per million input tokens and $0.60 output. Most “DeepSeek vs Claude” comparisons you’ll find quote SWE-bench or LiveCodeBench numbers the vendors reported themselves. These aren’t those. Every number here comes from the same tasks, the same prompts and the same grading, all run inside Claude Code.
DeepSeek vs Claude Opus 5.5
Opus wins on quality, and it’s not close on the hard parts. On our long sessions Opus scores 87% to DeepSeek’s 77%, and Opus costs about 39 times as much per session ($5.42 against $0.14).
The gap isn’t spread evenly. Our long sessions walk a model through real work on a real service: trace the relevant code, work out why something fails, plan a fix, implement it, then audit the change. Here’s how each turn scored:
| Turn in a long session | Score by model |
|---|---|
| Trace the code | 92%87%95% |
| Analyze the failure | 75%69%90% |
| Plan the fix | 81%81%81% |
| Implement | 68%73%85% |
| Audit | 70%73%82% |
DeepSeek V4.1 Flash 1017Claude Sonnet 5.5Claude Opus 5.5
DeepSeek’s plans score level with Opus. Its fixes score 17 points lower, and its analysis of why the code fails is 15 points behind. If being wrong is expensive, as it is when an agent writes a change to production code and then checks its own work, Opus earns its price.
The one-shot result goes the other way. On small, self-contained asks (explain how a config setting gets resolved, find where a flag is used, fix a small bug, make a timeout configurable) DeepSeek scored 90%, the same as Opus, at $0.013 a question against $0.32. That’s about 1/25th of the cost for the same score. It is slower, about two minutes a question against Opus’s one.
DeepSeek vs Claude Sonnet 5.5
On long agentic sessions this one’s a tie on score: 77% each. DeepSeek costs $0.14 a session and Sonnet $1.28, so about a ninth of the money.
They tie in different ways. DeepSeek is better at reading and diagnosing, 6 points ahead on the failure-analysis turn and 5 ahead on tracing the code. Sonnet is better at writing the change, 5 points ahead on implementation and 3 on the audit. If your agent mostly investigates and explains, DeepSeek is the better buy. If it mostly writes code, Sonnet’s edge is where it counts.
Speed goes to Sonnet by a mile. A long session took Sonnet 6.8 minutes and DeepSeek 15.4. DeepSeek V4.1 Flash 1017 thinks a lot: on one long task it wrote about 3,600 output tokens per request, mostly reasoning, where its predecessor wrote 700-900. At $0.60 per million output tokens that thinking costs pennies, but you wait for it.
DeepSeek vs Claude Haiku 5.5
Haiku 5.5 is Anthropic’s cheap model, so this is the closest fight. On long sessions they’re level, 76% for Haiku at its default and 77% for DeepSeek. DeepSeek costs about a fifth as much ($0.14 against $0.69). Haiku is faster at 8.1 minutes against 15.4.
On one-shot questions DeepSeek is ahead of Haiku at its default, 90% against 79%. Turn Haiku up to high effort and it reaches 87% at almost exactly DeepSeek’s price ($0.014 against $0.013). Between those two, the choice comes down to whether you’d rather stay on Anthropic’s models and get faster answers.
Haiku’s pricing has a catch for agent work. Its $0.10 per million input tokens applies to prompts up to 100K tokens, and longer prompts cost five times as much. Long agent sessions cross that line often, which is a big part of why a Haiku session costs $0.69.
Can you use DeepSeek in Claude Code?
Yes. Every DeepSeek number in this post comes from DeepSeek V4.1 Flash 1017 running inside Claude Code, with no extra prompting and Claude Code’s own effort setting. It ran the same long multi-turn sessions, tool calls and file edits as the Claude models, with no setup beyond pointing Claude Code at the model. The new version was also more consistent than the one before it. The previous V4.1 Flash once answered a stray notification from a background command instead of the question it was asked. In 16 one-shot sessions, V4.1 Flash 1017 never did anything like that.
Which should you use?
For quick lookups, explanations and small fixes, DeepSeek V4.1 Flash 1017 gives you Opus-level answers for about 1/25th of the cost, if you can wait a minute longer.
For long agentic sessions where you’d otherwise run Sonnet 5.5 or Haiku 5.5 at their defaults, DeepSeek gives the same score for much less money and takes about twice as long.
For implementing changes in code that matters, and for auditing them, use Opus 5.5. That’s where every cheaper model we tested, DeepSeek included, falls 12 to 17 points behind.
FAQ
Is DeepSeek better than Claude for coding?
It depends on which Claude. In our benchmark DeepSeek V4.1 Flash 1017 matched Claude Sonnet 5.5 and Haiku 5.5 on long agentic coding sessions (77% against 77% and 76%) and scored below Claude Opus 5.5 (87%). On one-shot coding questions it tied Opus at 90%.
How much cheaper is DeepSeek than Claude?
Per long agentic session in our runs: DeepSeek V4.1 Flash 1017 $0.14, Haiku 5.5 $0.69, Sonnet 5.5 $1.28, Opus 5.5 $5.42. That makes DeepSeek about 5 times cheaper than Haiku, 9 times cheaper than Sonnet and 39 times cheaper than Opus at the default settings.
Is DeepSeek slower than Claude?
Yes. A long session took DeepSeek 15.4 minutes, against 6.8 for Sonnet 5.5, 8.1 for Haiku 5.5 and 17.2 for Opus 5.5. On one-shot questions DeepSeek took about 2 minutes against under 1 for Opus.
Where is Claude still clearly better?
Implementing and auditing code changes. Opus 5.5 scored 85% on implementation and 82% on the audit, against 68% and 70% for DeepSeek V4.1 Flash 1017.
How we tested
The benchmark is a set of agentic coding tasks taken from real work on our own services: long multi-turn sessions that can run 15-20 minutes, plus one-shot questions. Every model gets the same fixed prompts in Claude Code with the version pinned. Each turn is graded against an answer key that was checked against the code, by a judge scoring five dimensions. The judge is Opus 5.5, so one contestant is also the referee. The answer keys tie it to facts rather than taste, and it marks Opus down plenty. We ran 8 long sessions and 16 one-shot sessions for DeepSeek V4.1 Flash 1017. The Claude numbers come from our earlier runs on the same tasks and answer keys. Session-to-session noise is about 3 points, so treat 1-2 point gaps as ties. Costs come from each session’s token counts at the prices in effect when it ran.