Published 2026-09-27 · Last updated 2026-09-27

Local LLM & AI VRAM Calculator

The short answer: an 8B model at Q4 with an 8K context needs about 7GB of RAM, a 32B model needs about 24GB, and Llama 3.3 70B at Q4 needs about 44GB — always plus a 2GB buffer for the OS. Set the model, quantization, and context below to get the exact number and matched laptops.

Weights
19.7 GB
KV cache
2.15 GB
OS buffer
2 GB
Total
23.8 GB

Buy at least 24GB of RAM to run Qwen 2.5 32B / DeepSeek-R1 32B at Q4_K_M with a 8K context. On a 135GB/s memory class, expect roughly 5.8 tokens/sec — generation speed is bandwidth-bound, not TOPS-bound.

24GB+ laptops that run this model

LaptopRAMChipPrice
Razer Blade 16 (2025, RTX 5090)64GBAMD Ryzen AI 9 HX 370 + NVIDIA RTX 5090$4,499Check price
HP ZBook Ultra G1a (Ryzen AI Max+ 395)128GBAMD Ryzen AI Max+ 395 (Strix Halo)$3,499Check price
Apple MacBook Pro 14" (M4 Max)64GBApple M4 Max (16-core CPU, 40-core GPU)$3,199Check price

NPU TOPS / tokens-per-sec figures in our dataset are AIPC simulated benchmark profiles based on chip-class data.

Cheat sheet: common setups

Pre-computed with the same formula the calculator uses (Q4_K_M unless stated, 8K context unless stated).

Model + quantContextTotal memoryRAM to buy
Llama 3.1 8B Instruct — Q4_K_M8K~8GB8GB
Qwen 2.5 14B Instruct — Q4_K_M8K~12GB16GB
Qwen 2.5 32B / DeepSeek-R1 32B — Q4_K_M8K~24GB24GB
Qwen 2.5 32B / DeepSeek-R1 32B — Q6_K8K~31GB32GB
Llama 3.3 70B Instruct — Q4_K_M8K~47GB48GB
Llama 3.3 70B Instruct — Q4_K_M32K~55GB56GB

The formula we use

Required RAM ≈ (parameters × bytes per parameter) + (2 × layers × KV heads × head dimension × 2 bytes × context tokens) + 2GB OS and runtime buffer. The first term is the quantized model weights; the second is the KV cache, which grows linearly with context. All models listed use grouped-query attention, which keeps the KV cache manageable. For generation speed: tokens/sec ≈ memory bandwidth ÷ weights in GB. For the vocabulary behind this, see our AI PC glossary, and for chip timelines see the AI PC roadmap.

Frequently asked questions

How much RAM do I need to run Llama 3.3 70B locally?

At Q4_K_M quantization with an 8K context, Llama 3.3 70B needs roughly 44GB of memory — about 42GB for the quantized weights, under 2GB of KV cache, plus a 2GB OS and runtime buffer. That means 64GB of unified memory (Apple M5 Pro/Max class) or a laptop with 64GB RAM. On 32GB it does not fit, even heavily quantized.

How much RAM do I need to run a 7B–8B model locally?

An 8B model at Q4_K_M with an 8K context needs about 7GB total: 4.8GB of weights, 0.2GB of KV cache, and a 2GB buffer. 16GB of RAM runs it comfortably; 32GB lets you run larger contexts or a 14B model alongside your other work.

Does quantization affect RAM requirements?

Yes — quantization is the biggest lever. FP16 needs about 2 bytes per parameter, Q8 about 1, and Q4_K_M about 0.6. A 70B model drops from 141GB (FP16) to about 42GB (Q4_K_M), which is the difference between a datacenter GPU and a 64GB laptop. Quality loss at Q4_K_M is small for most tasks.

Why does memory bandwidth matter as much as RAM size?

Local LLM token generation is memory-bandwidth bound: each generated token requires reading the model weights from memory. As a rule of thumb, tokens per second ≈ memory bandwidth ÷ model size in GB. A ~135GB/s laptop generates roughly 3 tokens/sec on a 32B Q4 model; a ~540GB/s M5 Max-class machine generates roughly 4x that on the same model.

How much RAM for the KV cache and long context?

KV cache scales linearly with context length and varies by model architecture. For Llama 3.3 70B, an 8K context costs about 1.7GB, and 128K costs about 27GB. Models using grouped-query attention (all models listed in the calculator) keep this far smaller than older architectures.

Methodology: memory figures follow public model architectures (layer counts, KV-head counts, head dimensions) and standard GGUF quantization scales; add ~10% headroom for tokenizer, libraries, and fragmentation. As of 2026-09-27.