TechCompare LogoTechCompare

How much VRAM does Mixtral 8x7B need at Q4_K_M? MoE memory math

Mixtral 8x7B is the rare model where memory is the bottleneck and compute is cheap. It needs at minimum a 32 GB card or a 24 GB card with Q8 KV cache and reduced context. When it fits, it's one of the fastest high-quality local options.

Mixtral 8x7B at Q4_K_M with 32K context needs about 34 GB of VRAM. Mixture-of-experts is the wrinkle here: even though only 2 of the 8 experts activate per token, all 8 must be in memory at all times. That makes Mixtral 8x7B effectively a 47B-parameter model from a memory standpoint, even though it computes like a 12B.

By TechCompare · Updated

Total VRAM required
33.7 GB
Mixtral 8x7B at Q4_K_M
Weights
26.3 GB
47B params
KV cache
4.3 GB
32K tokens, FP16 KV

Calculator

Estimated VRAM required

33.7 GB

47B params at Q4_K_M, 32,768 token context, batch 1, inference.

Weights
26.3 GB
KV cache
4.3 GB
Overhead
3.1 GB
Doesn't fit on a 32 GB consumer GPU at Q4_K_M. Q2_K (21.3 GB) is the smallest quant that fits a single RTX 5090.

Estimate accuracy: Weights within ~2%. KV cache within ~5% for standard GQA models, ~10% for MLA (DeepSeek). Real VRAM may vary with framework (vLLM vs llama.cpp vs Transformers), Flash Attention, and driver overhead.

Custom architecture - SWA not applied. If you're modeling Gemma 3/4 or Mistral Nemo, pick the preset for accurate KV cache.

Hardware that fits

A100 40GB
Datacenter
40 GB
84% used
Apple M3 Max 64GB
Unified
48 GB
70% used
RTX 6000 Ada
Pro
48 GB
70% used

Just barely too small

RTX 5090
Consumer
32 GB
short by 1.7 GB

How this is calculated

MoE is a compute optimization, not a memory one. The 8 expert FFN blocks plus the shared attention give Mixtral roughly 47B total parameters that must all be loaded in VRAM. At Q4_K_M that's about 26 GB of weights, plus ~4.3 GB of KV cache at 32K context. The benefit is throughput - inference runs at the speed of a 12B dense model, so you get 70B-class quality at 12B-class generation speed if it fits.

Verdict

Mixtral is the case study for MoE memory reality: only 2 of 8 experts run per token, but the router can hit any expert on any forward pass, so all 47B of parameters must stay resident. At Q4_K_M that's 26 GB of weights plus 4.3 GB of KV cache at 32K context, totaling about 34 GB. A 32 GB card fits it cleanly, a 24 GB card needs Q8 KV and a context cap to clear the gate, otherwise the same gen-rate math applies. The reward is throughput that matches a 12-13B dense model because only 2 experts compute per token, so you get 47B-class quality at 13B-class generation speed. That's the structural MoE win that justifies the memory cost.

More Mistral scenarios

DeepSeek V4 Pro 1.6T (MoE) at Q4_K_M
DeepSeek V4 Pro 1.6T at Q4_K_M with the full 1M-token context needs about 1012 GB of VRAM with every expert resident - this is the real shape of the model and the number to plan a deployment against.
View details ➜
Llama 4 Scout (17B/109B) at Q4_K_M
Llama 4 Scout at Q4_K_M with its native 10M context needs about 2231 GB of VRAM with all 109B params resident - that's the number you size hardware against.
View details ➜
gpt-oss 20B (MoE) at Q4_K_M
gpt-oss 20B at Q4_K_M with native 128K context needs about 19.4 GB of VRAM with all experts resident, dropping to roughly 9.3 GB with active-only weight loading.
View details ➜

Frequently asked questions

Why does Mixtral 8x7B use so much memory if only 2 experts run?
Because all 8 experts must be in memory at all times. The router selects which 2 to activate per token, but switching is per-token, so swapping experts in and out of VRAM would be far slower than just keeping them all loaded.
How fast is Mixtral 8x7B compared to a dense 47B model?
Significantly faster - generation throughput approximates a dense 12-13B model since only 2 of 8 experts compute per token, even though total memory is the full 47B at the chosen quant.
How fast is Mixtral 8x7B compared to a dense 47B model?
Mixtral computes only the per-token-active subset (roughly 13B parameters in two experts) at inference, so per-token throughput is closer to a 13B dense model than a 47B one. The catch is you need roughly 26 GB of VRAM resident for the full 47B parameter pool at Q4 plus the KV cache. Faster per token, same total memory footprint.
Why does a Mixture-of-Experts model still need all parameters in memory?
Because any expert might be picked for the next token. The router only activates two experts per forward pass, but the identity of those experts changes token to token, so the full 47B pool has to be loadable at inference time even though only 13B's worth does math each cycle. Memory holds the whole team, but compute only pays for the players on the field.