No more waiting

How to delete a large folder extremely fast on Windows 10

Using this process, you can delete thousands of files and folders in the matter of seconds on Windows 10, not minutes or hours.

Delete large folder fast on Windows 10

On Windows 10, sometimes you need to delete folders that may contain a large number of files, and using File Explorer can take a long time. The reason is that during the delete process, Windows 10 needs to run calculations, analyze, and show updates as files and folder are deleted, something that usually takes time when deleting a large folder with thousands of files and subfolders.

However, using a few command lines, you can significantly speed up the process to just a few seconds. The only caveat is that you need to be comfortable using Command Prompt.

In this guide, you’ll learn the fastest way to delete large folders with thousands of files using command lines based on a Ghacks’ guide, and the instructions to add an option on the right-click context menu to automate the process with just one click.

How to delete a large folder fast using Command Prompt

In order to delete a large number of files, which otherwise will take a lot of time, you’ll need to use the del and rmdir commands using these steps:

  1. Open Start.

  2. Search for Command Prompt, right-click the result, and select Run as administrator.

  3. Browse the folder path that you want to delete. For example, C:\Users\your-user-name\Documents\CarShow.

  4. Type the following command to delete all the files in that folder without showing the output and press Enter:

    del /f/q/s *.* > nul

    In the above command, we use the /f switch to force the deletion of read-only files. The /q switch enables quiet mode. The /s switch executes the command for all files in any folder inside the folder you’re trying to remove. Using *.* tells the del command to delete every file, and > nul disables the console output improving performance and speed.

  5. Type the following command to go back one level in the folder path and press Enter:

    cd..
  6. Type the following command to delete the folder and all its subfolders and press Enter:

    rmdir /q/s your-folder-name

    In the above command, we use the /q switch to enable quiet mode, the /s switch to run the command on all the folders, and your-folder-name is the variable you need to specify to delete the folder you want.

    Del and rmdir commands
    Del and rmdir commands

How to automate the process adding a context menu option

If the command lines aren’t your thing, you don’t usually delete tons of files, or you’re just looking for a faster way, it’s possible to add a right-click context menu option that will run batch file for the data you want to delete.

To add a context menu option that will delete files and folder extremely fast use the following steps:

  1. Open Notepad.

  2. Copy and paste the following lines into the Notepad text file.

    @ECHO OFF
    ECHO Delete Folder: %CD%?
    PAUSE
    SET FOLDER=%CD%
    CD /
    DEL /F/Q/S "%FOLDER%" > NUL
    RMDIR /Q/S "%FOLDER%"
    EXIT
  3. Click on File and select Save As.

  4. Save the file as quick_delete.bat, but make absolutely sure it uses the .bat extension. If you save it with an .txt extension, this will not work.

  5. Move the quick_delete.bat file to C:\Windows. This step is necessary, because the file need to be on a location that has a path environmental variable, but you can always create your own if you’re up to the challenge.

    Windows folder
    Windows folder
  6. Open Start.

  7. Search regedit, right-click the result, and click Run as administrator.

  8. Navigate to the following path:

    HKEY_CLASSES_ROOT\Directory\shell\
    Quick Tip: You can copy and paste the path in the address bar of the Registry if you’re running the Windows 10 Creators Update.
  9. Right-click the Shell (folder) key, and select New and click Key.

    Shell Registry key
    Shell Registry key
  10. Name the key Quick Delete and press Enter.

  11. Right-click the newly created key, select New and click Key.

  12. Name the key command and press Enter.

  13. Double-click the command key default String on the right side.

  14. Change the value of the key with the following line and click OK.

    cmd /c "cd %1 && quick_delete.bat"

    Command to delete folders and files fast
    Command to delete folders and files fast

Once you’ve completed the steps, you can right-click a folder and select Quick Delete to remove a large folder super fast.

Context menu with new Quick Delete option
Context menu with new Quick Delete option

While executing command you’ll get a security prompt which will prevent you from deleting files by accident. You can then press any key to proceed, or use the Ctrl + C keyboard shortcut or click the X button to cancel the operation.