Best Local LLMs for Coding

Written by Jakub Rusinowski · Last updated September 11, 2026

Writing, refactoring and debugging code in an editor or terminal, with the model reading real project files.

Want one agentic coder and one autocomplete model matched to your exact GPU, with setup steps? Pick by memory tier →

Top pick: Qwen 3 32B

Scores 95.4/100 for coding and software engineering. 33B parameters, needing about 20.6 GB at Q4_K_M, 125K context, Apache 2.0.

Ranked for coding and software engineering

ModelScoreParamsContextLicenceQuality index
1. Qwen 3 32B95.433B125KApache 2.0— (estimated)
2. Qwen 3.6 35B-A3B95.235B256KApache-2.0— (estimated)
3. Devstral Small 2 24B94.924B256KApache-2.0— (estimated)
4. DeepSeek R1 Distill Qwen 32B94.932B128KMIT87 (cited)
5. Gemma 4 31B94.831B250KApache-2.0— (estimated)
6. Ternary Bonsai 27B94.127B256KApache 2.0— (estimated)

Frontier open-weight models (multi-GPU / private cloud)

These also score for coding and software engineering, but none runs on a single consumer GPU or workstation, so they are listed apart rather than ranked against the local picks above.

Best pick for your memory budget

The strongest model overall is rarely the right answer — what matters is the strongest model that fits the memory you have. These picks are re-ranked per tier, so each one uses its budget rather than simply being small.

MemoryTypical hardwareRecommended models
8 GBRTX 4060, RTX 3070, base MacBook AirTernary Bonsai 27B (94.1)
Qwen 3 8B (92.9)
IBM Granite 4.1 Granite 4.1 8B (91.1)
12 GBRTX 3060 12 GB, RTX 5070Qwen 3 14B (95.9)
DeepSeek R1 Distill Qwen 14B (94.2)
Ternary Bonsai 27B (93.5)
16 GBRTX 5080, RTX 4080, RX 9070 XTDevstral Small 2 24B (96.5)
Qwen 3 14B (95.9)
DeepSeek R1 Distill Qwen 14B (93.9)
24 GBRTX 4090, RTX 3090, RX 7900 XTXQwen 3 32B (98)
Qwen 3.6 35B-A3B (97.8)
DeepSeek R1 Distill Qwen 32B (97.5)
48 GBRTX 6000 Ada, MacBook Pro M4 Max 48 GBQwen 3.6 35B-A3B (96.2)
Qwen 3 32B (96.1)
Llama 3.3 70B Instruct (96.1)
128 GB+Mac Studio, DGX Spark, multi-GPUDevstral-2 123B (99)
Qwen3-Coder-Next (80B-A3B MoE) (96.6)
Qwen3.8-Flash-Next (94.2)

How this ranking works

Coding score carries 60% of the capability weight and reasoning the remaining 35%, because most real editor work is "understand this repo, then write correct code". Context is weighted heavily: below 16K tokens a model cannot hold a meaningful slice of a codebase, and 128K is treated as fully served. Latency matters (0.7) — a coding assistant slower than you type stops being used.

Worked example — Qwen 3 32B: capability 95.9 × 0.419, quality 93.7 × 0.247, context 97.3 × 0.16, license 70 × 0.044, accessibility 80 × 0.129 + 3 tag bonus (coding).

Requirements applied: context floor 16,384 tokens (ideal 131,072), quality floor 55, licence weight 0.4, latency weight 0.7.

Running coding and software engineering locally

FAQ

What is the best local LLM for coding and software engineering?

Qwen 3 32B, scoring 95.4/100 against this workload's published requirements. 183 models qualified.

What hardware do I need for coding and software engineering?

A credible answer starts at 8 GB of memory. Larger budgets unlock materially stronger models — the table above lists the best pick at each tier.

How were these models ranked?

Coding score carries 60% of the capability weight and reasoning the remaining 35%, because most real editor work is "understand this repo, then write correct code". Context is weighted heavily: below 16K tokens a model cannot hold a meaningful slice of a codebase, and 128K is treated as fully served. Latency matters (0.7) — a coding assistant slower than you type stops being used.

Hardware for This Workload

Related Workloads

Top Pick

Tools

← All workloads | Check your hardware