LFS storage size is bigger than the repository actual size after LFS migration

Platform Notice: Cloud Only - This article only applies to Atlassian products on the cloud platform.

Summary

When migrating a repository to Git LFS, the LFS storage size can be much larger than the original repository size due to the difference between how Git and Git LFS handle the files.

Cause

Git is a distributed version control system that stores data as snapshots of a filesystem. It uses references to other objects (commits, trees, blobs) to represent changes and optimize storage space by compressing objects.

Git LFS, on the other hand, is an extension to Git that replaces large files in a repository with tiny pointer files while storing the actual file contents on a separate server (LFS storage). These files are not compressed, and each version of a binary file is stored independently. This will lead to larger storage usage than storing binary files directly in the repository, especially if multiple versions of large files are preserved in the commit history.

Updated on April 8, 2025

Still need help?

The Atlassian Community is here for you.