# Can you run gpt-oss-20b on your GPU? Yes with 16 GB of VRAM, and slower on 8 GB

gpt-oss-20b fits fully on any 16 GB graphics card: 14.9 GB at 8K context and 15.5 GB at 32K, per the llama.cpp guide. An 8 GB or 12 GB card still runs it with some layers in system RAM. What your GPU, RAM and Mac need, how fast each card is, and the Ollama setting that quietly cuts your context. Checked Nov 3, 2026.

Updated Nov 30, 2026 · By Ari Vale

This page has referral links: we earn a commission if you buy, at no cost to you.

Our Vast referral code: 623346 (link: https://cloud.vast.ai/?ref_id=623346). New users get no bonus from it; we earn 3% of what referred users spend (Vast's referral program docs: https://docs.vast.ai/guides/reference/referral-program?ref_id=623346).

**Yes, you can run gpt-oss-20b on your GPU if it has 16 GB of VRAM.** OpenAI says the model runs "within 16GB of memory", and the llama.cpp guide measures 14.9 GB at an 8K-token context and 15.5 GB at 32K, so any 16 GB card holds the whole model. With an 8 GB or 12 GB card it still runs, more slowly, by keeping some expert layers in system RAM. On a Mac you need at least 16 GB of unified memory. Checked November 3, 2026 on OpenAI's model card, the llama.cpp guide, Ollama and LM Studio.

## The short answer (checked Nov 3, 2026)

gpt-oss-20b runs fully on any GPU with 16 GB of VRAM. OpenAI's model card says MXFP4 (4-bit) weights make it run within 16 GB of memory, and the llama.cpp guide lists 14.9 GB at 8K context, 15.5 GB at 32K and 17.9 GB at the full 128K. So 16 GB covers normal use and 24 GB covers the whole context window. 8 GB and 12 GB cards run it with llama.cpp's --n-cpu-moe setting, which keeps part of the model in system RAM; a community result in the guide shows about 42 tokens a second on an 8 GB RTX 4060 Laptop GPU. Macs need at least 16 GB, and 8 GB Macs can't run it. The easiest install is Ollama (ollama pull gpt-oss:20b, a 14 GB download) or LM Studio.

- **16 GB VRAM:** fits fully, up to about 32K context (llama.cpp guide)
- **24 GB VRAM:** fits the full 128K context (17.9 GB)
- **8 to 12 GB VRAM:** runs with some layers on the CPU, slower
- **Mac:** 16 GB unified memory minimum; 8 GB Macs are out
- **Ollama gotcha:** on cards under 24 GB it defaults to a 4K context; raise it

- **14.9 GB** VRAM needed (llama.cpp guide, 8K context)
- **17.9 GB** At 128K tokens (llama.cpp guide, full context)
- **14 GB** Download size (Ollama, gpt-oss:20b)
- **3.6B of 21B** Active parameters (OpenAI model card)

## Can my GPU run gpt-oss-20b?

Find your VRAM in the table. You can see it in Windows Task Manager under Performance, GPU, "Dedicated GPU memory", or in `nvidia-smi` on an NVIDIA card. Memory figures are from the llama.cpp guide's minimum-requirements table; the guide's maintainer notes they "could vary a little bit" with settings.

### gpt-oss-20b by VRAM (llama.cpp guide, read Nov 3, 2026)

|   | Runs it? | What to expect |
| --- | --- | --- |
| 24 GB or more (RTX 3090, 4090, 5090) | Yes, fully on the GPU | Room for the full 128K context (17.9 GB) |
| 16 GB (RTX 5060 Ti 16 GB, 4060 Ti 16 GB, 4080, 5070 Ti, 5080) | Yes, fully on the GPU | Comfortable up to about 32K context (15.5 GB) |
| 12 GB (RTX 3060 12 GB, 4070) | Yes, with some layers on the CPU | Slower; needs spare system RAM |
| 8 GB (RTX 2060 SUPER, 3070, 4060) | Yes, with more layers on the CPU | Slower again; the guide gives exact settings |
| Mac, 16 GB unified memory | Yes, with some layers on the CPU | macOS doesn't give the GPU all 16 GB |
| Mac, 8 GB | No | Not enough memory, per the guide |

![Screenshot of OpenAI's gpt-oss-20b model card on Hugging Face, with the MXFP4 quantization line outlined: the models were post-trained with MXFP4 quantization of the MoE weights, making gpt-oss-120b run on a single 80GB GPU and the gpt-oss-20b model run within 16GB of memory](https://media.aliteq.com/media/ai/gpt-oss/gptoss-hf-16gb-2026-11-03.jpg)
OpenAI's own sizing on the gpt-oss-20b model card, huggingface.co/openai/gpt-oss-20b, read November 3, 2026. · Screenshot of huggingface.co by aliteq

Why does a 21-billion-parameter model fit in 16 GB? OpenAI trained its mixture-of-experts weights in MXFP4, a 4-bit format (see [what quantization is](https://aliteq.com/what-is-quantization-llm-explained)), and only 3.6B of the 21B parameters work on each token. The whole model still has to sit in memory, though: the guide counts 12.0 GB of model data plus 2.7 GB of compute buffers before any context.

To check a different card or context length, put it in our [VRAM calculator](https://aliteq.com/tools/vram-calculator).

## How much VRAM does gpt-oss-20b need at long context?

**15.5 GB at 32K tokens and 17.9 GB at the full 128K.** The model itself stays the same size; what grows is the KV cache, the memory that holds your conversation (our [context window explainer](https://aliteq.com/what-is-a-context-window) shows how). The guide puts it at about 0.2 GB per 8,192 tokens for this model, which is small, so the jump from 8K to 128K is only about 3 GB.

![Screenshot of the llama.cpp guide's minimum requirements table: gpt-oss 20B, 12.0 GB model data, 2.7 GB compute buffers, 0.2 GB KV cache per 8,192 tokens, 14.9 GB total at 8,192 tokens, 15.5 GB at 32,768 and 17.9 GB at 131,072](https://media.aliteq.com/media/ai/gpt-oss/gptoss-llamacpp-memory-2026-11-03.jpg)
The llama.cpp guide's memory table, github.com/ggml-org/llama.cpp/discussions/15396, read November 3, 2026. · Screenshot of github.com by aliteq

That's why the guide's own 16 GB example (an NVIDIA [V100](https://aliteq.com/tesla-v100-local-ai-worth-it)) caps context at 32K: the card is "just at the edge to fit the full context". In practice:

- **Chat, coding help, short documents:** 16 GB is plenty (other models that fit are in [the best local LLMs for 16GB](https://aliteq.com/best-local-llm-16gb-vram)).
- **Whole books, long agent sessions, big codebases in one prompt:** [24 GB](https://aliteq.com/best-local-llm-24gb-gpu-qwen-gemma-gptoss), so the full 128K fits without offloading.

## How fast is gpt-oss-20b on my GPU?

These are text-generation speeds (llama-bench `tg128`) from the benchmark runs posted in the llama.cpp guide, with the whole model on the GPU. They were run in 2025 on the guide's own builds, so treat them as a ranking, not a promise for your PC.

### gpt-oss-20b speed by card (llama.cpp guide, read Nov 3, 2026)

|   | VRAM | Tokens per second |
| --- | --- | --- |
| RTX 5090 | 32 GB | about 282 |
| RTX 4090 | 24 GB | about 225 |
| RTX 5080 | 16 GB | about 205 |
| RTX 5070 Ti | 16 GB | about 189 |
| RTX 4080 SUPER | 16 GB | about 186 |
| RTX 3090 | 24 GB | about 162 |
| RTX 5060 Ti 16 GB | 16 GB | about 112 |
| AMD RX 7900 XT (ROCm) | 20 GB | about 102 |
| Mac M4 Max (36 GB) | unified | about 92 |
| Mac M1 Pro (32 GB) | unified | about 46 |

Even the slowest entry writes faster than most people read. Of the 16 GB cards here, the [RTX 5060 Ti 16 GB](https://aliteq.com/gpus/rtx-5060-ti-16gb) is the slowest at about 112 tokens a second, and a used [RTX 3090](https://aliteq.com/gpus/rtx-3090) adds the 24 GB for the full context. If you're choosing a card to buy for it, our [best GPU for gpt-oss-20b](https://aliteq.com/cost-to-run/gpt-oss-20b#best-gpu) page ranks the cards that fit with live rental prices.

**No 16 GB card? Try gpt-oss-20b on a rented one first** Rent a 24 GB RTX 3090 for an hour, pull gpt-oss:20b and run your own prompts at the full 128K context. This link opens Vast.ai with Ollama and Open WebUI ready to use; pick a verified host. [Rent a 24 GB RTX 3090 for an hour](https://cloud.vast.ai/?template_id=26e7446a7d6906ee366b620c84e1e422&ref_id=623346) (Referral link: we earn a commission if you buy.) Live RTX 3090 prices on Vast.ai, from and typical: https://aliteq.com/vast-ai-pricing

## Can gpt-oss-20b run on an 8 GB or 12 GB GPU?

**Yes, with some of the model in system RAM.** llama.cpp's `--n-cpu-moe` setting moves expert layers to the CPU while attention and the context stay on the GPU. The guide's example is an RTX 2060 with 8 GB: 16 MoE layers on the CPU for a 32K context, or 22 for the full context.

![Screenshot of the llama.cpp guide's section for devices with less than 16GB VRAM, outlined: it is recommended to tell llama.cpp to run the entire model on the GPU while keeping enough layers on the CPU, with an RTX 2060 8GB example: full context with 22 layers on the CPU, or 32k context with 16 layers on the CPU](https://media.aliteq.com/media/ai/gpt-oss/gptoss20b-llamacpp-under-16gb-2026-11-03.jpg)
The llama.cpp guide's settings for cards under 16 GB, github.com/ggml-org/llama.cpp/discussions/15396, read November 3, 2026. · Screenshot of github.com by aliteq

How slow is it? One reader posted results in the guide's comments on November 10, 2025: an RTX 4060 Laptop GPU with 8 GB, a Core i7-14700HX and 64 GB of DDR5, running 14 MoE layers on the CPU, got about 42 tokens a second. That's their machine and their settings, not ours, but it shows 8 GB is usable. A [12 GB card](https://aliteq.com/best-local-llm-12gb-vram) needs fewer layers on the CPU, so it lands between that and the full-GPU numbers above.

What else you need for offloading:

- **System RAM** to hold the layers the GPU doesn't. LM Studio lists 12 GB as the minimum system memory for this model; the 42 tokens/sec laptop above had 64 GB.
- **The right number for `--n-cpu-moe`.** Too low and the GPU runs out of VRAM; too high and it gets slower than it needs to be. [What --n-cpu-moe actually does](https://aliteq.com/n-cpu-moe-llama-cpp-what-it-actually-does) explains how to find it, and the step-by-step 8 GB and 12 GB setup is in [gpt-oss-20b on an 8 GB or 12 GB GPU](https://aliteq.com/gpt-oss-20b-8gb-12gb-gpu-moe-offload).

One Windows trap the guide warns about: the driver can let a program allocate more VRAM than the card has, then quietly swap to RAM and crawl. "Just because the model loads without errors, it doesn't mean you have enough VRAM for the settings that you are using", the guide says. Watch "GPU Memory" in Task Manager and keep it under your card's VRAM.

## Can I run gpt-oss-20b on a Mac?

**Yes, with 16 GB of unified memory or more.** The guide says the model "can run efficiently on Macs with at least 16GB RAM", with two limits. On a 16 GB Mac, "Macs don't allow to utilize the full 16GB memory by the GPU", so you keep some layers on the CPU (the guide's example uses `--n-cpu-moe 12` with a 32K context). On an 8 GB Mac, in the guide's words, "you are out of luck". Bigger Macs are quick: about 92 tokens a second on an M4 Max with 36 GB. The 16 GB Mac mini setup is covered in [gpt-oss-20b on a 16 GB Mac mini](https://aliteq.com/gpt-oss-20b-mac-mini-16gb-m4-m6), and Mac buying advice in [best Mac for local AI](https://aliteq.com/best-mac-for-local-ai).

## How do I run gpt-oss-20b?

The easiest way is one of the two apps OpenAI's model card points to (compare them in [Ollama vs LM Studio](https://aliteq.com/ollama-vs-lm-studio-which-should-you-use)):

- **Ollama:** `ollama pull gpt-oss:20b`, then `ollama run gpt-oss:20b`. The download is 14 GB.
- **LM Studio:** `lms get openai/gpt-oss-20b`, or search "gpt-oss-20b" in the app.
- **llama.cpp:** `llama-server -hf ggml-org/gpt-oss-20b-GGUF --ctx-size 0 --jinja -ub 2048 -b 2048` downloads the model and starts a local chat page and API. `--ctx-size 0` means the full context, so on a 16 GB card set `--ctx-size 32768` as the guide does.

### The Ollama setting that cuts your context

Ollama picks a default context length from your VRAM, and on any card under 24 GB that default is only 4K tokens. A 16 GB card can handle about 32K, so raise it: use the context slider in the Ollama app's settings, or start the server with `OLLAMA_CONTEXT_LENGTH=32768 ollama serve`. Ollama's docs say coding tools and agents should get "at least 64000 tokens", which on gpt-oss-20b means 24 GB to stay fully on the GPU. Check what you got with `ollama ps`: the PROCESSOR column should say 100% GPU.

![Screenshot of Ollama's Context length documentation, with the first default outlined: Ollama defaults to context lengths based on VRAM, under 24 GiB VRAM 4k context, 24 to 48 GiB 32k context, 48 GiB or more 256k context](https://media.aliteq.com/media/ai/gpt-oss/gptoss20b-ollama-default-context-2026-11-03.jpg)
Ollama's default context by VRAM, docs.ollama.com/context-length, read November 3, 2026. · Screenshot of docs.ollama.com by aliteq

## Should I rent a GPU for gpt-oss-20b instead?

**Rent if you just want to try it or you only have 8 GB; buy if you'll use it every day.** On Vast.ai, Nov 17, 2026 (our price tracker, checked Nov 17, 2026), single-GPU on-demand rentals started at about $0.12/hr for an RTX 3090 and $0.27/hr for an RTX 4090; Runpod listed the RTX 4090 at $0.89/hr. On November 3 an RTX 5060 Ti 16 GB was from about $0.11/hr on Vast. These are the cheapest offers at that moment and they change hourly, so check [today's cloud GPU prices](https://aliteq.com/cloud-gpu) or the per-model page at [/cost-to-run/gpt-oss-20b](https://aliteq.com/cost-to-run/gpt-oss-20b) before you rent. If you're on the fence about owning a card at all, [rent vs buy a GPU for AI](https://aliteq.com/rent-vs-buy-gpu-ai-cloud-vs-local) does the break-even, and [the cheapest RTX 4090 rental](https://aliteq.com/cheapest-rtx-4090-rental) compares that card across providers.

**Want the full 128K context without buying a 24 GB card?** Want gpt-oss-20b behind an app or an API? A 24 GB RTX 4090 runs it fully on the GPU at the full 128K context, about 225 tokens a second in the llama.cpp guide. Runpod's one-click templates start it in a Secure Cloud datacenter, and serverless suits an app; stop the pod when you're finished. [Rent a 24 GB RTX 4090 by the hour](https://console.runpod.io/signup?ref=nuninlts) (Referral link: we earn a commission if you buy.) Live RTX 4090 prices on Runpod, from and typical: https://aliteq.com/runpod-pricing

On a rented card the Ollama steps above barely change. Runpod's own [Ollama tutorial](https://docs.runpod.io/tutorials/pods/run-ollama?ref=nuninlts) has you deploy a pod from its PyTorch template, add port 11434 under Expose HTTP Ports, set the environment variable `OLLAMA_HOST` to `0.0.0.0`, then install Ollama from the web terminal and run a model. The official one is the [Runpod Pytorch 2.8.0 template](https://console.runpod.io/hub/template/runpod-torch-v280?ref=nuninlts), with JupyterLab, SSH, a 30 GB container disk and a 50 GB volume disk (read Nov 30, 2026), room enough for the 14 GB gpt-oss:20b download. Then `ollama run gpt-oss:20b` and raise the context as above, because a 24 GB card still gets Ollama's 32K default unless you set it.

## What this page can't tell you

- **Your exact speed.** The speeds come from benchmark runs posted in the llama.cpp guide in 2025 and a reader's laptop result, not from our own tests. Ollama, LM Studio, newer llama.cpp builds and longer contexts all change the number.
- **Every card.** The guide covers mostly NVIDIA and Apple hardware. AMD cards run gpt-oss through ROCm or Vulkan; the guide says "Depending on your specific hardware, the results can vary", but the memory numbers are the same. On Intel, it needs a 16GB Arc card to sit fully on the GPU, as [our guide to what fits each Intel Arc card](https://aliteq.com/intel-arc-gpu-local-llm-what-fits) shows.
- **The bigger model.** gpt-oss-120b needs about 64 GB; see [gpt-oss-120b hardware requirements](https://aliteq.com/gpt-oss-120b-hardware-requirements). To weigh gpt-oss against other open models, see [gpt-oss vs Qwen3 vs DeepSeek](https://aliteq.com/gpt-oss-vs-qwen3-vs-deepseek).

**Can you run gpt-oss-20b?.** If your GPU has 16 GB of VRAM, yes, fully and fast, at up to about 32K context. With 24 GB you get the full 128K. With 8 or 12 GB it still runs with some layers in system RAM, at roughly 40 tokens a second on an 8 GB laptop card in one reader's test. Macs need 16 GB or more. Install it with Ollama or LM Studio, and raise Ollama's 4K default context. Anyone checking whether their PC or Mac can run OpenAI's gpt-oss-20b

gpt-oss ships its weights in MXFP4; [what MXFP4 is and which GPUs run it natively](https://aliteq.com/what-is-mxfp4) explains why the files are so small.

This guide is part of our [Which local AI model fits my GPU's VRAM? The 8GB to 32GB chart, model by model](https://aliteq.com/best-local-llm-vram-tiers-what-actually-fits) guide and our [Which Gemma, Llama, Mistral or gpt-oss model can you run on an 8 to 24GB GPU?](https://aliteq.com/gemma-llama-mistral-gpt-oss-local) guide. Related guides: [how to run Mistral locally — the lean European open model, on your own PC](https://aliteq.com/how-to-run-mistral-locally), [How much VRAM does Mistral Small 24B need, and how fast does it run?](https://aliteq.com/run-mistral-small-24b-locally), [Best GPU for a Local AI Coding Assistant (Oct 2026)](https://aliteq.com/best-gpu-for-ai-coding-locally).

## Common questions

**Q: How much VRAM do I need to run gpt-oss-20b?**

A: 16 GB to run it fully on the GPU. The llama.cpp guide measures 14.9 GB at 8K context, 15.5 GB at 32K and 17.9 GB at the full 128K. OpenAI's model card says it runs within 16 GB of memory.

**Q: Can gpt-oss-20b run on an 8 GB GPU?**

A: Yes, slower. llama.cpp's --n-cpu-moe setting keeps some expert layers in system RAM; the guide's RTX 2060 8 GB example uses 16 layers on the CPU for a 32K context. A reader reported about 42 tokens a second on an 8 GB RTX 4060 Laptop GPU with 64 GB of RAM.

**Q: Can a 12 GB card like the RTX 3060 run gpt-oss-20b?**

A: Yes, the same way as an 8 GB card but with fewer layers on the CPU, so it runs faster than the 8 GB setups. It won't fit fully on the GPU, which needs about 15 GB.

**Q: Is 16 GB enough, or do I need 24 GB?**

A: 16 GB is enough for normal chats and coding help at up to about 32K tokens of context. Get 24 GB only if you want the full 128K context fully on the GPU.

**Q: How big is the gpt-oss-20b download?**

A: 14 GB in Ollama (gpt-oss:20b), with a 128K context window.

**Q: Why does Ollama run gpt-oss-20b with a short context?**

A: Ollama sets the default context from your VRAM, and any card under 24 GB gets 4K tokens. Raise it in the app's settings or with OLLAMA_CONTEXT_LENGTH, and check ollama ps to confirm it still runs 100% on the GPU.

**Q: Can I run gpt-oss-20b on a Mac?**

A: Yes, on a Mac with 16 GB of unified memory or more. 16 GB Macs need some layers on the CPU because macOS doesn't give the GPU all of it; 8 GB Macs can't run it, per the llama.cpp guide.

**Q: Is gpt-oss-20b free to use commercially?**

A: Yes. OpenAI released it under the Apache 2.0 license, which allows commercial use.

## Sources

- [OpenAI, gpt-oss-20b model card on Hugging Face (vendor page, read Nov 3, 2026): runs within 16GB of memory, 21B parameters with 3.6B active, Apache 2.0, Ollama and LM Studio commands](https://huggingface.co/openai/gpt-oss-20b)
- [llama.cpp, guide: running gpt-oss with llama.cpp, by maintainer Georgi Gerganov (posted Aug 18, 2025, a live document, read Nov 3, 2026): memory table, per-GPU and per-Mac benchmarks, --n-cpu-moe examples, Windows VRAM warning, community RTX 4060 Laptop result](https://github.com/ggml-org/llama.cpp/discussions/15396)
- [Ollama, gpt-oss tags: gpt-oss:20b 14GB, 128K context window (read Nov 3, 2026)](https://ollama.com/library/gpt-oss/tags)
- [Ollama docs, Context length: default context by VRAM, under 24 GiB = 4k (read Nov 3, 2026)](https://docs.ollama.com/context-length)
- [LM Studio, openai/gpt-oss-20b model page: minimum system memory 12 GB, 131k context (read Nov 3, 2026)](https://lmstudio.ai/models/openai/gpt-oss-20b)
- [Runpod docs, Set up Ollama on a Pod (deploy with the latest PyTorch template, expose HTTP port 11434, set OLLAMA_HOST to 0.0.0.0, install Ollama from the web terminal; read Nov 30, 2026)](https://docs.runpod.io/tutorials/pods/run-ollama?ref=nuninlts)
- [Runpod Hub, Runpod Pytorch 2.8.0 official template (ID runpod-torch-v280; JupyterLab on port 8888, SSH on 22; 50 GB volume disk, 30 GB container disk; updated Nov 29, 2026, read Nov 30, 2026)](https://console.runpod.io/hub/template/runpod-torch-v280?ref=nuninlts)

---

Canonical: https://aliteq.com/can-you-run-gpt-oss-20b-locally

This page has referral links: we earn a commission if you buy, at no cost to you.
