Subscribe to RSS feed  Follow @jackvamvas - Twitter

*Use the Comments section for questions Links


SQL Server DBA Jobs

How do I find hidden files taking up space?

06 June,2023 by Tom Collins

Question: I'm attempting to drop a drive on Windows 2016 but seeing space used . I've checked the drives but there are no files in the drive. I also checked "Hidden items" and no files appear . How can I identify the items taking up the space ?


Answer: These steps deal with a common problem of deleting items from the hidden folder $Recycle.bin  

Note : If you think the issue it's  related to the pagefile.sys you can Find Windows pagefile location through command line and wmic

Step 1 : assuming your dive is called : H:\. Open the windows cmd and execute this command:

dir /s H:

Step 2:   You'll notice a single or series of folders that contain files that were deleted. 

Step 3: Once you have completed all due diligence and checked that you want to clear the Recycle bin , execute the following command.

NOTE: This command sequence  permanently deletes all files\folders in the Recycle Bin  from all the users - and cannot be recovered.

rd /s /q H:\$Recycle.bin

In this example , you're clearing out the hidden $Recycle.bin folder of the H:\ drive. Customise according to your requirements 


An alternative approach is to use Powershell read Find Recycle Bin location and clear down with Powershell   

If you're using Windows 2012 - Windows Server 2012 empty recycle bin


Author: Tom Collins (


Verify your Comment

Previewing your Comment

This is only a preview. Your comment has not yet been posted.

Your comment could not be posted. Error type:
Your comment has been posted. Post another comment

The letters and numbers you entered did not match the image. Please try again.

As a final step before posting your comment, enter the letters and numbers you see in the image below. This prevents automated programs from posting comments.

Having trouble reading this image? View an alternate.


Post a comment on How do I find hidden files taking up space? | SQL Server Performance Tuning | SQL Server DBA:Everything | FAQ | Contact|Copyright & Disclaimer