VRAM calculator
Pick a model, a quantisation and a context length: see how much GPU memory it needs and the cheapest GPUs that run it.
How it is counted
- Weights are the real size of the published file: GGUF builds by unsloth and others, FP8 and BF16 from Hugging Face. Without a file we count from the parameters: Q4_K_M is 4.84 bits per weight, Q8_0 is 8.5.
- The context cache follows the model's config.json: layers, KV heads and their size. Sliding windows (Gemma, GPT-OSS), compressed MLA caches (DeepSeek, Kimi) and linear-attention layers (Qwen3.5, Qwen3.8), whose cache does not grow with the context, are taken into account.
- Runtime is the CUDA context and buffers: about 0.75 GB plus the logits buffer of a 512-token batch.
- A model fits when the total is under 97.5% of the card: the driver and CUDA take the rest. vLLM takes 90% of the memory for its cache by default, which is expected.
- Image and video models are counted for ComfyUI: the text encoder runs first and is swapped out, then the model, the VAE and the sampling memory stay.
- “Minimum” is what ComfyUI does by default when memory is short. “No swapping” keeps everything loaded, so repeated runs are faster.
- Working memory is our estimate for the listed output size and frame count. ComfyUI also runs the model on a smaller card by swapping part of the weights to system RAM, only slower.