MACOS .GITIGNORE
GitHub’s official macOS .gitignore template.
GitHub’s official macOS .gitignore template. It is maintained in GitHub’s public template collection and released under CC0-1.0.
USE
- Copy it to the repository root as
.gitignore. - Merge it with project-specific patterns; later patterns take precedence.
- Commit the result so every contributor uses the same rules.
NOTES
- The template is a starting point; remove patterns you do not need.
- Generated files should usually stay untracked.
SOURCE
https://github.com/github/gitignore/blob/main/Global/macOS.gitignore
FULL TEXT
# General
.DS_Store
.localized
__MACOSX/
.AppleDouble
.LSOverride
Icon[
]
# Resource forks
._*
# Files and directories that might appear in the root of a volume
.DocumentRevisions-V100
.fseventsd
.Spotlight-V100
.TemporaryItems
.Trashes
.VolumeIcon.icns
.com.apple.timemachine.donotpresent
.com.apple.timemachine.supported
.PKInstallSandboxManager
.PKInstallSandboxManager-SystemSoftware
.hotfiles.btree
.vol
.file
.disk_label*
lost+found
.HFS+ Private Directory Data[
]
# Directories potentially created on remote AFP share
.AppleDB
.AppleDesktop
Network Trash Folder
Temporary Items
.apdisk
# Mac OS 6 to 9
Desktop DB
Desktop DF
TheFindByContentFolder
TheVolumeSettingsFolder
.FBCIndex
.FBCSemaphoreFile
.FBCLockFolder
# Quota system
.quota.group
.quota.user
.quota.ops.group
.quota.ops.user
# TimeMachine
Backups.backupdb
.MobileBackups
.MobileBackups.trash
MobileBackups.trash
tmbootpicker.efi
VERIFY SHA-256
Download the file, then choose it here. The checksum is compared locally in your browser.
Expected 840f2930209daaf1d3358c3b934a35c6d5b2dcfe15c56d9b7b469e4448b7e800
CITE
MACOS .GITIGNORE (v1.0, 2026-11-04). Original. https://original.wales/files/gitignore-macos/ SHA-256: 840f2930209daaf1d3358c3b934a35c6d5b2dcfe15c56d9b7b469e4448b7e800. Source: https://github.com/github/gitignore/blob/main/Global/macOS.gitignore.