Free compute calculator
LLM VRAM Calculator for Model Weights
Model-weight memory is approximately parameter count multiplied by bits per weight, divided by eight. This calculator converts that value to GiB, adds configurable runtime headroom, and compares the estimate with available GPU memory. It intentionally separates this transparent estimate from KV cache, activations, and framework-specific allocations.
Last updated: July 19, 2026 · No sign-up · Runs in your browser
Model and GPU inputs
First-pass estimate
Weights only
—
With headroom
—
GPU fit
—
Minimum GPU count by capacity
—
Formula and methodology
The calculator uses binary GiB: parameters × bits ÷ 8 ÷ 1,073,741,824. The headroom percentage covers a user-selected allowance for runtime allocations, but it is not a model-specific benchmark. Actual memory can be higher because of quantization metadata, non-quantized layers, KV cache, activations, batching, fragmentation, and the inference framework.
| Step | Calculation |
|---|---|
| Weight bytes | parameters × bits per weight ÷ 8 |
| Binary GiB | weight bytes ÷ 1,073,741,824 |
| Headroom estimate | weight GiB × (1 + selected headroom) |
| Capacity-only GPU count | ceil(estimated GiB ÷ usable GiB per GPU) |
Primary reference
Hugging Face Transformers: Quantization concepts explains lower-bit weight representations and the implementation tradeoffs behind 8-bit and 4-bit loading. Real formats may use extra metadata and mixed precision.
Frequently asked questions
How much VRAM does a 7B model need at FP16?
Seven billion parameters at 16 bits require about 13.0 GiB for weights alone. Runtime allocations, KV cache, activations, and framework overhead increase the total requirement.
Does 4-bit quantization always use exactly one quarter of FP16 memory?
No. Four bits per weight gives a useful lower-bound calculation, but real formats add scales, metadata, non-quantized modules, temporary buffers, and framework allocations.
Does this calculator include KV cache?
No. KV cache depends on architecture, layers, hidden dimensions, grouped-query attention, context length, batch size, and cache precision. The result deliberately labels model weights and configurable headroom separately.