How to find and remove duplicate files on a Mac
- For pictures in Photos, use its Duplicates album. For everything else, compare contents, not names. macOS has no duplicate finder for ordinary files, but a Finder search narrows the list, and one Terminal command proves which files are identical.
- Keep the copy you’d look for first, usually not the one in Downloads or the one named “copy”, and move the rest to the Trash so you can still change your mind.
- What it frees can be less than it looks: copies Finder made on the same disk often share their space. Duplicates you remove don’t come back once the Trash is emptied.
1. Photos: the Duplicates album
Photos finds duplicates in its own library by itself:
- Open Photos and click Duplicates under Utilities in the sidebar. It only appears once Photos has found some, which can take a while after an import. If you use a Shared Library, choose Both Libraries from the Library menu in the toolbar first.
- Look through the rows. Apple doesn’t say which copy Photos keeps, so check before you merge if it matters to you.
- Select the rows to merge, or press ⌘A for all, and click Merge … Items.
- One copy stays where the duplicates were. The others go to Recently Deleted for 30 days; empty it to get the space back.
This covers the Photos library only. Pictures saved in your own folders need the methods below, and the library itself should never be searched or cleaned from Finder or Terminal: here’s why.
2. Finder: narrow down the candidates
Finder can’t compare what’s inside files, but it can find likely pairs:
- Copies by name. Finder names a copy “report copy.pdf”, and downloading a file twice often adds a number, as in “report (1).pdf”. Press ⌘F, click your home folder at the top, set the first rule to Name contains and type
copy. Then check each match against the original. - Same size, side by side. Open a folder such as Downloads in List view and click the Size column. Files of exactly the same size, next to each other, are worth a closer look. The same size isn’t proof, but different sizes rule a pair out.
- Big ones first. A search with File Size is greater than 100 MB, sorted by size, puts the duplicates worth removing at the top. How to search by size.
Select two files and press Space to compare them in Quick Look before you decide.
3. Terminal: prove they’re identical
Two files with the same checksum have the same contents, whatever their names or dates say. To compare two files:
shasum -a 256 ~/Downloads/report.pdf ~/Documents/report.pdf
To find every group of identical files over 10 MB in a few folders at once, use the command below. It reads each file in full, so big folders take a while, and it only lists, never deletes:
find ~/Documents ~/Downloads ~/Desktop -type f -size +10M -exec shasum -a 256 {} + | sort | awk '$1 == h { if (first != "") print first; print; first = ""; next } { h = $1; first = $0 }'
Lines in the same group start with the same long checksum. Change +10M to +1M to include smaller files. Point it only at folders of your own files: given ~/Pictures or ~/Music, it would also list files inside the Photos library and the Music app’s folders, which belong to those apps.
4. Which copy to keep
- Keep the one where you’d look for it: in your project folder or Documents, rather than Downloads or the Desktop.
- Keep the original name, not the one ending in “copy” or a number. The oldest copy is usually the original.
- Keep files other apps point to. A clip in an iMovie or Final Cut Pro project, a song in your Music library or a photo in a Lightroom catalog is used from where it sits. Delete that copy and the app loses track of it, even though another copy exists.
- A copy on another drive is a backup, not a duplicate. It costs your Mac nothing, so leave it.
- Mind iCloud Drive and other synced folders. Deleting a file there deletes it on your other devices too.
5. Why some duplicates free no space
Mac startup disks use APFS, where a copy Finder makes on the same disk is usually a clone. Apple describes a clone as a copy that takes no extra space: both files share the same data on disk until one of them changes, and only the changes are stored separately. Delete a clone, and you get back only what differed, which may be nothing.
Copies that arrived separately, such as a file downloaded twice, saved again from an email, or copied over from another drive, don’t share anything, so removing one frees its full size. Finder and du can’t tell you which kind you have, so check the free space before and after you empty the Trash:
df -h /System/Volumes/Data
Questions
Does a Mac have a built-in duplicate file finder?
Not for files in general. Photos finds duplicates in its library (Utilities › Duplicates), and the Music app lists duplicate songs under File › Library › Show Duplicate Items. For other files, use the Finder and Terminal steps above, or an app.
Is it safe to delete duplicate files?
Yes, once you’ve confirmed the files are identical and no app uses the copy you’re removing. Move them to the Trash rather than deleting them outright, use your Mac for a few days, then empty it.
Why do I have so many duplicates?
The usual ways: downloading the same attachment twice, importing photos into both Photos and a folder, copying a project to keep an old version, and syncing the same files with two cloud services.
Will removing duplicates speed up my Mac?
No. It gives you space back, nothing more. A Mac with very little free space can struggle, so the space itself can help, but the duplicates weren’t slowing anything down.
How SiftMac handles it. Its Duplicates category compares files over 1 MB in Desktop, Documents, Downloads, Movies, Music and Pictures by size, then their first and last 64 KB, then a SHA-256 of the whole file, so only identical files are listed. It skips the Photos library, code projects and iCloud files that aren’t downloaded, keeps the best copy (not the one in Downloads or named like a copy, otherwise the oldest), and marks each extra Safe, sized by what removing it really frees, clones included. None is picked until you tick it, and before moving extras to the Undo Shelf for 7 days it checks the kept copy is still there.
Download SiftMac · scanning is free, and so is your first 2 GB of cleaning · See how it works