Model memory requirements

Llama 3.1 405B memory requirements for inference

How much GPU or accelerator memory Llama 3.1 405B needs at different precisions and context lengths, and which chips can hold it. Last reviewed 2 December 2026.

Short answer. Llama 3.1 405B needs about 896 GB in FP16, 450 GB in FP8 and 255 GB in 4-bit for a single 8,192-token sequence (weights, FP16 KV cache and a 10% allowance). Change the settings in the calculator.

Total memory by precision and context length

GB for one sequence: weights plus FP16 KV cache plus a 10% allowance. Column heads are context length in tokens.

Weight precisionWeights only2k ctx8k ctx32k ctx128k ctx
FP16 / BF16810892896910965
FP8405447450464520
INT8405447450464520
INT4 (about 4.5-bit)228252255269325

Each extra concurrent sequence adds its own KV cache: about 4.2 GB at 8,192 tokens in FP16, and about 67.6 GB at 131,072 tokens.

How many of each chip you need

Minimum devices by memory capacity, for one 8,192-token sequence with an FP16 KV cache. Green means it fits on a single device.

ChipMemoryFP16FP84-bit
NVIDIA H100 SXM80 GB1264
NVIDIA H200 SXM141 GB742
NVIDIA B200 SXM (HGX)180 GB532
NVIDIA Rubin288 GB421
NVIDIA A100 80GB80 GB1264
NVIDIA L40S48 GB19106
AMD Instinct MI300X192 GB532
AMD Instinct MI325X256 GB421
AMD Instinct MI355X288 GB421
Intel Gaudi 3128 GB742
Intel Crescent Island160 GB632
Google TPU v5e16 GiB532715
Google TPU v5p95 GiB953
Google TPU v7 (Ironwood / TPU7x)192 GiB532
AWS Trainium296 GiB953
AWS Inferentia232 GiB27148
NVIDIA RTX PRO 6000 Blackwell96 GB1053
NVIDIA DGX Spark (GB10)128 GB742
NVIDIA RTX 309024 GB381911
NVIDIA RTX 409024 GB381911
NVIDIA RTX 509032 GB28158
AMD Radeon RX 7900 XTX24 GB381911
Apple M4 Max (128 GB config)128 GB742
Apple M3 Ultra (256 GB config)256 GB421

On the largest accelerator in the table (NVIDIA Rubin, 288 GB), Llama 3.1 405B needs at least 4 devices in FP16 and 1 in 4-bit. Unified-memory machines share their pool with the operating system, so usable capacity is lower than the headline figure. On-chip SRAM designs (Groq, Cerebras) are covered in the calculator. Memory figures link to their vendor sources there.

Model architecture used

Parameters405 billion
Layers126
AttentionGrouped-query: 8 KV heads, head dimension 128
KV cache per token516.1 KB (FP16), 258.0 KB (FP8)

Read from the published config.json on 2026-12-02.

Questions about Llama 3.1 405B memory

How much GPU memory does Llama 3.1 405B need for inference?

The weights alone take about 810 GB in FP16, 405 GB in FP8 or INT8, and 228 GB in 4-bit group quantisation. Adding a 10% runtime allowance and the KV cache for one 8,192-token sequence (FP16 cache), the total comes to about 896 GB in FP16, 450 GB in FP8 and 255 GB in 4-bit.

How many H100s do I need to run Llama 3.1 405B?

By capacity alone, at least 12 H100s (80 GB each) for FP16, 6 for FP8 and 4 for 4-bit, at an 8,192-token context and one sequence. Tensor-parallel setups usually use a power of two, which makes the practical counts 16, 8 and 4. This counts memory only; speed depends on bandwidth and interconnect.

Can Llama 3.1 405B run on a single RTX 4090 or RTX 5090?

No. Even 4-bit needs about 255 GB at an 8,192-token context, more than the 24 GB of an RTX 4090 or the 32 GB of an RTX 5090. A longer context or more concurrent requests raises the total. Offloading to system RAM can make a larger model load, but at a large cost in speed.

How much memory does the Llama 3.1 405B KV cache use?

516.1 KB per token with an FP16 cache (258.0 KB with FP8). One 131,072-token sequence therefore takes about 67.6 GB in FP16 (33.8 GB in FP8), and every extra concurrent 8,192-token sequence adds about 4.2 GB.

Things to know

Other models

All model memory requirements ยท Open Llama 3.1 405B in the calculator