How to remove empty folders in Windows 10

Vlad Dragomir avatar. By: Vlad Dragomir
5 minute read
remove empty folders

For various PC problems, we recommend this tool.

This software will repair common computer errors, protect you from file loss, malware, hardware failure and optimize your PC for maximum performance. Fix PC issues now in 3 easy steps:

  1. Download this PC Repair Tool rated "Excellent" on TrustPilot.com.
  2. Click “Start Scan” to find Windows issues that could be causing PC problems.
  3. Click “Repair All” to fix all issues with Patented Technologies (requires upgrade).

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

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.

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. For various PC problems, we recommend this tool.

    This software will repair common computer errors, protect you from file loss, malware, hardware failure and optimize your PC for maximum performance. Fix PC issues now in 3 easy steps:

    1. Download this PC Repair Tool rated "Excellent" on TrustPilot.com.
    2. Click “Start Scan” to find Windows issues that could be causing PC problems.
    3. Click “Repair All” to fix all issues with Patented Technologies (requires upgrade).

  5. Select where you want to install the software and click on the Next button.
  6. 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.
  7. 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.
  8. 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.
  9. 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.

3

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

4

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

5

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.


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


RELATED STORIES YOU NEED TO CHECK OUT:

For various PC problems, we recommend this tool.

This software will repair common computer errors, protect you from file loss, malware, hardware failure and optimize your PC for maximum performance. Fix PC issues now in 3 easy steps:

  1. Download this PC Repair Tool rated "Excellent" on TrustPilot.com.
  2. Click “Start Scan” to find Windows issues that could be causing PC problems.
  3. Click “Repair All” to fix all issues with Patented Technologies (requires upgrade).

Discussions

Next up

Surface Pro 3 gets new security updates, install goes smoothly

Giles Ensor avatar. By: Giles Ensor
2 minute read

After recent bad news stories about updates released by Microsoft for Windows 10, that you can read here and here, it is refreshing to read (or […]

Continue Reading

Best Windows 10 antivirus software to use in 2018

Radu Tyrsina By: Radu Tyrsina
7 minute read

Update – 2018 will soon come to an end and we already have a guide on what is the best antivirus you should get in […]

Continue Reading

These features are out for good with Windows 10 version 1809

Sovan Mandal avatar. By: Sovan Mandal
2 minute read

Microsoft is all set to launch its next big update, Windows 10 version 1809 in October. While that should be a nice piece of news […]

Continue Reading