deepseek
236B parameters
Commercial OK
Reviewed October 2026

DeepSeek Coder V2 236B

Full DeepSeek Coder V2. 236B total / 21B active MoE coder.

License: DeepSeek License·Released Jun 17, 2024·Context: 131,072 tokens
BLK · VERDICT

Our verdict

OP · Eruo Fredoline|UPDATED OCT 7, 2026
Not tested by usEditorial assessment from specifications and published reports.
unrated

Positioning

DeepSeek Coder V2 is DeepSeek's 236B-parameter Mixture-of-Experts code generation model — the largest open-weight coding model available and the direct predecessor to DeepSeek Coder V3. Built on the DeepSeek V2 architecture with code-specific pre-training and fine-tuning, Coder V2 targets operators who need maximum coding capability in open-weight form. For coding-specialized workloads that demand the highest possible code generation quality, DeepSeek Coder V2 remains a top-tier option even as newer models emerge.

Strengths

  • Largest open-weight coding model. 236B MoE with ~21B active per token provides exceptional code generation capacity. HumanEval, MBPP, and SWE-bench scores are among the highest in open-weight AI — competitive with GPT-4 and Claude on coding benchmarks.
  • MoE efficiency for code generation. ~21B active parameters per token means fast decode while drawing on 236B total coding knowledge. The active-to-total ratio is favorable for code completion and generation throughput.
  • DeepSeek's code-specific training pipeline. Pre-trained on code-heavy corpora (GitHub, Stack Overflow, documentation) with code-specific fine-tuning and reinforcement learning. Not a general-purpose model that happens to code well — a coding model.
  • Strong performance across programming languages. Python, JavaScript, TypeScript, Java, C++, Go, Rust, and more — DeepSeek's training data spans the major programming languages with competitive results across all of them.
  • Competitive repository-level code understanding. Beyond single-file completion, Coder V2 handles multi-file repository context, codebase navigation, and cross-file reasoning — the capabilities that distinguish coding assistants from code completion tools.
  • Permissive DeepSeek open-weight license. Commercial use allowed with fewer restrictions than Llama. Verify for your specific deployment, but the license terms are generally favorable for commercial coding applications.

Limitations

  • Superseded by DeepSeek Coder V3. Coder V3 is the architectural successor with improved coding benchmarks and MoE efficiency. New deployments should consider Coder V3 first unless Coder V2 has specific ecosystem advantages in your stack.
  • Massive memory requirements. 236B MoE at Q4 requires ~135 GB — beyond single consumer GPU but fits Mac Studio M3 Ultra at 192 GB. Q3 at ~100 GB fits Mac Studio with generous context or dual A100 setups. Not a consumer-GPU model.
  • General (non-coding) tasks are secondary. DeepSeek Coder V2 is coding-specialized — performance on creative writing, general knowledge, and non-coding reasoning is below general-purpose models at similar scale. This is a specialist tool for coding, not a daily driver.
  • MoE serving complexity for code workloads. Production-grade code generation with MoE requires vLLM / SGLang with MoE routing optimizations. Not all serving stacks handle DeepSeek MoE efficiently for code-specific workloads.
  • Training data cutoff limits library/API knowledge. The coding training data has a cutoff date — newer libraries, APIs, and framework versions released after training aren't reflected. Supplement with retrieval for up-to-date coding.

Real-world performance

  • vs DeepSeek Coder V3: Coder V3 is the direct architectural upgrade with improved coding benchmarks and MoE serving efficiency. Coder V2 is the previous generation — still excellent but superseded. New deployments should pick V3 unless ecosystem compatibility favors V2.
  • vs DeepSeek V4: DeepSeek V4 is a general-purpose frontier model that codes well. Coder V2 is a coding specialist that handles non-coding tasks worse. For coding-only workloads, Coder V2 may match or exceed V4 on code-specific benchmarks at lower hardware cost.
  • vs Codestral Mamba 7B: Different weight classes entirely. Coder V2 is 236B with massive coding capability; Codestral is 7B with fast, efficient code completion. Coder V2 wins code quality; Codestral wins throughput and accessibility. Different use cases.

Should you run this locally?

Yes if coding is your dominant workload, you need the highest open-weight code generation quality available, you have workstation-class hardware (Mac Studio M3 Ultra or dual A100), and DeepSeek's license works for your deployment. DeepSeek Coder V2 delivers coding capability that general-purpose models cannot match.

No if you can use DeepSeek Coder V3 (architectural upgrade), your workload is mixed coding + general tasks (pick DeepSeek V4 or Qwen 2.5 72B Instruct), or you lack workstation-class hardware (pick smaller coding models like CodeGemma 7B or Codestral Mamba 7B).

How it compares

  • vs DeepSeek Coder V3: V3 is architectural successor; V2 is previous gen. Pick V3 unless V2 ecosystem advantage exists.
  • vs DeepSeek V4: Coder V2 is coding specialist; V4 is general-purpose frontier. Different optimization targets.
  • vs CodeGemma 7B: Coder V2 is massively larger and more capable; CodeGemma fits consumer GPUs.
  • vs Codestral Mamba 7B: Different scales and architectures. Coder V2 for quality; Codestral for speed.

Run this yourself

  • Datacenter: 2-4× H100 PCIe at FP8 with vLLM MoE routing. Production target: 60-90 tok/s.
  • Workstation: Mac Studio M3 Ultra (192 GB) at Q4 — comfortable fit at 10-15 tok/s.
  • Single-GPU: A100 80GB at Q3 with offload — marginal. Dual A100 preferred.
  • Vendor: huggingface.co/deepseek-ai/DeepSeek-Coder-V2-236B

Overview

Full DeepSeek Coder V2. 236B total / 21B active MoE coder.

How to run it

DeepSeek Coder V2 236B is DeepSeek's large code-specialized MoE model — 236B total parameters (21B active per token with 2-of-27 expert routing). Run at Q4_K_M via llama.cpp with -ngl 999 -fa -c 16384. Q4_K_M file size ~135 GB on disk (full MoE). Minimum VRAM: 160 GB — 4× RTX A6000 (48GB each) with row-split, or 2× A100 80GB. Expert offload: with only active experts (42B total) in VRAM, VRAM drops to ~35-40 GB for weights + expert offload latency on routing. Recommended: 4× A100 80GB at AWQ-INT4 for all experts in VRAM. Throughput: ~10-20 tok/s on 4× A100 at Q4_K_M (8K context). The MoE architecture makes per-token compute efficient — ~21B active feels like a ~30B dense model for generation speed. DeepSeek Coder's architecture is well-supported in llama.cpp and vLLM (DeepSeek MoE kernels). Context: 128K advertised; practical at Q4 on 4× A100 is 8-16K.

Hardware guidance

Minimum: 2× A100 80GB at Q4_K_M with expert offload. Recommended: 4× A100 80GB at AWQ-INT4 (all experts in VRAM). Budget: 4× RTX A6000 192 GB at Q4_K_M with row-split. VRAM math: 236B total MoE, Q4 ≈ 135 GB. Expert offload reduces VRAM to ~35-40 GB active experts + RAM-resident inactive experts (adds routing latency). KV cache at 8K: ~10-15 GB. Total with all experts in VRAM: ~150 GB at 8K. 2× A100 80GB = 160 GB — tight. 4× A6000 192 GB — comfortable. RTX 4090 × 4 = 96 GB — insufficient for Q4 without aggressive expert offload to RAM. Mac Studio M4 Ultra 192 GB: Q4_K_M at 2-5 tok/s with expert offload. Cloud: 2-4× A100 at $10-30/hr.

What breaks first

  1. DeepSeek MoE architecture. DeepSeek Coder V2 uses a custom MoE with shared experts + routed experts. Standard Mixtral MoE kernels in vLLM/llama.cpp may not handle the shared expert component correctly. Verify DeepSeek-specific MoE support. 2. Expert offload latency. With experts in system RAM, routing decisions hitting RAM-resident experts cause 50-150ms stalls. For code generation (which often has long, linear outputs), frequent stall patterns are disruptive. 3. Code quality at Q4. Code generation is precision-sensitive. Q4_K_M may produce measurably worse code (more bugs, worse structure) than Q8 or FP8. Benchmark your specific coding tasks. 4. DeepSeek's tokenizer. DeepSeek Coder uses a code-optimized tokenizer. Natural language prompts may be less token-efficient than specialized code prompts.

Runtime recommendation

vLLM with DeepSeek MoE support for production serving. llama.cpp with -ngl 999 for local multi-GPU use. DeepSeek Coder V2 is well-supported in both. SGLang if vLLM MoE routing is unstable. Avoid Ollama for multi-GPU — raw llama.cpp gives better tensor-split control.

Common beginner mistakes

Mistake: Assuming 236B needs 236 GB VRAM. Fix: Q4_K_M is ~135 GB. With expert offload, VRAM requirement drops to ~40 GB (active experts only). Do the math with your quantization. Mistake: Using standard Mixtral GGUF conversion for DeepSeek. Fix: DeepSeek has shared + routed experts. Use DeepSeek-specific GGUF conversion scripts. Mistake: Setting context to 128K on minimum hardware. Fix: KV cache at 128K is 80-100+ GB. 2× A100 at 160 GB with 135 GB weights = 25 GB left for KV = ~2K context. Scale context based on available VRAM after weights. Mistake: Expecting chat-quality code explanations. Fix: DeepSeek Coder V2 is code-specialized — it generates code, not conversational explanations. Use instruct variants for chatty code help.

Family & lineage

How this model relates to others in its lineage. Family members share architecture and training-data roots; parent / children edges record direct distillation or fine-tune relationships.

Family siblings (deepseek-coder)
DeepSeek Coder V2 Lite (16B)16B
Consumer
DeepSeek Coder V2 236B236B
You are here

Strengths

  • MoE coding at frontier scale

Weaknesses

  • Cluster-only deployment

Quantization variants

Each quantization trades model quality for file size and VRAM. Q4_K_M is the most popular starting point.

QuantizationFile sizeVRAM required
Q4_K_M134.0 GB160 GB
Rent instead
Too big for a 32 GB card? Rent a GPU by the hour

At Q4 DeepSeek Coder V2 236B needs about 160 GB of memory by our estimate, more than a 32 GB graphics card holds. Renting a GPU with enough memory (or several GPUs) by the hour is the practical way to try it before you plan hardware for it.

Referral links: RunLocalAI may earn a commission or account credits if you sign up and rent, at no extra cost to you. Hourly rates and which GPUs are listed change all the time, so check the provider's page before you start. How we make money.

Get the model

HuggingFace

Original weights

huggingface.co/deepseek-ai/DeepSeek-Coder-V2-Instruct

Source repository — direct quantization required.

Hardware that runs this

Cards with enough VRAM for at least one quantization of DeepSeek Coder V2 236B.

Compare alternatives

Models worth comparing

Same parameter band, plus what's one tier above and below — so you can decide what actually fits your hardware.

Step up
More capable — bigger memory footprint
No verdicted models in the next tier up yet.

Frequently asked

What's the minimum VRAM to run DeepSeek Coder V2 236B?

160GB of VRAM is enough to run DeepSeek Coder V2 236B at the Q4_K_M quantization (file size 134.0 GB). Higher-quality quantizations need more.

Can I use DeepSeek Coder V2 236B commercially?

Yes — DeepSeek Coder V2 236B ships under the DeepSeek License, which permits commercial use. Always read the license text before deployment.

What's the context length of DeepSeek Coder V2 236B?

DeepSeek Coder V2 236B supports a context window of 131,072 tokens (about 131K).

Source: huggingface.co/deepseek-ai/DeepSeek-Coder-V2-Instruct

Reviewed by RunLocalAI Editorial. See our editorial policy for how we research and verify model claims.

Related — keep moving

Before you buy

Verify DeepSeek Coder V2 236B runs on your specific hardware before committing money.