How to remove empty folders in Windows 10

Madalina Dinita
by Madalina Dinita
Managing Editor
Download PDF
Affiliate Disclosure

remove empty folders

All of us have empty folders left over uninstalling programs or after simple modifications. While these folders do not take much memory, they greatly affect the way your computer is organized.

That does not mean that we must search through thousands of folders to find the ones that are completely empty because it would take forever to find all of them.

There are some simple and easy to implement methods that you can use to delete empty folders instead.

Solutions to delete empty folders in Windows 10

  1. Search for empty folders
  2. Use Command Prompt
  3. Use the Remove Empty Directories software
  4. Use a Registry Cleaner
  5. Make sure you have all the necessary permissions

Can’t delete folders in Windows 10? Now you can with our step-by-step guide!

1. Search for empty folders

The first method does not require any software to be installed, but rather is based on a search based on size. It is very easy to do it because it performs like any other search on the system level.

The only difference is a zero byte filter for storage memory. This is how you do it.

  1. Open My Computer.
  2. Click on the Search Tab to open the Search Menu.1
  3. From the Search Menu set the Size filter to Empty and be sure that the All subfolder feature is checked.2
  4. After the search ends, it will display all files and folders that do not take up any memory space. Select the ones you want to delete, right click on one of them and click on Delete

2. Use Command Prompt

This method is a little more difficult to implement but if you follow these steps thoroughly you will be able to do it.

  1. Open a Command Prompt window by searching the words Command Prompt. This will open the console.
  2. Write down this structure DIR /AD/B/S | SORT /R > EMPTIES.BAT. Now the EMPTIES.BAT file contains a list with all your folders in reverse order (sorted by the memory used).
  3. Open the file with Word or any other editor.
  4. Word has a Find and Replace feature. Search the structure ^p and replace with ^pRD  (quote, caret, R, D, space, quote). RD comes from “remove directory” and it is a preset action for delete.
  5. Save the EMPTIES.BAT file and exit from your editor.
  6. Run the file and it will try to delete all the folders that are on that list, but it will fail for the folders with content.

This is how it works:

For the DIR command, function /AD selects all the files that have director attribution, in other words, the files that are folders. The /B function gives a list with only the file name and the /S function tells the computer to also check the subfolders.

To introduce the SORT command you must enter the “|” symbol. /R function tells the computer to sort the folders in reverse order. The symbol > tells the computer to redirect the output of SORT function in the EMPTIES.BAT file.

Because the sort is in reverse, every subfolder of every folder will be deleted when the parent folder is processed.

This method is a little more complicated compared to the search method, but it is also much more effective because you have access to all the folders in your computer.

Work in Command Prompt like a real technician with our complete guide!

3. Use the Remove Empty Directories software

Remove Empty Directories is free software designed to search and delete empty folders. It has a different filter for the folder selection and you can personalize your search very fast.

You can download the setup from here. The installation is very easy.

  1. Click on the installer.
  2. Click on the Next button.
  3. Check the I accept the agreement box and click on Next button.
  4. Select where you want to install the software and click on the Next button.
  5. Here setup informs you that it will create a shortcut in the start menu. If you do not want to create the shortcut, check the Do not create a Start Menu folder. Click on the Next button.
  6. This is an additional task where you can create a desktop shortcut for this software. If you want to create the shortcut, check the Create a desktop icon box.
  7. The installer will show a table with all the set-ups you established. If everything is alright, start the installation by clicking on the Install button.
  8. The installation should not take too long. Click on Finish button to end the installation.

The software is not difficult to use. This is a short presentation and the steps you need to follow to search and delete empty folders.

On the top menu there have three tabs: Scan, Settings and About. The Scan menu is for the search and delete process of the empty folders.


The Settings menu is for the customization of the search and the access.


The About menu is where you can find different information about this software.


Here is how you delete your empty folders:

  1. After you customize your settings, click the Scan button from the Scan tab.
  2. The folders with red names will be deleted. Make sure that by deleting those folders you don’t affect your system negatively.
  3. Click on the Delete folders button and the empty files will be deleted.
  4. Exit the software to end the process.

4. Use a Registry Cleaner

Registry cleaners can help you delete redundant items from your computer’s registry and this includes empty folders as well.

So, if you haven’t installed a Registry cleaner on your machine, check out this list of the best Registry cleaners to use on Windows 10 and select the one that best suits your needs.

Download, install and run the tool and then check if the empty folders are gone.

5. Make sure you have all the necessary permissions

Sometimes, you may not be able to delete certain folders because you don’t have the necessary permissions. If you didn’t create the respective folders, you may need to ask the owner to delete them.

So, make sure that you’re connected with an Administrator account and you have all the necessary permissions over the respective folders.

Also, if the folders that you want to delete are currently open in another program, this may explain why you can’t remove them. Close them and then try to delete them again.

There you go, we hope that these quick tips helped to delete empty folders on your Windows 10 computer.

Learn to make yourself an administrator with our comprehensive guide! It’s easy!

Editor’s Note: This post was originally published in September 2016 and has been since completely revamped and updated for freshness, accuracy, and comprehensiveness.


Was this page helpful?
Thanks for letting us know! You can also help us by leaving a review on MyWOT or Trustpillot.
Get the most from your tech with our daily tips
Tell us why!
  • I set everything as shown and Search in Explorer finds nothing in a tree of folders I know has a huge number of empty folders. I can make a new folder right under the top folder I’m searching, and it can’t find it. Nothing new there with Windows! Many times across the years and versions, I’ve had Windows built in search unable to find certain files, even when I have the file visible right there.