Packfile
ELI5 - The Vibe Check
A packfile is git's way of not storing your entire history as a million tiny loose files. Once enough loose objects pile up, git compresses them into one dense archive, storing similar files as small diffs against each other instead of full copies. It's basically a zip file for your commit history, and it's the reason a repo with 50,000 commits doesn't take up 50,000 times the disk space of one commit.
Real Talk
A packfile is a single compressed file that stores multiple git objects together, using delta compression to represent similar objects, such as successive versions of the same file, as diffs against a base object rather than as independent full copies. Packfiles are created by git gc or git repack, dramatically reducing repository size and network transfer time, and are what actually gets sent during a fetch or clone rather than raw loose objects.
When You'll Hear This
"The repo shrank from 2GB to 300MB after repacking into fewer packfiles." / "Clone traffic is mostly packfile transfer, that's why depth matters."
Related Terms
Git Garbage Collection
Git garbage collection is spring cleaning for your repository.
Git Object Model
Under the hood, git doesn't actually store files and folders the way your operating system does.
Partial Clone
A partial clone tells git to grab the commit history and file names, but not bother downloading the actual file contents until they're actually needed.
Shallow Clone
A shallow clone grabs only the most recent slice of commit history instead of the entire multi-year saga, the same way you'd binge the last three episodes...