Back to Models

DeepSeek V3.1

deepseekdeepseek/deepseek-v3.1

DeepSeek V3.1 is a hybrid model supporting both thinking and non-thinking modes. Features enhanced tool calling capabilities for agent-based tasks. Thinking mode maintains answer quality comparable to DeepSeek-R1 with improved response times.

DeepSeek-V3.1, released August 21, 2025, is the first hybrid-reasoning model from DeepSeek: one checkpoint that can operate in either non-thinking mode (deepseek-chat) or thinking mode (deepseek-reasoner) depending on the API endpoint or the DeepThink toggle in chat. It inherits the 671B-total / 37B-active MoE backbone from V3, adds 840B tokens of continued pretraining for long-context extension, and introduces a new tokenizer + chat template. The headline engineering win is that V3.1-Think matches or exceeds DeepSeek-R1-0528 quality while answering significantly faster.

For TheRouter operators the value is clear: V3.1 gives you the same model ID surface for both fast chat and deep reasoning workloads, eliminating the need to maintain separate R1 routing logic. Tool calling and multi-step agent tasks received targeted post-training, yielding SWE-bench Verified 66.0, SWE-bench Multilingual 54.5, Terminal-bench 31.3 β€” material gains over R1-0528. The model is MIT-licensed for code and permissively licensed for weights, and inference stacks (SGLang, vLLM, LMDeploy, etc.) already support it, so a self-host path is realistic.

Best for
  • β€’ Agentic coding and search workloads that need reliable tool calling and JSON output without paying frontier prices
  • β€’ Hybrid chat surfaces where some users want instant answers and others want visible chain-of-thought β€” toggle via endpoint or UI flag
  • β€’ Long-context reasoning tasks (128K) where V3.1's continued pretraining actually helps β€” repo analysis, long-document CoT, multi-turn agent loops
  • β€’ Self-host fallback for cost-sensitive or compliance-sensitive workloads β€” same weights, same tokenizer as the hosted path
Reach for something else if
  • β€’ Vision or multimodal inputs β€” V3.1 is text-only; route images to Claude Opus 4.7, Amazon Nova 2 Lite, or GPT-5o
  • β€’ Ultra-deep math or research where V3.2-Speciale or V4-Pro already exist and are preferred
  • β€’ Production paths that should already be on V4 β€” V4-Flash / V4-Pro launched April 2026 and are the current default
Context Length
128K
Max Output
33K
Input Priceper 1M tokens
$0.6264/ 1M tokens
Output Priceper 1M tokens
$1.81/ 1M tokens

Modalities

text→text

Pricing Breakdown

TypeRate
Input$0.6264 / 1M tokens
Output$1.81 / 1M tokens

Supported Parameters

temperaturemax_tokenstop_ptoolstool_choiceresponse_formatreasoningstop

Specifications

Release date2025-08-21api-docs.deepseek.com β†—verified
Architecture671B-total / 37B-active MoE; 840B tokens continued pretraining on V3 base for long-context extension; new tokenizer + chat templateapi-docs.deepseek.com β†—verified
Context window128K tokensapi-docs.deepseek.com β†—verified
Hybrid modesdeepseek-chat β†’ non-thinking mode; deepseek-reasoner β†’ thinking mode (toggle via API or UI DeepThink button)api-docs.deepseek.com β†—verified
License β€” codeMIThuggingface.co β†—verified
License β€” weightsDeepSeek Model License (commercial use permitted)huggingface.co β†—verified
Supported inference backendsSGLang, vLLM, LMDeploy, TensorRT-LLM, LightLLM, DeepSeek-Infer; FP8 + BF16; NVIDIA + AMD GPUs; Huawei Ascend via MindIEhuggingface.co β†—verified
SuccessorDeepSeek-V3.2 (Dec 2025) β†’ V3.2-Speciale (temporary) β†’ V4-Flash / V4-Pro (Apr 2026)verified

Benchmarks

BenchmarkDistributionScoreSource
SWE-bench Verified
Pass@1; major improvement over R1-0528 (44.6%)
66.0%api-docs.deepseek.com β†—
SWE-bench Multilingual
54.5%api-docs.deepseek.com β†—
Terminal-bench
31.3%api-docs.deepseek.com β†—
Aider
Surpasses Claude 3.5 Sonnet (70.6%)
71.6%localllm.in β†—
AIME 2025
Pass@1; +17.5 over R1-0528 (70.0)
87.5%api-docs.deepseek.com β†—
GPQA Diamond
74.9%localllm.in β†—
MMLU-Redux
91.8%localllm.in β†—

API Usage Examples

Use the global api.therouter.ai endpoint shown below for new integrations; the legacy China accelerated endpoint is retired.

cURL
curl https://api.therouter.ai/v1/chat/completions   -H "Content-Type: application/json"   -H "Authorization: Bearer $THE_ROUTER_API_KEY"   -d '{
    "model": "deepseek/deepseek-v3.1",
    "messages": [
      {"role": "user", "content": "Summarize the key points from this input."}
    ]
  }'

Chat

Standard non-thinking chat via deepseek-chat alias or direct model id.

cURL
curl -X POST https://api.therouter.ai/v1/chat/completions \
  -H "Authorization: Bearer $THEROUTER_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"model":"deepseek/deepseek-v3.1","messages":[{"role":"user","content":"Hello"}]}'

More from deepseek

Similar models

Cross-provider sibling models

News & changes

2026-04-24

V4-Flash / V4-Pro launch; legacy aliases now point to V4

DeepSeek-V4 family becomes the default. deepseek-chat and deepseek-reasoner aliases now resolve to V4-Flash non-thinking / thinking modes. V3.1 remains available but is no longer the recommended path for new projects.

re-authored by TheRouterapi-docs.deepseek.com β†—
2025-12-01

V3.2 replaces V3.1 on the default endpoints

Both deepseek-chat and deepseek-reasoner were upgraded to V3.2 (non-thinking / thinking). V3.1-Terminus was a brief intermediate release focused on language consistency and agent fixes.

re-authored by TheRouterapi-docs.deepseek.com β†—
2025-08-21

DeepSeek-V3.1: hybrid thinking model launched

First hybrid model from DeepSeek. Single checkpoint supports both thinking and non-thinking modes. Significant gains on agent benchmarks (SWE-bench Verified 66.0) and faster thinking than R1-0528.

re-authored by TheRouterapi-docs.deepseek.com β†—

Frequently asked

How do I switch between thinking and non-thinking mode?

Use model='deepseek-chat' for non-thinking or model='deepseek-reasoner' for thinking mode. In the web UI, toggle the DeepThink button. The same underlying weights are used; only the inference template changes.

Is V3.1 still recommended for new projects?

No. V4-Flash / V4-Pro launched April 2026 and are the current defaults. V3.1 remains available for compatibility but new integrations should target V4 unless you have a specific reason to stay on V3.1.

Can I self-host V3.1?

Yes. Weights are published on Hugging Face under a permissive license. Supported inference engines include SGLang, vLLM, LMDeploy, TensorRT-LLM, and LightLLM. Self-hosting gives you full control over data residency and cost.

Fact ledger β€” every claim on this page traces here
sourceURLretrieved
Release dateapi-docs.deepseek.com β†—2026-05-25verified
Architectureapi-docs.deepseek.com β†—2026-05-25verified
Context windowapi-docs.deepseek.com β†—2026-05-25verified
Hybrid modesapi-docs.deepseek.com β†—2026-05-25verified
License β€” codehuggingface.co β†—2026-05-25verified
License β€” weightshuggingface.co β†—2026-05-25verified
Supported inference backendshuggingface.co β†—2026-05-25verified
Successorβ€”β€”verified
SWE-bench Verifiedapi-docs.deepseek.com β†—2026-05-25verified
SWE-bench Multilingualapi-docs.deepseek.com β†—2026-05-25verified
Terminal-benchapi-docs.deepseek.com β†—2026-05-25verified
Aiderlocalllm.in β†—2026-05-25to verify
AIME 2025api-docs.deepseek.com β†—2026-05-25verified
GPQA Diamondlocalllm.in β†—2026-05-25to verify
MMLU-Reduxlocalllm.in β†—2026-05-25to verify
V4-Flash / V4-Pro launch; legacy aliases now point to V4api-docs.deepseek.com β†—2026-05-25verified
V3.2 replaces V3.1 on the default endpointsapi-docs.deepseek.com β†—2026-05-25verified
DeepSeek-V3.1: hybrid thinking model launchedapi-docs.deepseek.com β†—2026-05-25verified
How do I switch between thinking and non-thinking mode?api-docs.deepseek.com β†—2026-05-25to verify
Is V3.1 still recommended for new projects?api-docs.deepseek.com β†—2026-05-25to verify
Can I self-host V3.1?huggingface.co β†—2026-05-25to verify
Help & contact