Saving HDD Space

Some places to save HDD space.

Windows search

Windows search data is stored locally in a database. This can be deleted. To delete the database you will need to stop the windows service stop-service 'Windows Search'.

  • Path in Registry Get-ItemProperty 'HKLM:\SOFTWARE\Microsoft\Windows Search\Databases\Windows').FileName
  • Before windows 7 'C:\Documents and Settings\Application Data\All Users\Microsoft\Search\Data\Applications\Windows\Windows.edb'
  • Windows 7 and up Join-Path $Env:ProgramData '\Microsoft\Search\Data\Applications\Windows\Windows.edb'

Recycling bin

Empty the recycling bin

$Recycler = (New-Object -ComObject Shell.Application).NameSpace(0xa)
$Recycler.items() | foreach { rm $_.path -force -recurse }

Disabled hibernation

If you don’t use Hibernation, it can be disabled. Disable Hibernation Command &powercfg -h off

Patch Cache

This Join-Path $Env:windir '\Installer\$PatchCache$\Managed'

Winsxs, Windows 8+

&C:\WINDOWS\SYSNATIVE\DISM.EXE /online /Cleanup-Image /StartComponentCleanup

Windows update log

Windows CBS logs.

Resharper Cache

'C:\Users\[foreach]\AppData\Local\JetBrains\Transient\' This folder can be moved to another drive

nuget cache

Nuget cache can fill up with old versions of files. These can be removed. &$nugetPath locals -clear all


Folder that contains files that can be considered for deletion.

  • *: Any folder
  • [***]: Any folder recursive

Temp Folders

'C:\Documents and Settings\*\Local Settings\temp\*'

Windows folders


Windows logs


Dump files


Browser temp files

IE, temp internet folders

'C:\users\*\AppData\Local\Microsoft\Windows\Temporary Internet Files\*'

Chrome, temp internet folders

'C:\users\*\AppData\Local\Google\Chrome\User Data\Default\Cache\*'
'C:\users\*\AppData\Local\Google\Chrome\User Data\Default\Cache2\entries\*'
'C:\users\*\AppData\Local\Google\Chrome\User Data\Default\Media Cache\*'



Cleans IIS Logs.


.net workspace

.net projects can create a lot of temp files.

  • [workspaces] Path to your base workspace folder

    Workspace TestResults


workspace Bin folders, you would need to rebuild after doing this.


workspace Obj folders, you would need to rebuild after doing this.


Resharper cache folders


Nuget folders


Adobie install files