StarCoder 2 15B — VRAM, Speed & Local Setup

Written by Jakub Rusinowski · Last updated February 28, 2024

Model libraryStarCoder 2 → StarCoder 2 15B

The flagship StarCoder model. HumanEval score of 46.4%, beating many larger general-purpose models on code tasks. Excellent at generating and explaining complex code in 600+ languages.

StarCoder 2 15B needs about 10 GB of VRAM at Q4_K_M — quantized weights plus framework overhead, before any KV cache. On Apple Silicon that figure comes out of unified memory.

Specifications

Parameters15 Billion
Context window16,384
ArchitectureDense
ProviderBigCode
LicenceBigCode Open RAIL-M v1
Specified atQ4_K_M
System RAM24 GB
Record updated2024-02-28

Licence

BigCode OpenRAIL-Mcommercial use permitted. Weights are downloadable and commercial use is permitted, subject to the licence’s acceptable-use terms.

VRAM and Speed by Quantization

Modelled on a reference NVIDIA RTX 4090 (24 GB), at 8K context. Speed figures are ESTIMATES from the memory-bandwidth roofline described on the methodology page, not benchmarks we ran — rows marked measured come from published or reader-submitted runs. VRAM here includes the KV cache, so it reads higher than the headline figure above, which does not.

QuantWeightsVRAM neededEst. speedFit on 24 GB
Q2_K5.1 GB6.6 GB~106 tok/s (est.)Fits comfortably
Q3_K_M6.6 GB8.1 GB~87 tok/s (est.)Fits comfortably
Q4_K_M9.4 GB10.8 GB~66 tok/s (est.)Fits comfortably
Q5_K_M11.0 GB12.5 GB~58 tok/s (est.)Fits comfortably
Q6_K12.7 GB14.2 GB~51 tok/s (est.)Fits comfortably
Q8_016.5 GB17.9 GB~41 tok/s (est.)Fits comfortably
F1631.0 GB32.5 GB~3 tok/s (est.)Offloads to system RAM (slow)

Want the memory numbers alone, at every quantization level and your own context length? Use the StarCoder 2 15B VRAM calculator.

Buy This HardwareIntel Arc B580 12GB — 12 GB VRAM · 190 W board powerDeploy in the Cloud NowRTX 4090 on RunPod — from $0.34/hr · rate checked 2026-07

or compare on Vast.ai from $0.35/hr (typical low · varies)

As an Amazon Associate we earn from qualifying purchases. Cloud GPU links are referral links — we may earn a commission at no extra cost to you.

Recommended GPU

The cheapest catalogued GPU that runs StarCoder 2 15B is the Intel Arc B570 (10 GB).

Affiliate disclosure: Some links on this page are affiliate links — if you buy through them, LLM Configurator may earn a commission at no extra cost to you. As an Amazon Associate, LLM Configurator earns from qualifying purchases.
Intel Arc B570 10GB
10 GB VRAM · 150 W board power
2026 prices are volatile — check the current listing.
Check price on Amazon

How to Run StarCoder 2 15B

Install Ollama, then run:

ollama run starcoder2:15b

Weights on Hugging Face: bigcode/starcoder2-15b.

Best for: coding agent, code review, dev work.

Can I Run StarCoder 2 15B on My GPU?

Other StarCoder 2 Sizes

StarCoder 2 15B — Frequently Asked Questions

How much VRAM does StarCoder 2 15B need?
About 10 GB at Q4_K_M — quantized weights plus framework overhead, before any KV cache. The cache grows with context length and is added on top; the table above folds it in. Apple Silicon counts unified memory toward the same figure.
Does StarCoder 2 15B run on an RTX 4090 (24 GB)?
Yes. StarCoder 2 15B needs about 10 GB at Q4_K_M, inside a 24 GB card, at an estimated 66 tokens/sec.
How do I run StarCoder 2 15B locally?
Install Ollama and run `ollama run starcoder2:15b`. That pulls the weights and starts a local OpenAI-compatible endpoint; after the download nothing leaves the machine.
What other sizes does StarCoder 2 come in?
StarCoder 2 3B (3 GB), StarCoder 2 7B (5 GB), StarCoder 2 15B (10 GB). Every size shares the family's training and licence; the larger ones score higher and need proportionally more memory.

← All StarCoder 2 models | VRAM calculator | Check your own hardware