How to Find Duplicate Files on a Mac or Windows PC
Founder and CEO, The Drive AI
TL;DR: Neither macOS nor Windows has a general duplicate file finder. On a Mac, Photos finds duplicate photos and videos, and Finder search can put files with similar names side by side. On Windows, File Explorer can sort by name or size; Storage Sense clears temporary files, not duplicates. To catch copies with different names, compare checksums with
shasum,Get-FileHash, a duplicate finder app or an AI assistant.
Disclosure: The Drive AI publishes this guide and makes one of the tools in it. The built-in methods and third-party apps are described from their makers' own pages, checked in October 2026.
Copies build up the same few ways: an attachment downloaded twice as Invoice.pdf and Invoice (1).pdf, a folder copied to a USB stick and back, an old laptop's files dragged onto the new one "just in case". The hard ones are copies with different names in different folders.
How do you find duplicate files on your computer?
Start with the built-in tools, which find copies with similar names: Finder search on a Mac, File Explorer sorted by name or size on Windows. To catch identical files with different names, compare checksums, which are codes calculated from each file's bytes. A Terminal or PowerShell command, a duplicate finder app or an AI assistant can do that.
If the hash values of two files are identical, the contents are identical too (Microsoft Learn). Names, sizes and dates are only hints.
Does a Mac have a built-in duplicate file finder?
No, not for files in general. As of October 2026 (macOS 27), the only built-in duplicate finder on a Mac is in the Photos app, and it covers photos and videos in your Photos library. For documents, Finder can search by name and kind, which puts likely copies next to each other but doesn't compare contents.
Step 1: Merge duplicate photos in Photos
In Photos, open the Duplicates collection under Utilities in the sidebar. It fills once Photos has analyzed your library. Select the copies and click Merge: one photo or video stays where the copies were. The removed copies go to Recently Deleted, where you can recover them for 30 days (Apple Support).
It only covers the Photos library, not photos saved as files in Downloads.
Step 2: Search Finder for copy markers
In Finder, search for copy or (1), which copies and repeat downloads usually carry. To narrow it, click the Add button below the search field and choose a criterion: Name finds any item whose name contains a word, and Kind limits results to documents, images or another type (Apple Support).
Step 3: Save the search as a Smart Folder
To check again later, choose File > New Smart Folder in Finder, set the same criteria and click Save (Apple Support). It's a saved search that updates as files change.
All three steps compare names, not contents. Acme lease.pdf in Documents and scan_0043.pdf in Downloads can be the same file, and nothing here puts them side by side.
How do you find duplicate files on a Mac with Terminal?
Use shasum, which ships with macOS and prints a checksum for each file. The command below calculates a SHA-256 checksum for every file in your Documents folder, sorts the list, and prints only the files whose checksum appears more than once. It reads files and prints a list. It doesn't change, move or delete anything.
find ~/Documents -type f -exec shasum -a 256 {} + | sort | awk '$1==prev{if(!shown)print line; print; shown=1; next} {prev=$1; line=$0; shown=0}'
Each group of lines starting with the same code is one set of identical files. Change ~/Documents to the folder you want. On a large folder it takes a while, because it reads every byte. shasum uses SHA-1 unless you pass -a 256 (see man shasum).
Does Windows have a built-in duplicate file finder?
No. As of October 2026, Windows 11 and Windows 10 have no tool that finds duplicate files. File Explorer can sort and group files by name or size, which puts likely copies together. Storage Sense, the built-in cleanup, deletes temporary files and old Recycle Bin items, and Downloads files only if you turn that on. It doesn't look for duplicates.
Step 1: Switch File Explorer to Details view
Open the folder in File Explorer, select View, and choose Details (Microsoft Support). Details view shows each file's name, date, type and size in columns.
Step 2: Sort by name, then by size
Click the Name column header: Report.docx, Report (1).docx and Report - Copy.docx end up together. Then click Size. Two files with exactly the same size and a similar name are probably the same file. Right-click an empty area and choose Group by to group by size or type instead.
Step 3: Know what Storage Sense won't do
Storage Sense, under Settings > System > Storage, cleans up temporary files, deletes Recycle Bin content after a while, and, only if you choose, Downloads files you haven't opened in a set time (Microsoft Support). It never compares files, so it won't remove a duplicate. Nor does it sort files into folders; the AI file organizer for Windows guide covers what does.
How do you find duplicate files on Windows with PowerShell?
Use Get-FileHash, which is built into PowerShell and calculates a SHA-256 hash by default (Microsoft Learn). The command below hashes every file in your Documents folder, groups files by hash, and lists only the groups with more than one file. It reads and lists. It doesn't change anything.
Get-ChildItem -Path "$HOME\Documents" -File -Recurse |
Get-FileHash |
Group-Object -Property Hash |
Where-Object Count -gt 1 |
ForEach-Object { $_.Group | Select-Object Hash, Path }
Rows with the same hash are one group of identical files. Replace $HOME\Documents with the folder you want. A file open in another program may print an error and be skipped.
Which apps find duplicate files on a Mac or PC?
Dedicated apps do the same work in a window. Three, as their own pages describe them in October 2026:
| App | Runs on | Matches by | What it does with copies |
|---|---|---|---|
| The Drive AI desktop app | Mac, Windows (Max or Team plan) | Contents, by SHA-256 checksum on the device | Shows one plan to approve, then moves them to the Trash or Recycle Bin |
| dupeGuru | Windows, macOS, Linux | File names (with fuzzy matching) or contents; similar pictures | Delete, move or copy them |
| Gemini 2 by MacPaw | Mac | Duplicates and similar files | Moves them to the Trash by default |
| CCleaner Duplicate Finder | Windows | Any of name, size, modified date and content | Lets you delete them |
Only matching by content proves two files are identical, so turn that option on where an app offers it. And check whether the app sends files to the Trash or deletes them for good.
Can AI find and delete duplicate files on your computer?
Yes. The Drive AI's desktop app for Mac and Windows does it in a folder you share, without uploading the folder. Setup is on the local folders page.
Step 1: Share the folder
In the desktop app, open Settings › Agent › Share a folder and pick one, such as Downloads.
Step 2: Ask for the duplicates
Find duplicate files in Downloads and keep the oldest copy of each.
- Checksums are calculated on your computer. The app computes a SHA-256 checksum for each file on the device, and only the checksums leave it. Files not yet hashed are hashed in the background when you ask.
- Identical files are grouped. Each group shows its extra copies and the space removing them would free, largest first.
- Look-alikes are shown separately. Same type, same folder, sizes a few bytes apart, such as a re-downloaded PDF. They are listed to compare and never removed automatically.
- You choose the keep rule. Oldest, newest, the copy in the shallowest folder, or alphabetical. You can also ask for the groups as a spreadsheet first.
Step 3: Approve the plan
The cleanup is one plan with a count and a sample, and nothing moves until you approve it. Extra copies go to the Trash or Recycle Bin, or to a folder you name. Moves undo in the app; trashed files are restored from the Trash.
The limits. Duplicates are matched within one source: a file on your laptop isn't matched against its copy in Google Drive or Dropbox, because each platform fingerprints files differently. The computer must be on with the app running. Sharing folders from a computer comes with the Max plan or any Team plan. Duplicate file detection across cloud drives and NAS shares, and whether AI can organize files on your computer, are covered separately.
Which copy should you keep, and how do you remove the rest safely?
Keep the copy in the folder where people expect to find it, and failing that, the oldest. Move the rest to the Trash, the Recycle Bin or a review folder rather than deleting them for good, and wait a few weeks before emptying it.
- Oldest is usually the original. For identical files, "newest" means only the date changed.
- The copy outside Downloads and the Desktop is usually the one you meant to keep. Those two folders are where copies breed, and they are also why it's hard to find files on your computer in the first place.
- Check synced folders. Removing a file from an iCloud Drive, OneDrive or Dropbox folder removes it everywhere it syncs.
- Leave app libraries alone. Use the app's own tool, such as Merge in Photos, rather than deleting files inside a library by hand.
Know your recovery window. On a Mac, the Trash keeps items until you empty it, and File > Put Back restores them, unless Remove items from the Trash after 30 days is on in Finder settings (Apple Support). On Windows, Storage Sense deletes Recycle Bin content after a while by default, so restore anything you need soon. Photos keeps merged copies in Recently Deleted for 30 days.
The same rules apply in the cloud: see how to find duplicate files in Google Drive.
Frequently Asked Questions
Does Windows 11 have a duplicate file finder?
No. Windows 11 has no built-in duplicate file finder. File Explorer can sort or group a folder by name and size to put likely copies together, and Storage Sense removes temporary files, not duplicates. To find identical files, use PowerShell's Get-FileHash, a duplicate finder app such as dupeGuru or CCleaner, or an AI assistant.
Does macOS have a duplicate file finder?
Only for photos and videos. The Photos app has a Duplicates collection under Utilities, and Merge keeps one copy. For other files, Finder search and Smart Folders can find files with similar names, but nothing built in compares contents. Terminal's shasum command, a duplicate finder app or an AI assistant can.
How can I tell if two files are exactly the same?
Compare their checksums. On a Mac, run shasum -a 256 on both files in Terminal. On Windows, run Get-FileHash on both in PowerShell. If the two codes match, the files are byte-for-byte identical, even if their names, folders and dates differ. Matching names or sizes alone don't prove it.
Is it safe to delete duplicate files?
Usually, if the copies are truly identical and you keep one. Confirm with a checksum, not a name. Leave files inside app libraries and system folders alone, remember that deleting in a synced folder deletes in the cloud too, and move copies to the Trash or a review folder before deleting anything permanently.
Can AI delete duplicate files on my computer for me?
Yes, with your approval. The Drive AI's desktop app checksums files in a folder you share, on your computer, groups the identical ones and shows one plan of what it would remove. Nothing moves until you approve, and the extra copies go to the Trash or Recycle Bin. It needs the Max plan or any Team plan.
Clear the biggest groups first: most of the space sits in a few large files copied many times. To do it as one request, share the folder from the desktop app and ask The Drive AI with this, or paste it into Claude or ChatGPT with our connector added: Find duplicate files in my Downloads folder. Keep the oldest copy of each and move the rest to the Trash, but show me what you would remove first.
Share it with your network
