Best open-source LLMs to run locally

The open model families most worth running at home are Qwen3 for an all-rounder in every size, Llama for Meta's widely supported models, Mistral Small for a 24B model with image input, Phi-4 for a compact MIT-licensed model, and Qwen3-Coder or Devstral for code.

By Anjam JavedUpdated How we choose

How we chose

These are open-weight model families with official Hugging Face pages, published sizes and clear licenses, chosen to cover different sizes and uses. We have not run our own quality tests; descriptions of what a model is good at are the makers’ own. Memory figures are our estimates at Q4_K_M with an 8,192-token context.

The families at a glance

Family Sizes covered Context License Memory at Q4_K_M, 8K
Qwen3 4B, 8B, 14B, 32B 32K (131K with YaRN) Apache 2.0 3.7 to 22.2 GB
Llama 3.1 / 3.3 8B, 70B 128K Llama Community License 6.0 GB / 45.5 GB
Mistral Small 3.1 24B 128K Apache 2.0 16.0 GB
Phi-4 14B 16K MIT 10.2 GB
Qwen3-Coder 30B-A3B 262K Apache 2.0 about 18.7 GB weights alone
Devstral Small 2 24B 256K Apache 2.0 about 14.7 GB weights alone

Full architecture details for the general models are in our LLM model sizes table.

Qwen3: an all-rounder in every size

Qwen3 covers 4B to 32B parameters under one Apache 2.0 license, so the same family works on an 8 GB card and on a 24 GB card. The model cards list a 32,768-token native context, extendable to 131,072 tokens with YaRN.

Llama: Meta’s models

Llama 3.1 8B fits an 8 GB card at Q4_K_M, and Llama 3.3 70B needs about 45 GB, which means two cards or a large unified-memory computer. Both list a 128K context. Meta releases them under custom commercial licenses, so read the terms before commercial use.

Mistral Small 3.1: 24B with image input

A 24B model that accepts images as well as text, with a 128K context and an Apache 2.0 license. Mistral says it runs on a single RTX 4090 or a 32 GB Mac once quantized.

Phi-4: compact and MIT-licensed

Microsoft’s 14B model is the only one here under the MIT license. Its context is shorter, at 16K tokens.

For coding: Qwen3-Coder and Devstral

Both are built for code. Qwen3-Coder 30B-A3B lists a 262K context. Devstral Small 2 is designed for software-engineering agents. See the best local LLMs for coding for details.

Choose by your hardware

Our best local LLMs guide matches these models to 8, 12, 16 and 24 GB of GPU memory. To check a model and context exactly, use the LLM VRAM calculator.

Sources

Questions

Are these models really open source?

Their weights are free to download, but the licenses differ. Qwen3, Mistral Small, Devstral and Qwen3-Coder use Apache 2.0 and Phi-4 uses MIT, both standard open-source licenses. Llama uses Meta's own community licenses, which Meta describes as custom commercial licenses with their own terms. People often call all of them open-weight models.

Can I use these models commercially?

Apache 2.0 and MIT allow commercial use. The Llama community licenses are custom commercial licenses with their own terms. Read the license on each model's page before you build a product on it.

Which family should I start with?

Qwen3, because it comes in 4B, 8B, 14B and 32B sizes under one license, so you can pick the size that fits your memory and move up later.

Anjam JavedAnjam Javed has used PCs for 20 years, upgrades his own laptops and runs AI tools on local hardware. He holds master's degrees in IT and Marketing Management.More from the author