Git LFS (Large File Storage)
Last Updated: July 29, 2026 | By Mihail Sebastian | AI Dictionary
A Git extension that stores large files like datasets and model weights outside the repository, leaving a small text pointer in their place.
What is Git LFS?
Git LFS (Large File Storage) is a Git extension that stores large files outside the repository and keeps a small text pointer in their place, so the repository stays fast to clone and pull.
Plain Git copies the full history of every file to every collaborator. That works for source code and fails for machine learning, where model weights and datasets run to gigabytes; Git LFS is the standard fix.
How Git LFS Works
You tell LFS which file patterns to track. From then on, each commit records only a pointer file, a few lines of text holding a hash and a size, while the actual content uploads to a separate LFS store.
git lfs install
git lfs track "*.bin"
git add .gitattributes
When someone checks out the repository, Git fetches the real files only for the version they check out, not for the entire history. Everything else about version control stays the same: the large files are committed, branched, and reverted alongside the code.
Example of Git LFS
The Hugging Face Hub runs on this design. Every model on the platform lives in a Git repository where the README, configuration, and tokenizer files are ordinary Git content, and the multi-gigabyte weight files are LFS-tracked.
A team publishing a fine-tuned model pushes everything with one command. Git transfers the small files directly and hands the weights to LFS storage. Anyone browsing the repository sees the full file list instantly and downloads the heavy weights only when they actually load the model. Each weight file stays tied to the exact commit that produced it, which is what makes a shared model reproducible.
Related AI terms: Version Control · Hugging Face · Model Registry · Data Versioning
Did you like the Git LFS (Large File Storage) gist?
Learn about 250+ need-to-know artificial intelligence terms in the AI Dictionary.
Mihail Sebastian — Writes about AI governance, regulation, and the technology behind them. Placeholder bio — replace with a real credential line. About