Llama 3.1 405B: how much VRAM?
In Q4_K_M with 8k tokens of context, Llama 3.1 405B needs about 259 GB of memory. The cheapest option: Mac Studio M3 Ultra 512 GB (€11,500 for the complete machine).
Model sheet
ollama run llama3.1:405bWeights on Hugging Face: meta-llama/Llama-3.1-405B-Instruct
VRAM by precision and context
| Precision | 4k | 8k | 32k | 128k |
|---|---|---|---|---|
| FP16 | 853 GB | 855 GB | 867 GB | 914 GB |
| FP8 | 428 GB | 430 GB | 441 GB | 488 GB |
| Q8_0 | 453 GB | 455 GB | 467 GB | 514 GB |
| Q6_K | 351 GB | 353 GB | 365 GB | 412 GB |
| Q4_K_M | 258 GB | 259 GB | 271 GB | 318 GB |
| Q3_K_M | 211 GB | 213 GB | 224 GB | 271 GB |
One user. Each simultaneous user adds their own context cache.
Frequently asked questions
How much VRAM does Llama 3.1 405B need?
With an 8k-token context and one user, Llama 3.1 405B needs about 259 GB in Q4, 455 GB in Q8 and 855 GB in FP16.
What is the cheapest hardware to run Llama 3.1 405B?
In Q4, the cheapest option in our catalogue to run Llama 3.1 405B is Mac Studio M3 Ultra 512 GB, about €11,500 for the complete machine.
How fast does Llama 3.1 405B run?
Expect around 1.9 tokens per second for one user on Mac Studio M3 Ultra 512 GB in Q4 (estimate based on memory bandwidth).
On which hardware?
| Hardware | Cards | Speed | Machine |
|---|---|---|---|
| Mac Studio M3 Ultra 512 GB | 1 is enough | ~1.9 tok/s | €11,500 |
| RTX PRO 6000 Blackwell 96 GB | 3 cards | ~9.1 tok/s | €29,800 |
| A100 80 GB | 4 cards | ~14 tok/s | €50,000 |
| L40S 48 GB | 6 cards | ~8.8 tok/s | €51,000 |
| H200 141 GB | 2 cards | ~16 tok/s | €72,000 |
| B200 192 GB | 2 cards | ~27 tok/s | €90,000 |
| H100 80 GB | 4 cards | ~23 tok/s | €118,000 |
| RTX 3060 12 GB | doesn’t fit | — | — |
| RTX 4060 Ti 16 GB | doesn’t fit | — | — |
| Radeon RX 7800 XT 16 GB | doesn’t fit | — | — |
| RTX 4070 12 GB | doesn’t fit | — | — |
| RTX 3090 24 GB (used) | doesn’t fit | — | — |
| RTX 4070 Ti SUPER 16 GB | doesn’t fit | — | — |
| Radeon RX 7900 XTX 24 GB | doesn’t fit | — | — |
| RTX 4080 SUPER 16 GB | doesn’t fit | — | — |
| RTX 5080 16 GB | doesn’t fit | — | — |
| RTX 4090 24 GB | doesn’t fit | — | — |
| Mini-PC Ryzen AI Max+ 395 128 GB | doesn’t fit | — | — |
| RTX 5090 32 GB | doesn’t fit | — | — |
| NVIDIA DGX Spark 128 GB | doesn’t fit | — | — |
| Mac Studio M4 Max 128 GB | doesn’t fit | — | — |
| RTX 6000 Ada 48 GB | doesn’t fit | — | — |
Estimated complete machine: cards + host PC (€900 for 1–2 consumer cards, €2,800 beyond, a €6,000 server for datacenter cards). Macs and mini-PCs are sold complete.
Similar models
From: RTX 3060 12 GB · €1,180
From: Mini-PC Ryzen AI Max+ 395 128 GB · €2,300
From: Mac Studio M3 Ultra 512 GB · €11,500