Can I run Llama 3.1 8B on the GeForce RTX 3060 12GB?
Runs greatQ4_K_M fits in VRAM with 4.8 GB to spare: Runs great, 51.6 tok/s measured at 4k context (1 run; 8k estimate 42.0 tok/s, 37.0–47.1, calibrated estimate ±12%).
12 GB VRAM · 360.0 GB/s · FP16 12.7 TFLOPS. Assumes 32 GB of DDR5-5600 system RAM, Windows with this GPU driving the display, 8k context and an f16 KV cache.
Every quant of Llama 3.1 8B on the GeForce RTX 3060 12GB
| Quant | File size | Verdict | Speed | Memory | Runs as | Notes |
|---|---|---|---|---|---|---|
| Q2_K | 3.18 GB | Runs great | est. 59.2 tok/s52.1–66.4calibrated estimate ±12% | 5.4 / 12.0 GB | Full GPU | — |
| IQ4_XS | 4.45 GB | Runs great | est. 45.6 tok/s40.1–51.1calibrated estimate ±12% | 6.7 / 12.0 GB | Full GPU | — |
| Q4_K_Mbaseline | 4.92 GB | Runs great | 51.6 tok/s8k estimate 42.0 tok/s (37.0–47.1, calibrated estimate ±12%)measured (1 run, 4k context) | 7.2 / 12.0 GB | Full GPU | — |
| Q8_0 | 8.54 GB | Runs great | est. 26.2 tok/s23.1–29.4calibrated estimate ±12% | 10.8 / 12.0 GB | Full GPU | — |
Where the memory goes at Q4_K_M
- Weights
- 4.9 GB
- KV cache
- 1.1 GB
- Compute buffer
- 0.6 GB
- OS reserve
- 0.6 GB
- Free
- 4.8 GB
Context length vs. KV cache
| Context | KV f16 | KV q8_0 | KV q4_0 |
|---|---|---|---|
| 4k | 6.0 GBRuns great est. 46.2 tok/s40.6–51.7calibrated estimate ±12% | 5.7 GBRuns great est. 48.4 tok/s42.6–54.2calibrated estimate ±12% | 5.6 GBRuns great est. 49.7 tok/s43.7–55.6calibrated estimate ±12% |
| 8k | 6.6 GBRuns great 51.6 tok/s8k estimate 42.0 tok/s (37.0–47.1, calibrated estimate ±12%)measured (1 run, 4k context) | 6.1 GBRuns great est. 45.9 tok/s40.4–51.4calibrated estimate ±12% | 5.8 GBRuns great est. 48.2 tok/s42.4–54.0calibrated estimate ±12% |
| 16k | 7.7 GBRuns great est. 35.7 tok/s31.4–39.9calibrated estimate ±12% | 6.7 GBRuns great est. 41.5 tok/s36.5–46.5calibrated estimate ±12% | 6.2 GBRuns great est. 45.6 tok/s40.1–51.0calibrated estimate ±12% |
| 32k | 10.0 GBRuns great est. 27.3 tok/s24.1–30.6calibrated estimate ±12% | 8.0 GBRuns great est. 34.9 tok/s30.7–39.1calibrated estimate ±12% | 6.9 GBRuns great est. 41.0 tok/s36.1–45.9calibrated estimate ±12% |
| 64k | 14.6 GBRuns slowly est. 4.6 tok/s3.7–5.6calibrated estimate ±20% | 10.6 GBRuns great est. 26.5 tok/s23.3–29.7calibrated estimate ±12% | 8.5 GBRuns great est. 34.2 tok/s30.1–38.3calibrated estimate ±12% |
| 128k | 22.1 GBRuns slowly est. 2.0 tok/s1.6–2.4calibrated estimate ±20% | 15.8 GBRuns slowly est. 3.5 tok/s2.8–4.2calibrated estimate ±20% | 11.5 GBRuns well est. 23.1 tok/s18.5–27.8calibrated estimate ±20% |
S = Runs great · A = Runs well · B = Runs slowly · F = Won't run
At Q4_K_M the verdict stays Runs great up to 32k context with an f16 KV cache, and up to 64k with q8_0.
Estimated speed
- Generation
- 51.6 tok/s measured at 4k context (1 run; 8k estimate 42.0 tok/s, 37.0–47.1, calibrated estimate ±12%)
- Prompt processing
- about 1,778 tok/s (1,067–2,489, rough estimate ±40%)
Measured on this exact combination
Public benchmarks we calibrate against. Their conditions (context, backend, flags) can differ from the estimates above.
| Hardware | Quant | Backend | Context | Prompt (tok/s) | Generation (tok/s) | Flags | Source | Measured |
|---|---|---|---|---|---|---|---|---|
| GeForce RTX 3060 12GB | Q4_K_M | llama.cpp | 4k | 1,488.0 | 51.6 | ctx-weighted | localscore.ai | 2026-08-09 |
If this is not enough
A larger model that also runs well on the GeForce RTX 3060 12GB
Runs wellQwen3.5 35B-A3B: Runs well, est. 20.4 tok/s (14.3–26.5, theoretical estimate ±30%)
A larger quant that still runs great
Runs greatQ8_0 (8.54 GB): Runs great, est. 26.2 tok/s (23.1–29.4, calibrated estimate ±12%)
How to run it
Commands for the Q4_K_M file. Both tools download from Hugging Face on first run.
File: Meta-Llama-3.1-8B-Instruct-Q4_K_M.gguf (4.92 GB) from bartowski/Meta-Llama-3.1-8B-Instruct-GGUF.
llama-server -hf bartowski/Meta-Llama-3.1-8B-Instruct-GGUF:Q4_K_M -c 8192 -ngl all -fa on- -ngl all loads every layer on the GPU.
- -fa on enables flash attention (needed for KV cache quantization).
- --cache-type-k q8_0 --cache-type-v q8_0 shrinks the KV cache to 0.57 GB at 8k context.
PowerShell (quit the Ollama tray app first):
$env:OLLAMA_CONTEXT_LENGTH="8192"; ollama serve
ollama run hf.co/bartowski/Meta-Llama-3.1-8B-Instruct-GGUF:Q4_K_M- Ollama defaults to 4k context on GPUs under 24 GB. Set OLLAMA_CONTEXT_LENGTH when starting the server, or /set parameter num_ctx inside the chat.
/set parameter num_ctx 8192
Related pages
Guide: How much VRAM do local LLMs need? 8–32 GB tiers (2026)
Other models on the GeForce RTX 3060 12GB
Llama 3.1 8B on other hardware
Frequently asked questions
Can I run Llama 3.1 8B on the GeForce RTX 3060 12GB?
Q4_K_M fits in VRAM with 4.8 GB to spare: Runs great, 51.6 tok/s measured at 4k context (1 run; 8k estimate 42.0 tok/s, 37.0–47.1, calibrated estimate ±12%). Q4_K_M needs 6.6 GB at 8k context; this setup has 11.4 GB of usable memory and 28.0 GB of free system RAM.
How much context can Llama 3.1 8B use on the GeForce RTX 3060 12GB?
At Q4_K_M the verdict stays Runs great up to 32k context with an f16 KV cache (4.3 GB of KV) and up to 64k with a q8_0 KV cache (4.6 GB). The model supports up to 128k.
Which quant should I use, and how fast is it?
Q4_K_M (4.92 GB) is the recommended balance: Runs great, 51.6 tok/s measured at 4k context (1 run; 8k estimate 42.0 tok/s, 37.0–47.1, calibrated estimate ±12%). The largest tracked file that still gets Runs great is Q8_0 (8.54 GB), est. 26.2 tok/s (23.1–29.4, calibrated estimate ±12%).
Speeds are estimates from memory bandwidth, calibrated against public benchmarks, and each one comes with an error band and a confidence label. Real results vary with drivers, backend, context length and thermals.