DeepSeek V4.1 Flash vs Gemini 3.8 Flash: Cost per Task, Tested
On 11 identical calls on November 6, 2026, both passed every test; Gemini 3.8 Flash at default thinking cost 4.3x DeepSeek V4.1 Flash off-peak, 2.2x at peak.
On this page

For most text and image workloads where cost matters, start with DeepSeek V4.1 Flash (deepseek-flash, now served by the 1017 snapshot) and move to Gemini 3.8 Flash (gemini-3.8-flash) when the job needs audio, video, or PDF input, or answers that depend on what the model knows rather than on step-by-step reasoning. In a test run on November 6, 2026, both models passed all 11 graded calls of the same task set at their default thinking settings. At list price, Gemini 3.8 Flash cost $0.1236 for those calls and DeepSeek V4.1 Flash cost $0.0286 at DeepSeek's off-peak rate or $0.0572 at peak, so Gemini cost 4.3 times as much off-peak and 2.2 times as much at peak.
The per-token gap and the per-task gap are different numbers because both vendors bill thinking tokens as output, and the two models think different amounts. Gemini 3.8 Flash lists 5 times DeepSeek's off-peak input price and 6.25 times its output price, but at its default medium level it wrote fewer tokens than DeepSeek, which narrowed the bill to 4.3x; at high it wrote 1.75 times as many and the gap grew to 10.6x. On one harder coding spec, DeepSeek passed both tries inside a 32,000-token output cap, while every Gemini miss was that cap cutting it off mid-thought. With its documented maximum of 65,536 output tokens, Gemini passed 4 of 4, at about 8 to 15 times DeepSeek's cost per call.
If you choose Gemini 3.8 Flash for long code generation, raise maxOutputTokens to 65,536 before you judge its answers. If you choose DeepSeek V4.1 Flash for batch jobs, schedule them outside DeepSeek's weekday peak hours, which for US teams fall in the evening and overnight. Either way, budget for January 1, 2027, when Gemini 3.8 Flash's list price doubles and the default-setting gap in this test goes from 4.3x to 8.6x. Prices throughout are as of November 6, 2026.
Same 11 calls on both models, November 6, 2026: Gemini cost 4.3x
All three configurations passed all 11 calls, so on these tasks the models differed in cost and waiting time, not in correctness. The calls ran on a Friday between 12:50 and 13:00 UTC, inside DeepSeek's off-peak window; the peak figure in the table applies the same usage to DeepSeek's peak price.
The test sent identical prompts through the LaoZhang gateway with one usage-billed key for both models, every call streamed, with no system prompt, no tools, and one user message. DeepSeek ran through the OpenAI-compatible /v1/chat/completions endpoint with thinking enabled and reasoning_effort: "high", and returned the model name deepseek-v4-1-flash-261017 on every call. Gemini ran through the native streamGenerateContent endpoint with thinkingLevel set to medium and then high. Both had a 32,000-token output cap. The eight tasks were a word problem, five Python functions graded against hidden tests (interval merging, duration parsing, word counting, an expression evaluator without eval, and a CSV line parser), a five-bullet summary of a 6,723-word article, and a counting puzzle with one correct answer (55,252). Five tasks ran once and the three hardest twice, for 11 calls per configuration. Cost is the token usage each API returned, multiplied by the list price.
| Configuration (thinking level) | Passed | Output tokens (thinking) | Cost at list price | Median time to first answer token | Median time per call |
|---|---|---|---|---|---|
DeepSeek V4.1 Flash, high (default) | 11/11 | 44,807 (41,674) | $0.0286 off-peak, $0.0572 peak | 10.9 s | 12.3 s |
Gemini 3.8 Flash, medium (default) | 11/11 | 30,467 (25,476) | $0.1236 now, $0.2472 from 2027 | 22.0 s | 24.1 s |
Gemini 3.8 Flash, high | 11/11 | 78,258 (72,699) | $0.3028 now, $0.6057 from 2027 | 27.9 s | 30.1 s |

The gap shows clearly on single tasks. Summarizing the 6,723-word article cost $0.0025 on DeepSeek and $0.0176 on Gemini at medium, a 7x gap, because Gemini also thought longer on it (2,461 output tokens against 1,559). The expression evaluator cost $0.0053 and $0.0120 on DeepSeek's two tries, $0.0156 and $0.0274 on Gemini medium, and $0.0614 and $0.0845 on Gemini high.
This is one gateway on one day with one or two samples per task, so read it as what happened on these tasks, not as a benchmark. DeepSeek's own API and Google AI Studio's endpoints were not called directly, and the gateway may add time. Time to first answer also depends on the task: on its own longer tasks, Artificial Analysis measures the opposite order, with DeepSeek slower to start its answer, as the speed section below shows. Image, audio, and video input, tool use, DeepSeek's max effort, and Gemini's low level were not part of the run. Two Gemini attempts came back labeled with a different model version (3.1-flash-lite-05-2026), and one stream went silent and was dropped after 300 seconds; those attempts were discarded and rerun. If you call either model through any gateway, check the model version field in the response before trusting a result.
Why a 5–6x price gap per token became 4.3x per task, and 10.6x at high
On both APIs, output tokens cost more than input tokens and thinking tokens are billed as output, so the per-task ratio is set mostly by how many output tokens each model writes. DeepSeek V4.1 Flash costs $0.15 per million input tokens and $0.60 per million output tokens off-peak ($0.30 and $1.20 at peak), according to DeepSeek's API pricing page. Gemini 3.8 Flash costs $0.75 and $3.75 through December 31, 2026, with output "including thinking tokens", according to Google's Gemini API pricing page. That is 5x on input and 6.25x on output against DeepSeek off-peak. At medium, Gemini wrote 0.68 times as many output tokens as DeepSeek, which brought the bill down to 4.3x. At high, it wrote 1.75 times as many, and the bill rose to 10.6x.
You can rerun the numbers from the table. Cost per call is (input tokens − cache hits) × input price + cache hits × cache price + output tokens × output price, with prices per million tokens. For DeepSeek off-peak that is (11,836 − 256) × $0.15 + 256 × $0.003 + 44,807 × $0.60, divided by one million, or $0.0286; the 256 cached tokens came from DeepSeek's automatic prefix cache on two repeated prompts. For Gemini medium it is 12,486 × $0.75 + 30,467 × $3.75, divided by one million, or $0.1236.
The two models also count the same English text differently, though not by enough to change the verdict. Measured on the same API calls, 3,000 characters of English came to 844 tokens on DeepSeek and 936 on Gemini (10.9% more), and the 6,723-word article came to 10,288 and 11,198 (8.8% more). For other languages the difference ranged from Gemini counting 5.3% fewer tokens (Japanese) to 10.3% more (Chinese).
Token use swings from call to call, so budget from many calls rather than one. DeepSeek used 8,708 output tokens on the first expression-evaluator call and 19,986 on an identical second call; Gemini high used 16,326 and then 22,490. Totals across a task set were steadier: an earlier run of the same eight tasks on Gemini 3.8 Flash at high, on October 26, 2026, used 80,277 output tokens and cost $0.3104, within 3% of the November 6 figures.
A harder coding spec: DeepSeek passed at 32K tokens, Gemini needed 65,536
When the tasks got harder, DeepSeek V4.1 Flash still passed everything inside a 32,000-token output cap, and Gemini 3.8 Flash passed too once it had the 65,536 tokens Google allows, at a higher cost. A second round on November 6, between about 12:55 and 13:26 UTC and again off-peak for DeepSeek, used three tasks that had separated other models in an October 26 test: a Python function that matches npm-style semver ranges (caret, tilde, hyphen ranges, OR, and npm's prerelease rule, graded by 36 hidden tests); the 6,723-word article with three inserted project notes, including a later 25% budget correction, whose correct answer is $76.80; and a quiz on the Python 3.13 standard library that includes two made-up functions, statistics.winsorized_mean and functools.memoize_method, which must be answered "does not exist". Each ran twice per configuration, and Gemini streamed thought summaries (includeThoughts: true) so the connection stayed active.
At the 32,000 cap, DeepSeek passed 6 of 6, Gemini medium 5 of 6, and Gemini high 4 of 6. Every Gemini miss was the semver task stopping with finishReason: MAX_TOKENS after 30,719 to 31,898 thinking tokens, with no code or truncated code. That matches Google's Gemini thinking documentation: the output cap includes thought tokens, and a model that hits it while reasoning returns truncated or empty output while still billing the thinking. A rerun with maxOutputTokens at 65,536 passed all four Gemini calls, so the failures were the budget, not wrong code.
| Semver task, per call | Passed | Output tokens | Cost at list price | Time |
|---|---|---|---|---|
DeepSeek high, 32,000 cap | 2/2 | 23,154–24,531 | $0.014–0.015 off-peak, $0.028–0.030 peak | 141–150 s |
Gemini medium, 32,000 cap | 1/2 | 22,468 passed, 31,996 cut off | $0.0846, $0.1203 | 193–210 s |
Gemini medium, 65,536 cap | 2/2 | 30,421–30,794 | $0.114–0.116 | 199–218 s |
Gemini high, 32,000 cap | 0/2 | 31,898–31,996, both cut off | $0.120 each | 237–255 s |
Gemini high, 65,536 cap | 2/2 | 38,875–55,224 | $0.146–0.207 | 300–308 s |

So Gemini 3.8 Flash can write this function, but it needed more thinking to get there and cost roughly 8 times DeepSeek's off-peak price per call at medium and 10 to 15 times at high. One high call used 55,224 of the 65,536 tokens available, which leaves little room on a harder spec. DeepSeek's documented output limit is 384K tokens, so it has far more headroom if you set its cap high.
The other two tasks did not separate the models. All 8 Gemini answers (4 at medium, 4 at high) and all 4 DeepSeek answers to the article and quiz tasks were correct, and neither model invented the fake library functions. Gemini still thought longer for the short quiz answer: 2,573 to 3,043 output tokens at medium and about 5,600 at high, against 509 to 988 for DeepSeek, which made the quiz $0.0097 to $0.0115 per call on Gemini medium and $0.0003 to $0.0006 on DeepSeek. Across round 2 at the 32,000 cap, DeepSeek cost $0.0319 off-peak ($0.0637 at peak), Gemini medium $0.2423, and Gemini high $0.3017.
Both APIs cached the repeated 10,387-token article prompt automatically, without any cache setup. DeepSeek reported 10,368 cache-hit tokens on the second call, which cut that call from $0.0019 to $0.0004. Gemini reported 8,168 of 11,300 tokens from its implicit cache, which cut its call from $0.0107 to $0.0054.
Is Gemini 3.8 Flash smarter than DeepSeek V4.1 Flash 1017?
At their default settings they score about the same, and which one comes out ahead depends on the effort level and the kind of task. On the Artificial Analysis comparison of DeepSeek V4.1 Flash 1017 and Gemini 3.8 Flash (Intelligence Index v5.0.1, as of November 6, 2026), DeepSeek at high scores 29 and Gemini at medium 30. DeepSeek at max reaches 33, above Gemini at high (31). At the low end, Gemini at low scores 23 and DeepSeek with thinking turned off scores 19.
The sub-scores split by task type. DeepSeek leads on agentic coding in a terminal, with Terminal-Bench 4.0 at 28.8% at high against 19.7% for Gemini medium, and 33.8% at max. Gemini leads on science reasoning and stored knowledge: HLE-Diamond 29.1% against 20.8%, CritPt v2 45.0% against 27.5%, and AA-Omniscience 24 against 2. If your application answers questions from what the model knows, without search or your own documents in the prompt, Gemini 3.8 Flash has the clearer lead. If it runs code and shell commands in a loop, DeepSeek V4.1 Flash does.
Artificial Analysis also reports cost per index task: $0.46 for DeepSeek at high and $6.26 for Gemini at medium. Artificial Analysis prices DeepSeek at its peak rate, so the off-peak figure would be about half, near $0.23. That gap is much wider than the 4.3x in the November 6 test, likely because its tasks are long multi-step runs where cached input adds up, and Gemini's cache price ($0.075 per million) is 12.5 times DeepSeek's peak cache-hit price ($0.006). The wider point is that a per-task ratio holds only for the kind of work it was measured on.
The 1017 snapshot matters for any older result. DeepSeek's API change log says the October 17, 2026 update kept the same model name and price while improving its benchmarks and reducing "task runtime and output length". Results recorded on the September 10 release describe a model that wrote longer answers.
Which answers sooner? DeepSeek starts streaming in under 3 seconds
In the November 6 test, DeepSeek V4.1 Flash showed text first and reached the answer first. Its first streamed token arrived after a median 2.6 seconds because DeepSeek streams its reasoning in reasoning_content right away, and its first answer token came at a median 10.9 seconds. Gemini 3.8 Flash streamed nothing until its answer began, at a median 22.0 seconds at medium and 27.9 seconds at high, because thought summaries were not requested in that round. In the second round, with includeThoughts: true, Gemini's first streamed chunk arrived after a median 4 to 5 seconds. If your users watch a chat window, turning on thought summaries is the simplest way to show activity early on Gemini.
Artificial Analysis measures the opposite order on its own, longer tasks: time to first answer token of 24.11 seconds for DeepSeek at high and 10.01 seconds for Gemini at medium, with total time per task of 10.5 and 11.8 minutes. DeepSeek generates faster once it starts, at 175 output tokens per second against 116 in those measurements. The difference fits what happened on the semver spec, where DeepSeek thought for about two minutes before answering. On hard tasks DeepSeek can think longer before its first answer token, so time your own prompts before promising a response time.
When latency matters more than depth, lower the thinking level instead of switching models. On Artificial Analysis's runs, Gemini 3.8 Flash at low reached its first answer token in 2.64 seconds and DeepSeek V4.1 Flash with thinking off in 1.32 seconds, at index scores of 23 and 19.
DeepSeek peak hours and Gemini's 2027 price: how the cost gap moves
The same round-1 usage costs anywhere from 1.9 to 21 times more on Gemini depending on when DeepSeek runs, which Gemini price applies, and how you buy access. Each row reprices the 11 calls from the first table; nothing else changes.
| Price scenario | DeepSeek V4.1 Flash, high | Gemini 3.8 Flash, medium | Gemini 3.8 Flash, high |
|---|---|---|---|
| DeepSeek off-peak, Gemini price through December 31, 2026 | $0.0286 | $0.1236 (4.3x) | $0.3028 (10.6x) |
| DeepSeek peak, Gemini price through December 31, 2026 | $0.0572 | $0.1236 (2.2x) | $0.3028 (5.3x) |
| DeepSeek off-peak, Gemini price from January 1, 2027 | $0.0286 | $0.2472 (8.6x) | $0.6057 (21.2x) |
| DeepSeek peak, Gemini price from January 1, 2027 | $0.0572 | $0.2472 (4.3x) | $0.6057 (10.6x) |
| DeepSeek off-peak, Gemini Batch or Flex in 2026 | $0.0286 | $0.0618 (2.2x) | $0.1514 (5.3x) |
| Both through LaoZhang | $0.0643 | $0.1236 (1.9x) | $0.3028 (4.7x) |
DeepSeek's off-peak price is defined as half of peak. Peak runs from 01:00 to 04:00 and 06:00 to 10:00 UTC, Monday through Friday, except Chinese public holidays; weekends and those holidays are off-peak all day. In US Eastern Standard Time, that is 8 to 11 PM and 1 to 5 AM from Sunday night through Thursday night, or 5 to 8 PM and 10 PM to 2 AM Pacific, an hour later once daylight saving time returns in March. A US team working business hours pays the off-peak price without trying, while a batch job that starts at 9 PM Eastern on a weeknight pays the peak price until 11 PM. DeepSeek API Peak Hours: Current Prices and When to Wait covers scheduling around those windows.
Gemini 3.8 Flash's price doubles on January 1, 2027, to $1.50 per million input tokens and $7.50 per million output tokens, with cached input going from $0.075 to $0.15. Batch and Flex requests cost half the Standard rate, $0.375 and $1.875 now, which brings Gemini medium close to DeepSeek's peak cost in this test ($0.0618 against $0.0572), if your job can wait for asynchronous results. For anything that will still run after December, use the 2027 rows. Gemini API Pricing 2026: Token Rates, Free Tier, and Key Cost has the full Gemini table.
Through LaoZhang, one key reaches both models. As of November 6, 2026, its DeepSeek V4.1 Flash price is a flat $0.44 per million input tokens and $1.32 per million output tokens with no peak or off-peak split, which is above DeepSeek's own price at every hour, and its Gemini 3.8 Flash price matches Google's list price.
Audio, video, PDF, or output over 65,536 tokens: the hard limits
Two limits settle the choice before price does. Gemini 3.8 Flash accepts text, images, video, audio, and PDF, according to Google's Gemini 3.8 Flash model page, while DeepSeek V4.1 Flash accepts text and images. If your input includes recordings, video, or PDFs and you don't want to convert them yourself, Gemini is the option. In the other direction, Gemini caps output at 65,536 tokens including thinking, while DeepSeek's documented maximum is 384K, so long generated files, large refactors, and long reports with heavy thinking fit only on DeepSeek. Both accept about one million tokens of context.
Built-in tools differ as well. Gemini 3.8 Flash includes grounding with Google Search, with 5,000 free requests a month shared across Gemini 3 and newer models and then $14 per 1,000, plus code execution, computer use, file search, and Maps grounding. DeepSeek V4.1 Flash supports tool calls, JSON output, the Responses API, and an Anthropic-format endpoint, and sells web search as a separate API billed per request, covered in DeepSeek Search API Pricing: $0.75/1K and Real Cost per Search. DeepSeek lists a concurrency limit of 2,500 for deepseek-flash.
Default thinking: DeepSeek high, Gemini medium, and what to change
Unless you set it, DeepSeek V4.1 Flash thinks at high and Gemini 3.8 Flash thinks at medium, so a quick test with no parameters compares one model's higher setting with the other's middle one. According to DeepSeek's thinking mode guide, DeepSeek accepts low, high, and max, maps medium and xhigh to high and minimal to low, and turns thinking off with {"thinking": {"type": "disabled"}}. In thinking mode it ignores temperature, presence_penalty, and frequency_penalty without returning an error. Gemini 3.8 Flash accepts low, medium, and high, with no minimal or off setting. On both, thinking tokens are billed as output.
When you move a workload from one model to the other, these are the checks that changed results in the test:
- Set the model ID explicitly.
deepseek-flashpoints to DeepSeek-V4.1-Flash-1017, and the legacy namedeepseek-v4-flashis still accepted and served by the same model at the same price. Gemini's ID isgemini-3.8-flash. - Set the thinking level on both sides, so you compare the settings you plan to run rather than the defaults.
- Raise Gemini's
maxOutputTokensto 65,536 for long code or long reasoning, and give DeepSeek'smax_tokenssimilar headroom; it used up to 24,531 output tokens, thinking included, on the semver spec. A cap that is too low on Gemini costs the thinking and returns nothing usable. - Check the model version each response reports (
deepseek-v4-1-flash-261017andgemini-3.8-flashin the test), especially through a gateway. - Remove any reliance on
temperaturefor DeepSeek in thinking mode, because it has no effect there.
These were the request bodies in the test. For DeepSeek V4.1 Flash, through the OpenAI-compatible endpoint:
{
"model": "deepseek-flash",
"messages": [{ "role": "user", "content": "..." }],
"thinking": { "type": "enabled" },
"reasoning_effort": "high",
"max_tokens": 32000,
"stream": true,
"stream_options": { "include_usage": true }
}For Gemini 3.8 Flash, through streamGenerateContent, with the larger cap used in the rerun:
{
"contents": [{ "role": "user", "parts": [{ "text": "..." }] }],
"generationConfig": {
"maxOutputTokens": 65536,
"thinkingConfig": { "thinkingLevel": "medium", "includeThoughts": true }
}
}Why DeepSeek vs Gemini Flash comparisons show different prices and winners
When two comparisons of these models disagree, the cause is usually one of three things. The first is the snapshot: anything measured before October 17, 2026 tested the September release of DeepSeek V4.1 Flash, which DeepSeek says wrote longer outputs. An early-October 3D-geometry test that aimlapi posted on X, for example, found DeepSeek using 168k output tokens against Gemini's 21k and costing $0.27 against $0.11 at aimlapi's prices. A DeepSeek row that isn't labeled 1017 is likely the older model.
The second is the price. Model catalogs and routers sometimes show a third-party provider's DeepSeek price, or only the peak rate, instead of DeepSeek's own $0.15 and $0.60 off-peak list. Artificial Analysis uses the peak rate. Some catalogs also list DeepSeek's maximum output as about one million tokens, while DeepSeek's documentation says 384K.
The third is the effort level. A chart that sets DeepSeek at max against Gemini at high, or that uses each model's default, compares different amounts of thinking, which can change both the score and the bill by several times. Before you use any number, check which snapshot, which price list, and which thinking level it belongs to.
Which to pick for your workload
The table turns the results above into a first choice and the condition that would change it.
| Workload | Start with | What would change it |
|---|---|---|
| Text or image chat, extraction, summarization at volume | DeepSeek V4.1 Flash | Your traffic is mostly in DeepSeek's peak hours and you can use Gemini Batch or Flex, which brings the cost close |
| Coding agents and terminal tasks | DeepSeek V4.1 Flash | Your own graded tasks pass more often on Gemini at a cost you accept |
| Audio, video, or PDF input | Gemini 3.8 Flash | You already convert those inputs to text or images |
| Questions answered from the model's own knowledge | Gemini 3.8 Flash | You add search or your own documents to the prompt; then test DeepSeek too |
| Outputs longer than 65,536 tokens, thinking included | DeepSeek V4.1 Flash | None; Gemini's cap is fixed |
| Chat UI where the first visible text matters | Either, with thinking streamed or lowered | Time your own prompts; the order flips between short and long tasks |
| Jobs that will run past December 31, 2026 | DeepSeek V4.1 Flash | Your job can wait for asynchronous results on Gemini Batch or Flex at half the Standard rate |
If you're also weighing other models, DeepSeek V4.1 Flash vs GLM-5.3-Flash: Which Is Cheaper, and When compares DeepSeek with the other low-cost Flash model, and Gemini 4 Argon vs 3.8 Flash: Cost per Task and When to Switch covers when to step up from Gemini 3.8 Flash.
DeepSeek V4.1 Flash vs Gemini 3.8 Flash: other questions
Is DeepSeek V4 Flash better than Gemini 3.5 Flash?
Both names in that question are older. As of November 6, 2026, the model name deepseek-v4-flash is still accepted but served by DeepSeek-V4.1-Flash-1017, and Gemini 3.8 Flash is the model Google describes as its most intelligent Flash model, so the comparison that applies to new API calls is the one on this page.
Can I use Gemini 3.8 Flash for free through the API?
Yes, Gemini 3.8 Flash is on the Gemini API free tier, where input and output are listed as free of charge, but Google doesn't publish the free tier's daily limits on its pricing page, and free-tier data is used to improve Google's products. Gemini API Free Tier 2026: Limits, Free Models, and Free API Keys covers what the free tier allows.
How do these two compare with Claude Sonnet 5.5 or Kimi K3.1?
Both pairings have their own tested comparison. Claude Sonnet 5.5 vs Gemini 3.8 Flash: Cost per Task, Tested runs the same eight tasks against a more expensive model, DeepSeek V4.1 vs Kimi K3.1: Flash vs Pro and a 9–28× Cost Gap sets DeepSeek's Flash model against a Pro-tier one, and AI API Price Comparison: Cheapest Model by Input and Output Mix ranks a wider set by price.
Sources7
External pages this guide links to, in the order they appear. Last updated Nov 6, 2026.
Sources7
External pages this guide links to, in the order they appear. Last updated Nov 6, 2026.
- 1.DeepSeek's API pricing pageapi-docs.deepseek.com/quick_start/pricing
- 2.Google's Gemini API pricing pageaistudio.google.com/docs/pricing
- 3.Google's Gemini thinking documentationaistudio.google.com/docs/thinking
- 4.Artificial Analysis comparison of DeepSeek V4.1 Flash 1017 and Gemini 3.8 Flashartificialanalysis.ai/models/releases/comparisons/deepseek-v4-1-flash-1017-vs-gemini-3-8-flash
- 5.API change logapi-docs.deepseek.com/updates
- 6.Google's Gemini 3.8 Flash model pageaistudio.google.com/docs/models/gemini-3.8-flash
- 7.DeepSeek's thinking mode guideapi-docs.deepseek.com/guides/thinking_mode





