How to Find Duplicate Files on Mac

If you’ve been using your Mac for some time now, chances are high that you have accumulated duplicate files without realizing it. Duplicates on Mac are usually identical files of any format, such as documents, music, or images.

 

While Mac systems offer a good amount of storage, these files slowly take up space on your device, eventually slowing down its performance. So, you need to be smart about dealing with duplicates to avoid experiencing storage limitations on your Mac.

 

This article explains how to find duplicate files on a Mac and how to remove them. Let's dive in!

Before we start:

 

Keeping your MacBook free of duplicate files is easy with MacKeeper's Duplicates Finder, which quickly and easily scans your Mac to remove unnecessary duplicate files.

 

Here’s how to use it:

  1. In MacKeeper, select Duplicates Finder from the sidebar
  2. Click Start Scan, and wait for it to finish
  3. Select what files you want to delete, and click Remove Selected.

Why does Mac duplicate files?

Your Mac may duplicate files for different reasons. For example, you could download the same file more than once. Similarly, you may have installed the same apps multiple times without realizing it.

 

Other common reasons for duplicates on your Mac include:

  • You have identical libraries and playlists on different devices, which allows copies of files to be stored on your Mac
  • Deliberately creating several copies of a document or a photo and forgetting to delete the other ones
  • Importing photos or music from external devices, like smartphones, can sometimes create duplicates
  • Some applications create duplicate files or system backups within their data folders
  • Automated backup or synchronization processes, like Time Machine, can duplicate files across devices or storage locations.

Duplicate files are a huge inconvenience, especially if you’re trying to keep your MacBook organized. That’s why you should find and delete duplicates regularly to free up disk space on your Mac.

 

To learn more about your files, ensure you get a file path on Mac and establish its folder and disk information. This will also make it easier to delete a file manually if you no longer need it.

Does Mac have a Duplicate File Finder

macOS does not have a dedicated duplicate file finder that automatically checks and removes duplicates from your device. However, there are many ways to search for duplicate files on Mac, such as relying on Smart Folders in the Finder.

 

Smart Folders helps you easily locate identical files on your device. The tool lets you define criteria for items to be included in the folder, making it easier to keep track of files on your Mac.

 

Besides Smart Folders, you can also use your MacBook's Quick Look feature to preview files without opening them. This helps you decide whether the files are worth keeping or should be deleted from your Mac.

How to search for duplicate files on Mac

Once your hard drive is loaded with duplicates, your macOS risks becoming excruciatingly slow for regular tasks. The best way to free up disk space on a Mac is to identify these files and get rid of them.

 

Here are some proven methods to search for and identify duplicate files on Mac:

  1. Find duplicate files with Smart Folder in Finder
  2. Identify duplicate files with Terminal
  3. Search duplicates in the Photos Library

1. Find duplicate files with Smart Folder in Finder

Finder's Smart Folders feature is one of the most straightforward ways to locate duplicate files on your system. Though time-consuming, relying on Smart Folders will help you find duplicates by file size or type without using any third-party tool.

 

Here’s how to find duplicates with Smart Folders in Finder:

  1. Open Finder on your Mac.
  2. Click File in the upper-left menu.
  3. Select New Smart Folder in the drop-down menu.
  4. Proceed to the + button and click it.
  5. You can now decide on criteria to locate duplicate files, whether photos, music, or videos.
Here’s how to start finding duplicate files on Mac. The Finder app and the File drop-down menu open on Mac to give you an opportunity to create a new folder.
Step 1. Open Finder > Click File in the upper-left menu > Select New Smart Folder
Next, create and use New Smart Folders in Finder to locate duplicate files on Mac. See how the New Smart Folder with the search bar looks.
Step 2. Press the ‘+’ button and decide on the criteria to locate duplicate files

Using Smart Folders can be a helpful method for locating duplicates on your Mac based on file attributes. You can rely on the method if you want to:

1.1 Catch out duplicates in specific folders

You can use Smart folders to set specific criteria based on file attributes such as name, extension, creation date, modification date, and more. This makes it easier to find duplicates among files with the same criteria that Smart Folders gather in one place.

 

Follow these steps to set up a Smart Folder that searches a specific folder:

  1. Go to Finder > File > New Smart Folder and type the specific folder in the search bar.
  2. Click ‘+’ in the top-right corner to set the parameters for the files you want in the specific folders. This could be a name, kind, date created, etc.
  3. Now, open each file with the same name, kind, or those created on the same date in the specific Smart Folder and check whether their data is duplicated.
To open a New Smart Folder in Finder on Mac, go to Finder > File > The News Smart Folder. The new window will show the available applications on your Mac.
Step 1. Open Finder > File > New Smart Folder
Now, when you open a New Smart Folder in Finder, set search criteria to identify duplicate files. With their help, you can filter duplicate applications on your Apple device.
Step 2. Click the ‘+’ icon to set the search criteria

Hint from our team: 

 

From this point on, you can open and organize your files by name, size, or date created to help you see those that are duplicated. Delete duplicates and drag them to your Trash.

1.2 Find duplicates by file size

Smart Folders will help you identify duplicate files on Mac based on size for easy filtering and subsequent deletion. To get started, create a New Smart Folder and follow these steps to locate duplicates by file size:

  1. In the search bar, type the folder name where you want to locate duplicates.
  2. Click ‘+,’ then hit the ‘Name’ drop-down menu, and scroll down to Other, where you can set the search criteria as file size.
  3. Set it to the ‘Physical file size in bytes’ that matches the range or exact size of the file you want to delete. Click OK.
  4. After grouping the files by size range, review them to identify duplicates and delete them.      
A New Smart Folder displays where you can locate files based on their size. For example, here’s a Screenshot folder within the New Smart Folder on a MacBook.
Step 1. New Smart Folder > Search bar > Screenshots
In the New Smart Folder, set search criteria to sort out the available screenshots on your Mac: per name, contents, kind, etc. Choose the one you need from the drop-down menu.
Step 2. Click ‘+’ in the upper right corner > Hit the ‘Name’ drop-down menu > Others
Now select the file size attribute in the New Smart Folder under the Others’option. Confirm the action by clicking OK when it's done.
Step 3. Click on Others > File size > Select the file size option > OK

The New Smart Folder will contain all files within the specified or exact size range. You can open this folder, manually scroll through it to identify duplicates, and move them to the trash.

1.3 Look for duplicates by file types

In the same way that it helps you locate duplicates by file size, Smart Folders can also be very useful for finding duplicates of specific file types. Do the following:

  1. Create a New Smart Folder first—see how above.
  2. Set specific criteria to filter duplicates or identical files based on their file type or extension. For example, you can specify the criteria for duplicate JPEG image files as .jpg or .docx for Microsoft Word documents.
See how to set the file size duplicate as a search criterion in the New Smart Folder. In this case, the available JPEG file images are selected on Mac.

Despite being quite useful in locating duplicates based on file attributes, using Smart Folders requires much manual effort. Because of this, it's a decent option—but only if you have extra time to clear duplicate files on your Mac individually.

2. Identify duplicate files with Terminal

For tech-savvy Mac users, one method for finding and eliminating duplicates is to use terminal commands. In this method, duplicates are listed by Terminal, but you will still need to find and get rid of them manually.

 

Using Terminal as a command-line interface to identify duplicate files on a Mac is quicker as long as you know the basic commands and functions. To do it:

  1. Open Finder and go to Applications.
  2. Click on Utilities and select Terminal to open it.
  3. Go to the folder you want to scan using the cd command. For example, if you're going to scan Downloads, type in cd ~/Documents and hit ENTER.
  4. Copy and paste the command: find ./ -type f -exec md5 {} \; | awk -F '=' '{print $2 "\t" $1}' | sort | tee duplicates. Txt
To identify duplicate files with Terminal, first access  Finder > Applications.
Step 1. Open Finder > Applications
Next step is to find the Terminal app within the list of Utilities on your Mac. Now, you can use it to show duplicate files on your computer.
Step 2. Go to Utilities > Terminal
While in the app, enter the necessary Terminal command: the cd ~/Documents. Press Enter to identify duplicate files on Mac.
Step 3. Terminal > Type cd~/Documents > Enter
Copy and type in the following command in the Terminal window: find ./ -type f -exec md5 {} \; | awk -F '=' '{print $2
Step 4. Type in the command shown on the screenshot

Hint from us: 

 

This terminal command creates a text file in the folder you’ve specified with all the duplicates inside. Open a Finder window and navigate to the folder. From here, you can open the duplicates.txt file and proceed to sort and delete them manually.

 

We should also note that some duplicates, especially those with different file names, may not be flagged as such.

Can you rely on Terminal commands to identify duplicates?

The good thing about using Terminal to identify duplicates is that every file has a unique identifier, otherwise known as an MD5 hash. This identifier doesn’t change, even if you move files on Mac to a different folder or rename them.

 

So, you can still generate a list that displays MD5 tags using the Terminal command described below to verify all duplicates within a specific folder.

 

Here’s how to create the MD5 tags list:

  1. Open Terminal.
  2. If you want to scan the Downloads Folder, type into the Terminal window: cd~/Downloads.
  3. Copy and paste this code: find ./ -type f -exec md5 {} \; | awk -F '=' '{print $2 "\t" $1}' | sort | tee duplicates.txt and hit ENTER.
  4. Proceed to open the Finder > Downloads.
  5. Open the Dupicates.txt file.
A Terminal command displays MD5 tags, which discloses the available duplicates in the Downloads folder on a Mac.
Step 1. Open Terminal > Type ~/Downloads > Copy and paste the command > Enter
The downloads folder displays all the files that have been recently downloaded on the device.
Step 2. Open Finder > Downloads

You’ll see a list of all the files in the specified folder with the md5 tags, making it easier to tell which files are duplicates. Overall, identifying duplicates with Terminal is quicker than the Smart Folders option.

 

However, there are a few things to keep in mind:

  • Only use Terminal if you understand how Terminal commands work.
  • Terminal command tends to overlook most duplicates.
  • While it’s quicker, you still have to locate those duplicates and sort them from the original copies.

3. Search duplicate photos in the Photos Library

Mac has a Photos app to help you identify duplicate photos in the photo library. These photos are stored in a designated ‘Duplicates’ album, where you can merge or remove them to clean up your library.

3.1 Using the built-in duplicate search tool on Ventura or Sonoma macOS

The built-in duplicate search tool to identify and remove duplicate photos on Mac works for newer macOS versions such as Ventura and Sonoma.

 

Here’s how to use the duplicate search tool:

  1. Open the Photos app on your Mac and click Duplicates in the sidebar.
  2. Allow for it to scan and find duplicates.
  3. If there are any, click Merge [x] Similar Items.
  4. Go to the Recently Deleted album to find and delete the duplicate copies.
To find duplicate photos from the Duplicates folder in the Photos app, click Duplicates and allow for a scan on your MacBook.

How to find duplicate files on an external hard drive on a Mac

External hard drives on Macs serve different purposes. You can use them for backup purposes, such as Time Machine backups, to back up files on your Mac that weren't part of the macOS installation.

 

You can also use an external hard drive to transfer music, photos, and documents from your MacBook to another. However, as useful as external hard drives may be, frequently using them leads to the eventual accumulation of duplicate files.

 

Therefore, I always recommend regularly finding duplicate files on these drives and getting rid of them. The best way to find and delete duplicates on an external hard drive on a Mac is to do it manually.

 

On your Mac, open the external hard drive and drag the duplicate items to the Bin in the Dock. Alternatively, select the duplicate items, then press Command-Delete.

 

Or, you can use MacKeeper to automate this process through the custom scan option by following the steps below:

  1. Open MacKeeper.
  2. Click on Duplicate Finder > Custom Scan in the bottom right corner.
  3. Add an external folder to scan and click Start Scan.
The MacKeeper app shows the feature of the Duplicates Finder, including the custom scan option, for you to automatically find and then delete the redundant image copies on your Mac
Step 1. Open MacKeeper > Duplicates Finder > Custom Scan
As an additional help, you can scan an external folder with the MacKeeper's Duplicates Finder feature.
Step 2. Click to add the external folder > Scan

How to remove duplicate files on Mac

Duplicates consume a lot of valuable space. If left unchecked over time, they fill up your hard drive with unnecessary copies to back up data and other documents, leading to a huge waste of drive space.

 

Here are three ways to remove duplicate files on Mac:

  1. Remove duplicate files using Mac Terminal
  2. Delete them manually using Finder
  3. Use third-party software

1. Remove duplicate files using Mac Terminal

Terminal is one of the best ways to remove duplicates from your MacBook. By keying in a Terminal command, you'll find an extensive list of duplicates on your MacBook, which you can filter and manually delete.

 

The following steps will help you identify and remove duplicates on Mac using Terminal:

  1. Go to Application > Utilities to open Terminal.
  2. Type in the command depending on the folder of choice:
    • For downloads, type: cd ~/Downloads
    • For documents, type: cd ~/Documents
  3. Hit Enter and  then follow through up by entering the following command in Terminal: find ./ -type f -exec md5 {} \; | awk -F '=' '{print $2 "\t" $1}' | sort | tee duplicates.txt
  4. A .txt file in your destination folder will show all the duplicates in the directory, if there are any.

View the hash codes in the left-hand column to see which files are true duplicates. Then, manually delete them. Empty your Trash afterward to ensure they don't consume any disk space.

2. Delete them manually using Finder

Here, you'll use Finder to search for duplicate files and then manually delete them. While this may not be ideal if you plan on deleting a ton of duplicates, it's effective in clearing your MacBook of duplicates and recovering valuable disk space.

 

Here are the steps to follow:

  1. Open Finder.
  2. Type asterisk * within the search field to search for all files on your drive.
  3. You can then search through the list to find duplicate files and remove them.
To manually delete duplicate files in Finder, type the asterisk* in the search field and see the results. Choose the selected items and move them to Trash.

3. Using third-party software

If the methods described above don't prove effective, the easiest solution you have is to use third-party software dedicated to finding and removing duplicates on your Mac. For example, MacKeeper’s Duplicates Finder finds and deletes similar-looking copies without affecting the original copies.

 

One of the key advantages of using our tool is that your original files stay safe while you enjoy more disk space for the much-needed files. MacKeeper will always notify you if you accidentally select the original file.

  1. Download MacKeeper and launch the Duplicates Finder.
  2. Click on Start scan.
  3. Remove all the duplicates.
The MacKeeper app shows the Duplicates Finder feature, which is ready to scan for duplicate files on the device.
Step 1. Open MacKeeper and launch the Duplicates Finder
Our Duplicates Finder is waiting to start the scanning process. Just click on Start Scan.
Step 2. Launch a scan on your device
See the scan results of MacKeeper's Duplicates Finder, pick the duplicate files you don't need anymore, and click on Remove Selected.
Step 3: Remove the selected duplicates

Conclusion

Deleting duplicates on your Mac will help you recover the much needed disk space for the files you really need. As described above, the most useful methods you can use to find and remove duplicate files on your Mac are:

  • Find duplicate files with Smart Folder in Finder
  • Use Terminal Command
  • Search duplicates in the Photos Library

From our experience, the fastest way to locate duplicates was by typing the ‘*’ within the search bar in Finder. The only faster and more efficient way is to use MacKeeper’s Duplicates Finder, which offers advanced features that automate the detection and removal of duplicate files without affecting the original files.

Use your Mac to the fullest! Sign up and get:
Effective tips on how to fix Mac issues
Reliable advice on how to stay safe online
Mac-world news and updates

Thank you!

You’ll love exploring your Mac with us.

Oops, something went wrong.

Try again or reload a page.

Here’s another sign you need to upgrade your macOS ASAP:

30% off your MacKeeper subscription

Сopy the code now and use it in the MacKeeper checkout after the upgrade.

Copy Code

Please be aware that this code cannot be combined with any other discounts, offers, or promotions.

Contents

Unlocked
PC

MacKeeper - your all-in-one solution for more space and maximum security.

Try Now

Read more

Unified Memory
Unified Memory
How to Change Startup Programs on Mac
How to Change Startup Programs on Mac
arrow

Run Application

step_1

Click Continue

step_2

Click Install

step_1

Your macOS version is lower than OS 10.11. We’d like to offer you MacKeeper 4 to solve the cleaning, privacy, and security issues of your macOS.