Handle Large Files With Git LFS

Store big binaries as pointers so the repository stays small.

macOSFilesgitcliLow risk
Run git lfs track "*.psd" to route matching files through LFS.

01Command

Command
$ git lfs track "*.psd"

02What it does

Git LFS replaces large files with small pointer files and stores the content on a separate server, keeping clone and fetch fast. The track command updates .gitattributes so the rule is shared with the team, unlike doing it per-machine in a GUI.

03Risk

RiskLow risk
RequirementsGit 2.20+ (install with Homebrew or Xcode Command Line Tools)
CompatibilitymacOS with Git installed (Homebrew or Xcode Command Line Tools)
!Warning: Everyone who clones the repository needs Git LFS installed, and LFS storage may be metered by the host.

04Undo

✓No undo needed — this command does not change persistent state.

05Sources

  • Git LFS
    Git LFS · vendor-doc · 2026-09-20
    Evidence: Official Git LFS site describing large-file tracking.

Last verified: 2026-10-13 · Category: Developer

06Related solutions