# Run Qwen3.8 27B locally without the Ollama defaults that make it look bad

Qwen3.8 27B is the default pick for a 16 to 24GB card, and Flash Next runs on smaller cards with lots of RAM. One command gets you started. Three default settings decide whether it is any good.

Updated Nov 17, 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).

*Updated Nov 1, 2026: rewritten for the Qwen3.8 generation (27B dense and Flash Next), with Ollama's current tags, its context defaults, and where the older Qwen3, 3.5 and 3.6 models still fit.*

To run Qwen locally today, start with **Qwen3.8 27B** if you have a 16 to 24GB graphics card, and look at **Qwen3.8 Flash Next** if you have a smaller card but 48 to 64GB of system RAM. On a 24GB card, install [Ollama](https://aliteq.com/ollama) and run `ollama run qwen3.8`, which pulls the 27B at Q4_K_M (18 GB, per Ollama's tag list). On 16GB, use a 3-bit GGUF in [llama.cpp](https://aliteq.com/ollama-vs-llama-cpp-vs-lm-studio-vs-vllm) instead. Then check three things Ollama decides for you: the context length, the quant and the sampling settings. Most "Qwen is bad at coding" complaints come down to one of those.

## The short answer

Pick the Qwen your hardware holds, then fix the defaults. 24GB card: ollama run qwen3.8 (Qwen3.8 27B at Q4_K_M, 18 GB). 16GB card: Qwen3.8 27B at a 3-bit quant in llama.cpp, or gpt-oss-20b. 8 to 12GB card: Qwen3.5 9B (ollama run qwen3.5:9b, 6.6 GB) or Qwen3 14B. Small card with 48 to 64GB of RAM: Qwen3.8 Flash Next with MoE offloading. Ollama's docs say it sets context to 4K on cards under 24 GiB and 32K from 24 to 48 GiB, so raise it for coding and documents, and use Qwen's recommended sampling.

- **24GB:** ollama run qwen3.8, the 27B at Q4_K_M
- **16GB:** Qwen3.8 27B at 3-bit in llama.cpp
- **Small card, big RAM:** Qwen3.8 Flash Next
- **Then:** set context, check the quant, use the card's sampling

## Which Qwen to run

Qwen ships a new generation every few months, and the bare Ollama names now point at different sizes in each family. This is the current map, from the model cards and Ollama's tag lists read on 1 November.

|   | Run | How |
| --- | --- | --- |
| 24GB card (3090, 4090, 7900 XTX) | Qwen3.8 27B, Q4_K_M or Q5 | `ollama run qwen3.8` (18 GB) |
| 16GB card | Qwen3.8 27B at 3-bit | llama.cpp, Unsloth UD-Q3_K_XL (13.15 GB file) |
| 8 to 16GB card + 48 to 64GB RAM | Qwen3.8 Flash Next, 2 to 3-bit | llama.cpp MoE offload or Strata |
| 12GB card | Qwen3 14B or Qwen3.5 9B | `ollama run qwen3:14b` (9.3 GB) |
| 8GB card | Qwen3.5 9B or Qwen3 8B | `ollama run qwen3.5:9b` (6.6 GB) |
| 32GB card (5090) | Qwen3.8 27B at Q6_K with long context | llama.cpp or Ollama |

**Qwen3.8 27B** is a dense 27B model with vision input, 262,144 tokens of native context and an Apache-2.0 licence, per [Qwen's model card](https://huggingface.co/Qwen/Qwen3.8-27B). It is what owners of mid-size cards reach for: in [a r/LocalLLaMA thread ranking every model for 10 to 16GB](https://www.reddit.com/r/LocalLLaMA/comments/1x3gpyi/), the top reply put Qwen 3.8 27B first and said there was no need for a second place, though other replies flagged errors in the original list. Only 16 of its 64 layers keep a growing context cache, so long context is cheap for its size; [its hardware requirements](https://aliteq.com/qwen3-8-27b-hardware-requirements) have the full numbers.

**Qwen3.8 Flash Next** is a mixture-of-experts model with 125B parameters and 6B active per token, plus a 51B n-gram embedding, under a custom "qwen-community-1.0" licence, per [its model card](https://huggingface.co/Qwen/Qwen3.8-Flash-Next). It runs on small cards because the experts can sit in system RAM. What it takes, card by card, is in [our Flash Next setup guide](https://aliteq.com/run-qwen3-8-flash-next-locally), and the hardware options are on [the best GPU for Flash Next](https://aliteq.com/cost-to-run/qwen3.8-flash-next#best-gpu) page.

## Step 1: the one-command start (Ollama)

[Ollama](https://ollama.com/) is the quickest way in. Install it, open a terminal and run the line for your card. Every tag below was on Ollama's library pages on 1 November, with the size Ollama lists:

```bash
ollama run qwen3.8              # Qwen3.8 27B, Q4_K_M, 18 GB, 256K window
ollama run qwen3.8:27b-q8_0     # Qwen3.8 27B, Q8_0, 30 GB
ollama run qwen3.6:35b-a3b      # Qwen3.6 35B-A3B MoE, 23 GB
ollama run qwen3:14b            # Qwen3 14B, 9.3 GB
ollama run qwen3.5:9b           # Qwen3.5 9B, 6.6 GB
```

Name the size. The bare tags pull different things per family: `qwen3.8` is the 27B, `qwen3.6` is the 35B-A3B [MoE](https://aliteq.com/moe-vs-dense-ai-models-explained), `qwen3.5` is the 9B and `qwen3` is the 8B. Ollama's own sizes run a little above our formula, so judge the fit from the tag size plus room for context.

Prefer a window to a terminal? [LM Studio](https://aliteq.com/ollama-vs-lm-studio-which-should-you-use) lists Qwen3.8 and the older Qwen families in its catalogue too.

## Step 2: fix the three defaults

The loudest Qwen complaint of the month was [an r/LocalLLM post from a small software house](https://www.reddit.com/r/LocalLLM/comments/1xjvc08/): an RTX 3090 with 32GB of RAM, Qwen3.8 27B at 128K context, and the verdict "practically unusable for coding". The top reply, with 629 votes, was "I can already tell you're running ollama". The next asked for the quant, the temperature, the harness and the engine settings, and others said the model works well even at Q4 once it is configured. Those replies make a checklist.

**1. Context length.** Ollama's [context-length docs](https://github.com/ollama/ollama/blob/main/docs/context-length.mdx) say it picks a default from your VRAM: 4K tokens under 24 GiB, 32K from 24 to 48 GiB, and 256K at 48 GiB and up. The same page says agents and coding tools should have at least 64,000. A coding agent that sees only part of your files will look stupid. Set it before you judge:

```bash
OLLAMA_CONTEXT_LENGTH=65536 ollama serve
```

Inside `ollama run`, `/set parameter num_ctx 65536` does the same for that session. Then run `ollama ps`: the CONTEXT column shows what was allocated, and PROCESSOR should read 100% GPU. On a 24GB card, Qwen3.8 27B at Q4_K_M with 128K context is about 24.5 GB on our formula with an fp16 cache, over the card, so something will spill. Around 64K is the comfortable ceiling there.

**2. Quant.** The bare `qwen3.8` tag is Q4_K_M. That is fine on 24GB. Do not judge the model at 2 or 3-bit and blame the model; if you have 32GB, try `qwen3.8:27b-q8_0`.

**3. Sampling.** Qwen's card recommends temperature 1.0, top_p 0.95, top_k 20 and min_p 0 in thinking mode (the default), and temperature 0.7, top_p 0.80, top_k 20 with presence_penalty 1.5 when thinking is off. Run `ollama show qwen3.8 --parameters` to see what the tag sets, and override anything that differs with `/set parameter`, or in your app's settings. Greedy decoding (temperature 0) is not what the model was tuned for.

Two more from the same thread: the coding tool (harness) matters as much as the model, and a 27B model does better with small, explicit tasks than with a whole repository.

## Step 3: more control with llama.cpp (and how 16GB runs it)

On a 16GB card, Ollama's 18 GB tag does not fit. llama.cpp lets you pick a smaller file and a compressed cache. Unsloth's [Qwen3.8 27B GGUFs](https://huggingface.co/unsloth/Qwen3.8-27B-GGUF) include UD-Q3_K_XL at 13.15 GB and UD-IQ3_S at 12.04 GB. A starting point:

```bash
llama-server -hf unsloth/Qwen3.8-27B-GGUF:UD-Q3_K_XL \
  -ngl 99 -c 32768 \
  --temp 1.0 --top-p 0.95 --top-k 20 --min-p 0.0
```

`-hf` downloads the file from Hugging Face on first run. For more context on 16GB, a quantized cache (`--cache-type-k` and `--cache-type-v`, for example q8_0) shrinks the cache, and moving your desktop display to the CPU's integrated graphics frees the few hundred megabytes it holds. Our [Qwen3.8 27B requirements](https://aliteq.com/qwen3-8-27b-hardware-requirements) page works through the 16GB numbers and the user reports behind them.

## Where the older Qwens still make sense

- **Qwen3 8B and 14B** still fit 8 to 12GB cards with room to spare (5.2 GB and 9.3 GB in Ollama). Their Ollama tags list a 40K context window.
- **Qwen3.5 9B** is the newer small option at 6.6 GB, with a 256K window per its tag.
- **Qwen3.6 35B-A3B** is the fast one: an MoE with 3B active, 23 GB in Ollama. In [an r/ollama thread](https://www.reddit.com/r/ollama/comments/1xguqao/), a 16GB owner who got 10 to 20 tokens/s from 27B dense on a 4070 Ti Super moved to a 35B-A3B coder fine-tune for agent speed; a reply said they would rather have 20 tokens/s of better output than 120 of worse. See [running Qwen3.6 35B-A3B](https://aliteq.com/run-qwen3-6-35b-a3b-locally).
- **Qwen3.6 27B** has the same layout as Qwen3.8 27B. In [a r/LocalLLaMA beginners' thread about it](https://www.reddit.com/r/LocalLLaMA/comments/1x7sq8e/), one reply simply said to download Qwen 3.8 27B instead. There is little reason to start a new setup on it.
- **Qwen3 Next 80B-A3B** is the bigger MoE for machines with lots of RAM; [running Qwen3 Next 80B-A3B locally](https://aliteq.com/run-qwen3-next-80b-a3b-locally) covers the offload setup.

If the 27B is mainly for code, compare it with the other picks in [the best local LLM for coding on a single GPU](https://aliteq.com/best-local-llm-for-coding-single-gpu). The 16GB route is ranked against every other model in [the best local LLMs for 16GB of VRAM](https://aliteq.com/best-local-llm-16gb-vram), and the 24GB picks are in [the best local LLMs for a 24GB GPU](https://aliteq.com/best-local-llm-24gb-gpu-qwen-gemma-gptoss). Once you have several Qwen sizes downloaded, [managing your Ollama models](https://aliteq.com/how-to-manage-local-ai-models-ollama) keeps the disk under control.

**Want to try Qwen3.8 27B without a 24GB card?** Rent a 24GB card by the hour and try Qwen3.8 27B before you buy one. This link opens Vast.ai with our Ollama and Open WebUI template, so it starts ready to chat; pull qwen3.8, set the context and sampling as above, and shut it down when you're done. [Chat with Qwen on a rented 24GB GPU](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

A 24GB [RTX 3090](https://aliteq.com/gpus/rtx-3090) started at $0.12 an hour on Vast.ai and an [RTX 4090](https://aliteq.com/gpus/rtx-4090) at $0.27 (Nov 17, 2026); every card's live price is on our [cloud GPU page](https://aliteq.com/cloud-gpu). For long context at Q6_K or Q8_0, a 32GB [RTX 5090](https://aliteq.com/gpus/rtx-5090) is the step up.

**Need Qwen at full quality with long context** Want Qwen3.8 27B at Q8_0 with long context, on a managed machine? Runpod rents 32GB cards in its Secure Cloud datacenters with one-click templates, and its serverless option fits an app that calls the model. [Rent a 32GB RTX 5090 on Runpod](https://console.runpod.io/signup?ref=nuninlts) (Referral link: we earn a commission if you buy.) Live RTX 5090 prices on Runpod, from and typical: https://aliteq.com/runpod-pricing

![An AI chat assistant concept](https://media.aliteq.com/media/2026/07/b16-qwen-body.jpg)
Pick the Qwen your memory holds, then set the context, quant and sampling yourself. · Unsplash

![The image that ran at the top of an earlier version of this guide](https://media.aliteq.com/media/2026/07/b16-qwen.jpg)
The image that ran with an earlier version of this guide.

Qwen also makes models that see: [running a local vision model](https://aliteq.com/how-to-run-a-local-vision-model) like Qwen3-VL 8B lets you read text from screenshots and invoices offline, and it scored 96.1 on DocVQA.

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 Qwen model can you run locally? Every size matched to your GPU](https://aliteq.com/qwen-models-run-locally) guide. Related guides: [Qwen3.5 9B is what 'ollama run qwen3.5' actually gives you](https://aliteq.com/run-qwen3-5-9b-locally), [Run Qwen3.8 27B at home with no graphics card? AMD just showed it works](https://aliteq.com/amd-ryzen-ai-max-qwen3-8-27b-no-gpu-needed), [Llama 4 or Qwen3 for local use? Here's the honest comparison](https://aliteq.com/llama-4-vs-qwen3-local).

## Quick answers

**Q: How do I run Qwen locally?**

A: Install Ollama and run ollama run qwen3.8 on a 24GB card; that pulls Qwen3.8 27B at Q4_K_M (18 GB). On smaller cards, run ollama run qwen3.5:9b or qwen3:14b, or use llama.cpp with a 3-bit Qwen3.8 27B file on 16GB. Then raise the context length and use Qwen's recommended sampling.

**Q: Which Qwen should I run on a 16GB GPU?**

A: Qwen3.8 27B at a 3-bit quant, such as Unsloth's UD-Q3_K_XL (13.15 GB), in llama.cpp. Ollama's default qwen3.8 tag is 18 GB and does not fit 16GB. If you want speed over answer quality, Qwen3.6 35B-A3B with some experts offloaded to RAM is the alternative.

**Q: Why is Qwen3.8 27B bad at coding in Ollama?**

A: Usually the defaults. Ollama's docs say it sets 4K context on cards under 24 GiB and 32K on 24 to 48 GiB cards, while coding tools need at least 64K. Also check the quant and that sampling matches Qwen's card (temperature 1.0, top_p 0.95, top_k 20 in thinking mode).

**Q: What does ollama run qwen3.6 download?**

A: The 35B-A3B mixture-of-experts model, 23 GB. Ask for qwen3.6:27b if you want the dense 27B. The bare qwen3.5 tag is the 9B and the bare qwen3 tag is the 8B.

**Q: Can I run Qwen3.8 Flash Next in Ollama?**

A: Ollama lists it, but the smallest GGUF tag is Q4_K_M at 120 GB, which suits 128GB machines. On a small card with 48 to 64GB of RAM, use llama.cpp or Strata with a 2 to 3-bit pack instead.

Start with the model your card holds, fix the three defaults, and only then decide whether you need more hardware. For card choices, see [the best GPU for Qwen3.8 27B](https://aliteq.com/cost-to-run/qwen3.8-27b#best-gpu), and for the dense 27B from the previous generation, [running Qwen3.6 27B locally](https://aliteq.com/run-qwen3-6-27b-locally); for sizing any model, the [VRAM calculator](https://aliteq.com/tools/vram-calculator); and if you are new to all of this, the [beginner's guide to local LLMs](https://aliteq.com/how-to-run-a-local-llm-on-your-pc-beginners-guide).

## Sources

- [Hugging Face (Qwen), Qwen3.8-27B model card, read Nov 1, 2026](https://huggingface.co/Qwen/Qwen3.8-27B)
- [Hugging Face (Qwen), Qwen3.8-Flash-Next model card, read Nov 1, 2026](https://huggingface.co/Qwen/Qwen3.8-Flash-Next)
- [Ollama library, qwen3.8 tags, read Nov 1, 2026](https://ollama.com/library/qwen3.8/tags)
- [Ollama library, qwen3.5 tags, read Nov 1, 2026](https://ollama.com/library/qwen3.5/tags)
- [Ollama library, qwen3.6 tags, read Nov 1, 2026](https://ollama.com/library/qwen3.6/tags)
- [Ollama library, qwen3 tags, read Nov 1, 2026](https://ollama.com/library/qwen3/tags)
- [Ollama docs, context length defaults, read Nov 1, 2026](https://github.com/ollama/ollama/blob/main/docs/context-length.mdx)
- [Hugging Face, unsloth/Qwen3.8-27B-GGUF file sizes, read Nov 1, 2026](https://huggingface.co/unsloth/Qwen3.8-27B-GGUF)
- [r/LocalLLM: Qwen3.8 27B 'practically unusable for coding' and the replies (Oct 30, 2026)](https://www.reddit.com/r/LocalLLM/comments/1xjvc08/)
- [r/LocalLLaMA: every model for 10 to 16GB ranked (Oct 11, 2026)](https://www.reddit.com/r/LocalLLaMA/comments/1x3gpyi/)
- [r/LocalLLaMA: 10 things to do with Qwen3.6 27B (Oct 16, 2026)](https://www.reddit.com/r/LocalLLaMA/comments/1x7sq8e/)
- [r/ollama: 16GB, 27B dense vs a 35B-A3B MoE for agents (Oct 27, 2026)](https://www.reddit.com/r/ollama/comments/1xguqao/)

---

Canonical: https://aliteq.com/how-to-run-qwen3-locally

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