LLM Laboratory

Date: 06.03.2026

Uploading Custom GGUF Models to Hugging Face

This guide explains how to correctly upload custom .gguf models to a repository on Hugging Face using Git LFS.

Large model files (like .gguf) cannot be pushed using normal Git because Hugging Face limits regular files to 10 MB. Instead, they must be stored using Git LFS (Large File Storage).

1. Install Git LFS

Install Git LFS if you don’t already have it.

sudo apt install git-lfs
brew install git-lfs

Download and install from: https://git-lfs.github.com/

git lfs install

2. Create a New Hugging Face Repository

Create a model repository on Hugging Face.

Example repository name:

username/my-gguf-model

Clone the repository:

git clone https://huggingface.co/username/my-gguf-model
cd my-gguf-model

3. Track GGUF Files with Git LFS

git lfs track "*.gguf"
git add .gitattributes
git commit -m "Enable Git LFS for GGUF models"

4. Add Model Files

my-gguf-model/
│
├── README.md
├── model-Q4_K.gguf
├── model-Q8_0.gguf
└── model-bf16.gguf
git add *.gguf
git commit -m "Add GGUF model files"

5. Push to Hugging Face

git push
Uploading LFS objects: 100% (3/3), 12 GB

6. Verify Files

git lfs ls-files
model-Q4_K.gguf
model-Q8_0.gguf
model-bf16.gguf

7. Updating Models Later

git add new-model.gguf
git commit -m "Add new quantization"
git push

Notes

Hugging Face documentation: https://huggingface.co/docs/hub/repositories-getting-started