All guides

deepseek-chat retires July 24: the migration checklist

On 2026-07-24 at 15:59 UTC, the legacy deepseek-chat and deepseek-reasoner aliases stop meaning what your code thinks they mean. Here is the mapping table, the one-line fix, and the three failure modes worth testing before the date.

Deadline: 2026-07-24 15:59 UTC — after this, both legacy IDs route to deepseek-v4-flash.

What changes, in one table

DeepSeek is not shutting the API down — it is retiring the old names. The danger is that nothing visibly breaks: requests to the old IDs keep returning HTTP 200, served by a different model. When we checked the official pricing page on 2026-07-02, the deprecation note had already carried the hard date for weeks, yet a quick GitHub code search still turned up thousands of files hard-coding deepseek-chat.

Legacy IDAfter 07-24What you should doRisk
deepseek-chatRoutes to deepseek-v4-flash (non-thinking default)Rename to deepseek-v4-flash explicitlyLow — same behavior, cheaper family
deepseek-reasonerRoutes to deepseek-v4-flash, not a reasoning-first modelMove to deepseek-v4-pro, or set Flash's thinking mode explicitlyHigh — silent quality change on reasoning workloads

Step 1: Find every hard-coded legacy ID

Search your codebase, environment files, CI configs, and any LangChain / LlamaIndex / Vercel AI SDK configuration for both strings. Don't forget infrastructure: model names hide in Helm values, feature-flag payloads, and analytics dashboards.

grep -rn "deepseek-chat\|deepseek-reasoner" . \
  --include="*.{py,ts,js,json,yaml,yml,env,toml}"

Step 2: Swap the model string (base URL stays)

The API is OpenAI-compatible and the endpoint does not change, so for most codebases this really is a one-line diff per call site.

Python

# Before (legacy alias — retires 2026-07-24)
client.chat.completions.create(
    model="deepseek-chat",
    messages=[{"role": "user", "content": "..."}],
)

# After (explicit V4 model ID)
client.chat.completions.create(
    model="deepseek-v4-flash",
    messages=[{"role": "user", "content": "..."}],
)

TypeScript

// Before
const res = await client.chat.completions.create({
  model: "deepseek-reasoner",   // retires 2026-07-24
  messages,
});

// After — reasoning workloads should go to Pro
const res = await client.chat.completions.create({
  model: "deepseek-v4-pro",
  messages,
});

curl

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

Step 3: Test the three failure modes

Renaming is easy; the regressions hide in behavior. Before the deadline, run your existing test prompts against the new IDs and check these three areas:

1. Reasoning depth (deepseek-reasoner users). V4 Flash defaults to non-thinking mode. If your pipeline expects chain-of-thought quality, compare outputs on deepseek-v4-pro or on Flash with the thinking mode explicitly enabled, and measure your task's actual pass rate rather than eyeballing single answers.

2. Output format drift. Model swaps are where strict JSON parsers go to die. If you assert on response structure, re-run your format validation suite against the new model ID.

3. Cost accounting. V4 bills cache-hit input at 1/5 the cache-miss rate ($0.028 vs $0.14 per 1M on Flash). If your prompts are stable, your input bill may drop after migration; if your cost dashboards hard-code old rates, update them. Our pricing page and calculator has the current numbers.

Frequently asked questions

What exactly happens on 2026-07-24?

At 15:59 UTC, the hosted DeepSeek API retires the legacy deepseek-chat and deepseek-reasoner model IDs. Calls using those names do not error — they are routed to deepseek-v4-flash. Your code keeps running, but on a different model than the one those names originally meant.

Will my API calls start failing after the deadline?

No, and that is the trap. Requests succeed with HTTP 200 but are served by V4 Flash. If you relied on deepseek-reasoner's long chain-of-thought behavior, outputs change without any error to alert you. Rename your model IDs before the date so the change happens on your schedule.

Do I need to change my base URL or API key?

No. The base URL (https://api.deepseek.com) and your existing API key keep working. The migration is a model-name change: swap the model string in your request body or SDK call.

Is the new pricing higher?

For deepseek-chat users the V4 Flash rate is $0.14/M input ($0.028 cache-hit) and $0.28/M output. For deepseek-reasoner users moving to deepseek-v4-pro, the rate is $1.74/M input ($0.145 cache-hit) and $3.48/M output. Check the official pricing page for current numbers before you budget.

What if I do nothing?

Chat workloads mostly get a silent upgrade. Reasoning workloads silently lose their reasoning-first model. Batch pipelines with output-format assertions are where we would expect the first breakage reports — test before July 24, not after.

Last verified: 2026-07-02 against the official DeepSeek API pricing page. Model routing behavior after the deadline is as documented by DeepSeek; re-check the official announcement before making production changes.