Vram For Llm Memory Chart
Image: Saganote

VRAM for Local LLMs: How Much Each Model Size Needs at Every Quantization Level

Weights set the floor, context adds a growing cache, and a short formula estimates memory before any download

TL;DR: An 8B model at Q4_K_M needs about 5 GB for weights and 70B needs about 43 GB, context adds a cache that grows with every token, and a three-line formula estimates any model.

VRAM for LLM inference comes down to three numbers: the weights, the KV cache, and a fixed runtime overhead of about 0.7 GB at short context, according to computingforgeeks. Weights depend on parameter count and quantization. Context length drives the cache.

Weights Set the Floor: Memory by Model Size and Quantization

Each cell below is parameters times bits per weight, divided by eight, using the llama.cpp bits-per-weight figures for Llama 3.1 8B. Real files track the math closely. A Llama 3.3 70B Q4_K_M file measures 42.5 GB against a calculated 42.8 GB, per computingforgeeks.

Model sizeQ4_K_MQ5_K_MQ6_KQ8_0FP16
8B4.9 GB5.7 GB6.6 GB8.5 GB16.0 GB
14B8.6 GB10.0 GB11.5 GB14.9 GB28.0 GB
32B19.6 GB22.8 GB26.3 GB34.0 GB64.0 GB
70B42.8 GB49.9 GB57.4 GB74.4 GB140.0 GB
Bar chart of model weights memory for 8B, 14B, 32B, and 70B models at Q4_K_M, Q8_0, and FP16
Chart: Saganote, data: llama.cpp quantization table

Totals run higher than weights alone. Saganote's Ollama setup guide gave rounder ranges from two third-party guides, and this page splits those ranges into their parts. Add the cache and overhead from the sections below before choosing a card, because a model that fits on paper can still fail once a long chat begins.

Each Quantization Level Stores Fewer Bits Per Weight

Quantization shrinks a large language model by storing each weight in fewer bits. llama.cpp's table lists 4.89 bits per weight for Q4_K_M, 5.70 for Q5_K_M, 6.56 for Q6_K, 8.50 for Q8_0, and 16.0 for FP16. Q4_K_M is the common default. ToolHalla and DEV Community both assumed it in their own tables.

Lower bits cost some quality, and the guides read for this page measure memory rather than accuracy, so no benchmark data backs a quality claim here. Flavio Copes calls Q4_K_M a common sweet spot. A 70B model at FP16 needs about 140 GB, which no consumer card holds.

Context Length Adds a KV Cache That Grows With Every Token

A KV cache stores attention data for every token. Computingforgeeks puts Llama 3.1 8B at 128 KiB per token at f16, which works out to about 1.1 GB at 8K context, 4.3 GB at 32K, and 17.2 GB at 128K. Qwen3 32B uses 256 KiB per token, and Llama 3.3 70B uses 320 KiB.

Servers allocate that cache up front. Per computingforgeeks, it is sized for the maximum context configured and "grows linearly with that length and with every concurrent request." Long chats and large documents cost memory too, and retrieval pipelines that stuff documents into prompts, such as retrieval-augmented generation with embedding models like NVIDIA's Nemotron 3 Embed, push context upward fast.

Apple Silicon Shares One Memory Pool With the GPU

Macs have no separate VRAM. Their GPU draws from unified memory, and macOS caps how much of it the GPU can use. Computingforgeeks says the cap is about two thirds of RAM on smaller Macs and three quarters on larger ones, so a 64 GB Mac behaves like a 48 GB GPU.

Flavio Copes uses about 72%, which gives roughly 11.5 GB on a 16 GB Mac and 46 GB on a 64 GB Mac. Guides differ by a couple of gigabytes. Treat Mac figures as ranges. Ollama's quickstart recommends 8 GB of VRAM, or unified memory on a Mac, for its example model.

Raising the Mac GPU memory limit has risks

Computingforgeeks says the cap can be raised with the iogpu.wired_limit_mb setting through sudo sysctl, but gives no safe value. Giving the GPU too much memory can starve macOS and other apps, so leave room for the system.

GPU Memory Tiers and the Models That Fit

Cards come in a few memory sizes, and each tier maps to a model class, using recommendations from computingforgeeks, Flavio Copes, and Plugable at Q4_K_M and short context. Anything beyond that needs the cache math above.

GPU memoryExample cardsWhat fits at Q4_K_M
12 GBRTX 3060 12 GB7B to 8B models; Plugable calls 12 GB a sweet spot
16 GBRTX 4060 Ti 16 GB, RTX 5060 Ti 16 GB12B to 14B models such as Gemma 4 12B (7.1 GB file)
24 GBRTX 3090, RTX 409027B to 32B at short context; a 70B does not fit
32 GBRTX 509032B with longer context; a 70B still does not fit
48 GBRTX 6000 Ada70B at Q4_K_M with about 16K context
96 GBRTX PRO 6000 Blackwellgpt-oss-120b, or 70B with long context

Guides disagree on one point. Flavio Copes says a 32B model fits a 24 GB card, while computingforgeeks finds that Qwen3 32B at 32K context needs about 29 GB and spills off the card unless context is capped or the cache is quantized. Both statements hold, because context length decides the outcome.

Mixture-of-experts models change the picture again. Computingforgeeks lists gpt-oss-120b at 62.6 to 65.4 GB at every quantization level, and DeepSeek V4 Flash, a 284B MoE, at 90.9 GB even at a 2-bit-class quant. Saganote covered the DeepSeek V4.1 Flash launch with native vision, and NVIDIA's Nemotron agent models for PCs and servers target the same hardware range.

A Formula Estimates Any Model Before Downloading

Three pieces combine into one estimate when sizing VRAM for LLM use, with the same cache formula published by both Flavio Copes and computingforgeeks. Plugable's article uses a flat 1.4 multiplier. Its own 7B figures disagree with that formula.

weights_gb  = parameters_in_billions x bits_per_weight / 8
kv_cache_gb = 2 x layers x kv_heads x head_dim x bytes_per_value x context_tokens / 1e9
total_gb    = weights_gb + kv_cache_gb + 0.7

8B,  Q4_K_M, 8K context: 4.9 + 1.1 + 0.7 = 6.7 GB
32B, Q4_K_M, 8K context: 19.6 + 2.2 + 0.7 = 22.5 GB
70B, Q4_K_M, 8K context: 42.8 + 2.7 + 0.7 = 46.2 GB

Per-token cache sizes come from computingforgeeks: 128 KiB for 8B, 256 KiB for 32B, and 320 KiB for 70B. Runtimes vary. Keep 2 to 4 GB of headroom, the margin DEV Community advises when sizing VRAM for LLM workloads. Google is also building a chip with Gemini baked into the hardware, a sign that inference hardware keeps changing faster than these tables.

Frequently Asked Questions

How much VRAM does an 8B model need?
About 5 GB for Q4_K_M weights, or roughly 6.7 GB with 8K context and runtime overhead. Q8_0 needs about 8.5 GB for weights and FP16 about 16 GB.
Can a 24 GB card run a 70B model?
Not at Q4_K_M. A 70B file is about 42.5 GB, so it needs 48 GB or more, or a Mac with enough unified memory.
Does a longer context window use more memory?
Yes. The KV cache grows linearly with context, and Llama 3.1 8B uses about 1.1 GB at 8K and about 17.2 GB at 128K at f16.
How much of a Mac's memory can the GPU use?
Computingforgeeks says about two thirds on smaller Macs and three quarters on larger ones. Flavio Copes uses about 72%.
Is Q4_K_M good enough?
Both guides call it a common default. Quality loss depends on the model and task, and these sources measure memory, not accuracy.

Share this
Waqas Ahmad

About Author

Waqas Ahmad

Waqas Ahmad is a technology writer at Saganote and a software professional with more than a decade of experience in the software industry. He primarily writes about artificial intelligence, AI products, developer tools, software development, and emerging technologies.