Skip to content
AI Dev Toolkit.
Esc
  • Loading…

AI glossary · Local AI

What is a GGUF file?

Also called: GGUF file, .gguf, GGUF format

Definition

GGUF is a single-file binary format from the ggml and llama.cpp project that stores a model’s weights together with everything needed to run them, such as its architecture, tokenizer and quantisation type.

Explained

How does a GGUF file work?

Because everything sits in one file, local runners such as Ollama, LM Studio and llama.cpp can load and memory-map it in one step. Our comparison of Ollama, LM Studio and llama.cpp shows how each one uses it.

GGUF replaced the project’s earlier GGML, GGMF and GGJT formats. A file starts with the magic bytes GGUF and a version number (currently 3), then metadata as key-value pairs (architecture, context length, tokenizer and so on), then a description of every tensor, then the tensor data itself. The layout can be memory-mapped, so models load quickly.

Models are usually trained in PyTorch and published as safetensors files. llama.cpp’s convert_hf_to_gguf.py turns them into a 16-bit GGUF, and llama-quantize makes the smaller quantised versions from it.

The file name ends with the encoding, so Qwen3-14B-Q4_K_M.gguf is Qwen3 14B at Q4_K_M. Very large models are split into shards named like -00001-of-00003.gguf. llama.cpp reads GGUF directly, LM Studio runs GGUF models with llama.cpp, and Ollama imports a GGUF file through a Modelfile with a FROM line.

Example

Qwen’s official GGUF files for Qwen3 14B

Qwen publishes Qwen3 14B as GGUF files at several quantisations, one file per level. We read their sizes from the Hugging Face API and compared them with our VRAM calculator’s weight estimate: every one is within 0.3%. The file is only the weights. Running it with an 8K context adds the KV cache and working space for the runtime.

Qwen3 14B GGUF files: size on disk and memory to run
FileFile sizeOur weight estimateTotal at 8K context
Qwen3-14B-Q4_K_M.gguf8.4 GB8.4 GB10.7 GB
Qwen3-14B-Q5_K_M.gguf9.8 GB9.8 GB12.2 GB
Qwen3-14B-Q6_K.gguf11.3 GB11.3 GB13.8 GB
Qwen3-14B-Q8_0.gguf14.6 GB14.6 GB17.5 GB

File sizes from the Hugging Face API (Qwen/Qwen3-14B-GGUF), 2026-10-11. Estimates: parameters × llama.cpp’s bits per weight; totals add an FP16 KV cache and overhead, batch 1. Model config fetched 2026-10-08. GB = 1,024³ bytes.

Cost and quality

Why does GGUF matter for running models locally?

GGUF is what most local tools download, and its name tells you the memory you need before you download it: the quantisation sets the file size, and the context you want adds the rest. Check the total against your VRAM.

One self-contained file also moves easily between tools: the same GGUF runs in llama.cpp and LM Studio, and Ollama can import it.

Don’t mix up

GGUF vs safetensors vs GGML: what’s the difference?

GGUF vs safetensors
Safetensors is the Hugging Face weights format that training frameworks save to, with the config and tokenizer in separate files. GGUF bundles all of it in one file, usually quantised, for runtimes built on ggml.
GGUF vs GGML
ggml is the tensor library that llama.cpp is built on. GGML was also the name of its older file format, which GGUF replaced, so a file described as a “GGML model” is the old format, not the library.

FAQ

Questions people ask

What does GGUF stand for?

The format’s own specification in the ggml repository never spells the letters out; it describes GGUF only as a file format for storing models for inference with ggml and runtimes built on it. Other sources expand the name in different ways, so treat any expansion as unofficial. What matters in practice is that GGUF is the successor to the older GGML, GGMF and GGJT formats.

Are GGUF models better than other formats?

Not better, just suited to a different job. GGUF packs quantised weights and the metadata needed to run them into one file that loads fast on CPUs, Apple Silicon and consumer GPUs. Safetensors usually holds full-precision weights for training or for GPU servers. A GGUF at Q4_K_M trades a little accuracy for a much smaller memory footprint.

How do I use a GGUF file?

Load it in a runner built on ggml. With llama.cpp you pass the file to llama-cli or llama-server with -m; LM Studio opens GGUF models from its model browser; in Ollama you write a Modelfile with FROM /path/to/file.gguf and run ollama create. Check the quantisation suffix first so the file fits your memory, using the VRAM calculator.

What is the difference between GGUF and vLLM?

They are different kinds of thing. GGUF is a file format for model weights; vLLM is a GPU inference server that normally loads Hugging Face checkpoints. vLLM can load GGUF files, but its own docs call that support highly experimental and under-optimised. In practice GGUF belongs to llama.cpp-based tools for local, single-user inference, while vLLM targets high-throughput serving.

Go deeper

Try it and read more

Related

All 41 terms in the AI glossary

Written by Tahir Nazir. Checked .

How this was checked: On 2026-10-11 we read the GGUF specification (version 3, file structure and naming convention), the llama.cpp quantize README for the conversion commands, Ollama’s import docs and LM Studio’s docs, and measured the Qwen3 14B GGUF file sizes with the Hugging Face API. On 2026-10-16 we re-read the specification (no expansion of the name; memory-mapping as a design goal), Ollama’s import syntax and vLLM’s GGUF page. Memory figures come from our VRAM calculator (model config fetched 2026-10-08).

Keep exploring