Cost, Billing, and OpsSeptember 24, 2026Flatkey Team

DeepSeek API Pricing (October 2026): Flash vs V4 Pro, Peak Hours, and Cache Math

DeepSeek API prices per 1M tokens for Flash and V4 Pro, peak vs off-peak hours in US time, cache-hit math, a cost calculator, and code.

DeepSeek API Pricing (October 2026): Flash vs V4 Pro, Peak Hours, and Cache Math

DeepSeek API Pricing (October 2026): Flash vs V4 Pro, Peak Hours, and Cache Math

DeepSeek API pricing in October 2026 is $0.15 per 1M input tokens and $0.60 per 1M output tokens for deepseek-flash at off-peak hours, and $0.66 input / $1.98 output for deepseek-v4-pro; peak-hour rates are exactly double. Cache hits drop input to $0.003 (Flash) or $0.022 (V4 Pro) per 1M tokens off-peak. Peak hours are 01:00–04:00 and 06:00–10:00 UTC on weekdays, which means US business hours are entirely off-peak. All figures come from DeepSeek's official Models & Pricing page, checked on October 21, 2026.

This guide is for indie developers and small teams choosing DeepSeek to keep inference cheap. It covers the full price table per million tokens, how peak and off-peak billing works in US time zones, the cache discount, the new Search and Fetch fees, legacy model names, worked cost examples, a time-aware cost calculator, and how DeepSeek compares with OpenAI, Claude, and Gemini.

DeepSeek API pricing at a glance

Question Answer (as of Oct 21, 2026)
Models deepseek-flash (DeepSeek-V4.1-Flash-1017) and deepseek-v4-pro (DeepSeek-V4-Pro-0813)
Cheapest input deepseek-flash, cache hit, off-peak: $0.003 per 1M tokens
Flash, off-peak $0.15 input (cache miss) / $0.60 output per 1M tokens
V4 Pro, off-peak $0.66 input (cache miss) / $1.98 output per 1M tokens
Peak multiplier 2x (off-peak is half of peak)
Peak hours 01:00–04:00 and 06:00–10:00 UTC, Monday–Friday, excluding Chinese public holidays
Context / max output 1M tokens / 384K tokens
Search and Fetch APIs $0.75 per 1,000 successful requests each
Free tier None listed; granted balance (if any) is spent before topped-up balance

Source: DeepSeek Models & Pricing, October 21, 2026.

DeepSeek API price per million tokens

Price per 1M tokens deepseek-flash off-peak deepseek-flash peak deepseek-v4-pro off-peak deepseek-v4-pro peak
Input, cache hit $0.003 $0.006 $0.022 $0.044
Input, cache miss $0.15 $0.30 $0.66 $1.32
Output $0.60 $1.20 $1.98 $3.96
Concurrency limit 2,500 2,500 500 500

Source: DeepSeek Models & Pricing, October 21, 2026.

Both models share the same feature set on the pricing page: JSON output, tool calls, the Responses API, an Anthropic-format endpoint, chat prefix completion (beta), and FIM completion in non-thinking mode only. The one difference that matters for builders: vision is supported on deepseek-flash but not on deepseek-v4-pro. Both default to thinking mode and can be switched to non-thinking; see the thinking mode guide. Because reasoning tokens are output tokens, non-thinking mode is the easiest saving on simple routes.

Legacy model names still work, at the Flash price

DeepSeek's footnote says to use deepseek-flash as the model name. The older names deepseek-v4-flash and deepseek-v4-flash-vision-exp are still accepted, but those models are retired: requests are served by DeepSeek-V4.1-Flash-1017 and billed at the Flash price. If you pinned a legacy name to freeze behavior, you are already on the new model, so re-run your evals. Our DeepSeek V4 migration checklist lists what to test.

Peak vs off-peak: what it means in US time

DeepSeek defines peak hours in UTC. Converted for US teams (Eastern Daylight Time runs until November 1, 2026):

Peak window (UTC, Mon–Fri) US Eastern (EDT, to Nov 1) US Eastern (EST, from Nov 1) US Pacific (PDT, to Nov 1)
01:00–04:00 9:00 pm–12:00 am (Sun–Thu evenings) 8:00 pm–11:00 pm 6:00 pm–9:00 pm
06:00–10:00 2:00 am–6:00 am 1:00 am–5:00 am 11:00 pm–3:00 am

Converted from the peak hours on DeepSeek's pricing page. Weekends and Chinese public holidays are off-peak in full.

The practical takeaway: a US product whose traffic follows the US working day pays off-peak rates for nearly all of it. The expensive windows fall on US evenings and overnight, which is exactly when many teams schedule batch jobs. Move nightly cron jobs, evals, and backfills to US daytime or weekends and they cost half as much. If your users are in Asia, the reverse is true: 06:00–10:00 UTC is mid-afternoon in Beijing and much of your daytime traffic is peak.

How the cache discount works

DeepSeek caches prompt prefixes automatically; you do not need to mark anything. The response usage object reports prompt_cache_hit_tokens and prompt_cache_miss_tokens, per the context caching guide. The guide also says caching is best-effort with no guaranteed hit rate, cache construction takes seconds, and unused caches are cleared within a few hours to a few days.

On Flash, a cache hit costs $0.003 versus $0.15 for a miss off-peak, a 98% discount. That makes prompt structure the biggest lever after model choice:

  • Keep the system prompt, tool schemas, and reference documents identical and at the start of every request.
  • Append the user-specific part at the end.
  • For multi-turn chats, resend the full history in the same order so the earlier turns hit the cache.

For a general method to measure whether caching pays off, see our prompt caching cost and ROI guide.

Search and Fetch fees

DeepSeek now sells standalone Search and Fetch APIs at $0.75 per 1,000 successful requests each. The pricing page adds that server-side tool calls made through DeepSeek Harness, Claude Code, or Codex already hit these APIs and are free for now, with per-request billing starting at 00:00 Beijing time on November 1, 2026 (4:00 pm UTC on October 31). If you use DeepSeek inside a coding agent, add a line item for search calls before that date.

Worked example: DeepSeek API cost per month

Assume 100,000 requests per month, each with 2,000 input tokens and 500 output tokens: 200M input and 50M output tokens.

Scenario Input cost Output cost Monthly total
Flash, off-peak, no cache hits 200 x $0.15 = $30.00 50 x $0.60 = $30.00 $60.00
Flash, peak, no cache hits 200 x $0.30 = $60.00 50 x $1.20 = $60.00 $120.00
Flash, off-peak, 70% cache hits 60 x $0.15 + 140 x $0.003 = $9.42 $30.00 $39.42
V4 Pro, off-peak, no cache hits 200 x $0.66 = $132.00 50 x $1.98 = $99.00 $231.00
V4 Pro, peak, no cache hits 200 x $1.32 = $264.00 50 x $3.96 = $198.00 $462.00

Calculated from DeepSeek's published rates, October 21, 2026.

Two patterns jump out. First, caching cuts the Flash bill by about a third even though output is unchanged, because the input side almost disappears. Second, V4 Pro is roughly 4x Flash at the same hour, so route only the requests that fail on Flash (complex reasoning, long agent loops) to Pro. Our DeepSeek V4 Pro vs Flash comparison covers when that trade is worth it.

Copyable DeepSeek cost calculator (time-aware)

The calculator below reads the cache fields from a real response and applies the peak or off-peak rate based on the UTC time of the request. It does not know Chinese public holidays, so on those days it overestimates.

# pip install openai
import os
from datetime import datetime, timezone
from openai import OpenAI

# DeepSeek rates per 1M tokens, Models & Pricing page, Oct 21, 2026 (off-peak; peak = 2x)
OFF_PEAK = {
    "deepseek-flash":  {"hit": 0.003, "miss": 0.15, "out": 0.60},
    "deepseek-v4-pro": {"hit": 0.022, "miss": 0.66, "out": 1.98},
}

def is_peak(ts: datetime) -> bool:
    ts = ts.astimezone(timezone.utc)
    if ts.weekday() >= 5:  # Saturday, Sunday
        return False
    return 1 <= ts.hour < 4 or 6 <= ts.hour < 10

def cost(model: str, usage, ts: datetime) -> float:
    r = OFF_PEAK[model]
    k = 2 if is_peak(ts) else 1
    return k * (usage.prompt_cache_hit_tokens * r["hit"]
                + usage.prompt_cache_miss_tokens * r["miss"]
                + usage.completion_tokens * r["out"]) / 1_000_000

client = OpenAI(api_key=os.environ["DEEPSEEK_API_KEY"], base_url="https://api.deepseek.com")
now = datetime.now(timezone.utc)
resp = client.chat.completions.create(
    model="deepseek-flash",
    messages=[{"role": "system", "content": "You are a concise SQL assistant."},
              {"role": "user", "content": "Count orders per day for the last 7 days."}],
)
print(resp.choices[0].message.content)
print(f"peak={is_peak(now)} cost=${cost('deepseek-flash', resp.usage, now):.6f}")

The same request with curl:

curl https://api.deepseek.com/chat/completions \
  -H "Authorization: Bearer $DEEPSEEK_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model":"deepseek-flash","messages":[{"role":"user","content":"Explain idempotency keys in one paragraph."}]}'

And in Node.js:

import OpenAI from "openai";

const client = new OpenAI({ apiKey: process.env.DEEPSEEK_API_KEY, baseURL: "https://api.deepseek.com" });
const r = await client.chat.completions.create({
  model: "deepseek-v4-pro",
  messages: [{ role: "user", content: "Plan a zero-downtime Postgres migration." }],
});
console.log(r.choices[0].message.content);
console.log(r.usage.prompt_cache_hit_tokens, r.usage.prompt_cache_miss_tokens, r.usage.completion_tokens);

DeepSeek vs OpenAI, Claude, and Gemini

Same workload as above (200M input, 50M output, no caching), using each provider's official Standard list price on October 21, 2026:

Model Input / output per 1M Monthly cost
Gemini 2.5 Flash-Lite $0.10 / $0.40 $40.00
gpt-6-luna $0.10 / $0.50 $45.00
Claude Haiku 5.5 (prompts up to 100K) $0.10 / $0.50 $45.00
deepseek-flash, off-peak $0.15 / $0.60 $60.00
deepseek-v4-pro, off-peak $0.66 / $1.98 $231.00
Gemini 3.8 Flash (2026 promo) $0.75 / $3.75 $337.50
gpt-6.1-sol $2.00 / $10.00 $900.00
Claude Sonnet 5.5 $2.00 / $10.00 $900.00

Sources: OpenAI pricing, Anthropic pricing, Gemini pricing.

The honest read: at list price DeepSeek Flash is no longer the cheapest budget model; Gemini 2.5 Flash-Lite, gpt-6-luna, and Claude Haiku 5.5 undercut it slightly without caching. DeepSeek wins when your traffic has high cache-hit rates (its $0.003 hit price is the lowest in the table) and in the mid tier, where V4 Pro costs about a quarter of gpt-6.1-sol or Sonnet 5.5. Compare quality on your own tasks before switching. For a cross-vendor view, see DeepSeek API vs Qwen API for cost-sensitive workflows and our OpenAI API pricing guide.

Direct DeepSeek API or a gateway?

Direct access gives you DeepSeek's own rates, the newest features first, and the Anthropic-format endpoint at https://api.deepseek.com/anthropic. A gateway is useful when DeepSeek is one of several models in your product and you want one key, one balance, and failover if DeepSeek's concurrency limit or an outage blocks requests.

On October 21, 2026, Flatkey's model pages listed deepseek-v4-1-flash from $0.09 input / $0.36 output per 1M tokens and deepseek-v4-pro from $0.396 / $1.188, 40% below DeepSeek's off-peak list prices. Flatkey also uses UTC time-tiered rates, so the "from" price is the off-peak tier; check the model page for the tier that applies to your traffic. Flatkey speaks the OpenAI format at https://router.flatkey.ai/v1 and the Anthropic format, so the same code above works by changing the base URL and key. Setup details are in our DeepSeek API access guide.

DeepSeek pricing checklist

  • Use deepseek-flash as the model name; legacy V4 Flash names now hit V4.1-Flash-1017.
  • Schedule batch work outside 01:00–04:00 and 06:00–10:00 UTC on weekdays.
  • Log prompt_cache_hit_tokens and prompt_cache_miss_tokens and track the hit rate.
  • Use non-thinking mode where reasoning adds no value.
  • Send image inputs to Flash; V4 Pro does not support vision.
  • Budget Search and Fetch calls from November 1, 2026 if you use DeepSeek in coding agents.
  • Re-check the pricing page monthly; DeepSeek says prices may change.

To compare these rates with OpenAI models, read DeepSeek vs ChatGPT (2026), which includes a worked cost example.

For the Flash model alone, including peak hours and a worked monthly cost, see DeepSeek V4 Flash pricing.

FAQ

How much does the DeepSeek API cost per million tokens?

As of October 21, 2026, deepseek-flash costs $0.15 per 1M input tokens (cache miss) and $0.60 per 1M output tokens off-peak, and deepseek-v4-pro costs $0.66 and $1.98. Peak-hour rates are double, and cache-hit input costs $0.003 (Flash) or $0.022 (V4 Pro) off-peak, per the official pricing page.

Is it free to use the DeepSeek API?

No. DeepSeek bills every request against your balance, and the pricing page lists no free tier. If you have a granted balance from a promotion, DeepSeek spends it before your topped-up balance. For zero-cost options, see our free LLM API list.

Is there a free DeepSeek API key?

You can create an API key for free on the DeepSeek platform, but requests still need a balance. Third-party sites offering "free DeepSeek keys" are either reselling shared keys or offering their own trial credits; avoid sending private data through them.

When are DeepSeek peak hours?

01:00–04:00 and 06:00–10:00 UTC, Monday to Friday, excluding Chinese public holidays. In US Eastern time before November 1, 2026, that is 9 pm to midnight and 2 am to 6 am; weekends are off-peak.

Why do DeepSeek costs vary between identical requests?

Three reasons: the time of day (peak doubles the price), the cache hit rate (a hit costs 98% less on Flash), and thinking tokens, which bill as output. Log all three per request to explain your bill.

Is DeepSeek cheaper than OpenAI?

In the mid tier, yes: deepseek-v4-pro off-peak is $0.66/$1.98 per 1M tokens versus $2/$10 for gpt-6.1-sol. At the budget end, gpt-6-luna ($0.10/$0.50) is slightly cheaper than deepseek-flash off-peak ($0.15/$0.60) unless your cache-hit rate is high.

Sources