Categories
Interior

How to overwrite free space securely in windows

What does wipe free space do

Wipe free space is to overwrite the deleted space or unused space on the disk, so that there are only meaningless characters instead of sensitive personal private info left, it’s a way of protecting data privacy operation.

To make it simple, the Wipe free space wipes the disk clean again after you deleted a file or other stuff, it’s an advanced way of deleting data.

Is wipe free space safe

Yes, wiping free space is safe, in Data Wiper, eg, you can wipe free space on any drive, even the C Drive, the system partition, wiping free space won’t affect the data exist, it only deal with data you cannot access but actually stays on the hard drive.

So feel free to use the Wipe free space function when you don’t want to recover what has been deleted.

Does wiping free space improve performance

In fact, wiping free space has nothing to do with improving system performance, if you’re expecting a faster running computer with wiping free space, you may be disappointed.

Wipe free space, this operation only overwrites the sectors on the hard drive, it Windows OS performs the same on deleted space and wiped space when reading and writing, so it’s a system improver. On the other hand, the wiping step takes much time to overwrite the disk when the capacity is too large.

Does wiping free space delete files

No, it won’t delete exist files, like we mentioned above, it’s only the deleted files contents that will be overwritten.

Although you can still using other files and run programs while wiping free space, we still recommend you to close all the running software and close all the opened files before actually wiping free space, so that this performance will do the best to ensure data clean.

How long does wipe free space take

The step of overwriting is sector by sector, so the time spend on this is determined by how many sectors you assigned this operation to wipe. Simply it’s depend on the capacity of the volume you’re wiping, please refer to this picture below

If you want to wipe the unallocated space to further clean data after deleting a partition, here we list two methods to help you easily erase unallocated disk space in Windows 10, 8, 7.

By Emily / Last Updated March 26, 2021

Why need to wipe unallocated space?

Why you might need to wipe unallocated disk space? The first and foremost one should be deleting data from this space to prevent sensitive data from leakage.

When you delete the partition, you cannot clear up the data on the unallocated space completely. That’s due to how the file systems like NTFS, FAT32 works. The files that are removed by deleting partition within Windows are not immediately deleted, and they are simply marked as “deleted” from the Master File Table (the index of hard drive). So these deleted files just become inaccessible from within Windows.

This just makes the deleted data a little harder to access, and anyone using data recovery tools can recover those files easily. Therefore, it is necessary to permanently wipe unallocated space.

2 Methods to wipe unallocated space in Windows 10/8/7

In this part, we will provide you with 2 different methods to wipe data from unallocated space on Windows computer. Take a look at them and choose one based on your requirements.

Method 1. Erase unallocated disk space with Cipher.exe

Cipher.exe is a built-in tool in Windows XP and later versions of Windows PC. It was originally developed to encrypt/decrypt files, but it also has a “wipe” option that securely removes the files that you have already deleted.

The “/w” option which stands for Wipe. When you run it, it overwrites all of the unused/unallocated space on your hard drive (or a specific folder) three times – three passes. The first pass replaces all of your deleted file information with one’s, the second pass with zeros, and the third pass with random numbers. To wipe disk unallocated space with Cipher.exe, follow the steps:

Step 1. Press “Win+R” to open “Run” dialogue. Input “diskmgmt.msc ”and tap OK to open Disk Management.

Step 2. Right-click on the unallocated space and choose “New Simple Volume”. Follow the guide to create a new partition with a drive letter on the unallocated space.

Step 3. Open Command Prompt window: press Win+R to open Run dialogue. Input “cmd ”and tap OK.

Step 4. Type “cipher /w: ” and press Enter.

How to overwrite free space securely in windows

How much time it will cost mainly depends on how large the unallocated space is because it needs to read and overwrite every sector on your drive – three times.

Method 2. Wipe unallocated space with a free partition manager

To erase unallocated space on Windows PC, you can also resort to a free partition manager called AOMEI Partition Assistant Standard. This freeware can not only wipe the entire disk, wipe a specific partition, but also wipe data on unallocated disk space in Windows 10/8/7 and Windows XP/Vista (32bit and 64bit). You can click the button, free download it, and install AOMEI Partition Assistant Standard.

Step 1. Run AOMEI Partition Assistant Standard. Click the unallocated space, choose “Wipe Data” on the left side.

How to overwrite free space securely in windows

Step 2. In the mini window, choose “Fill Sectors with Zero” and click “OK”.

How to overwrite free space securely in windows

вњЋNote: to choose another three advanced wiping methods ( Fill sectors with random data, DoD5220.22-M, Gutmann), please upgrade to AOMEI Partition Assistant Professional.

Step 3. Back to the main interface, click “Apply” to commit the pending operation.

How to overwrite free space securely in windows

This method can also apply to wipe free space on hard drives. In addition to the data wiping function, AOMEI Partition Assistant Standard also has the following amazing functions:

в–Њ Convert non-system disk between MBR and GPT partition styles without deleting partitions;

в–Њ Migrate OS between MBR and MBR disk (HDD/SSD).

в–Њ Merge unallocated space and adjacent partitions;

в–Њ Copy partition to another hard drive;

в–Њ Rebuild MBR (Master Boot Record) on HDD or SSD drive.

Final words

So, when you need to wipe unallocated space, there are two methods available. Apparently, the GUI tool-AOMEI Partition Assistant Standard is a better choice. Moreover, its Professional edition can erase Solid State Drive from all most popular brands such as Samsung, SanDisk and more. To erase data from unallocated space or free space in Windows Server 2019/2016/2012/2008/2003,you can try AOMEI Partition Assistant Server.

How to overwrite free space securely in windows

When you delete files from your hard drive, did you know that the file never actually gets deleted and is likely able to be recovered using tools like Recuva? Normally this isn’t an issue as we use our computer each day, however, if you’re planning to sell or donate your computer and don’t want your old data to be recoverable, follow the steps below to wipe the free space on your hard drive. The process is the same and will work on Windows 7, 8 and Windows 10.

How to overwrite free space securely in windows

What really happens when you delete a file?

When you delete a file on your computer, the only thing that’s removed is the reference to it in the master file table. The file still exists on your hard drive however Windows just doesn’t know where the file is. This is because as mentioned earlier, you’re only removing the indexes and the links to the data and telling Windows it has permission to overwrite that area of the hard drive.

So, until (and possibly after) the data is written over, it can be recovered by special tools or the right set of skills. The tools, or an experienced hacker, can scan the hard drive and look for the files and restore the links and indexes so Windows can see the files again. If you’re selling a computer, or even disposing of one, you should securely wipe the free space on your PC’s hard drive so the files cannot be recovered.

Today we’ll show you how to use the cipher command on the command line to securely write over the free space several times to make sure no data can be recovered. We’ll also mention some third-party tools that do the same thing.

Cipher

Before using the cipher command to securely overwrite the free space on your hard drive, be sure you quit all programs. That ensures the maximum amount of free space is securely wiped.

Click the Cortana icon or the Search icon on the Taskbar and start typing “command prompt.” Then, click Command Prompt under Best match.

How to overwrite free space securely in windows

Type the following command at the prompt and press Enter.

How to overwrite free space securely in windows

Data that is not allocated to any files or folders is overwritten three times and permanently removed. This can take a long time if you are overwriting a large amount of free space.

Cipher goes through the following steps as it securely wipes the free space on your hard drive.

  1. The cipher command automatically creates a new folder on the C drive called EFSTMPWP and then creates a file in that folder with nothing but zeros in it. It will grow until the hard drive fills up.
  2. Then, cipher deletes that file and creates a second file that is filled with the number 255 repeatedly until the file grows big enough to fill the free space on the hard drive again.
  3. Next, cipher deletes the second file, creates a third file, and fills that with random numbers until your hard drive is full again.
  4. Finally, cipher deletes the third file and returns you to the prompt. Type exit at the prompt to close the Command Prompt window.

So, essentially, cipher wrote over the free space (old files) on your hard drive three times to make sure no one could ever scan your hard drive and recover the data you deleted from it.

If you watch your hard drive space, as cipher does its thing, don’t be surprised when you see your hard drive fill up. This is normal as mentioned in the steps above and space will be freed again.

How to overwrite free space securely in windows

CCleaner

If you’re not comfortable using the command line, there’s a free utility called CCleaner that allows you to securely wipe the free space on your hard drive.

NOTE: We are aware that CCleaner was hacked. However, it was the 32-bit version 5.33 distributed by Avast that was compromised. The company has since acknowledged the issue and fixed it to the point that we feel comfortable now recommended them still. That said, be sure you update to the latest version. CCleaner is still a useful and reliable tool.

There are two versions of CCleaner, free and paid. The feature that wipes the free space on your hard drive is available in the free version, so that will do just fine.

Once you’ve downloaded CCleaner and installed it, or updated it, open the program and click Tools on the left pane. Choose Free Space Only from the Wipe drop-down list. Make sure you DO NOT select Entire Drive, as this will erase ALL the files on your hard drive—unless that is what you mean to do. If you’re getting rid of the PC, you can use the Entire Drive option to wipe the entire drive. Be very careful when making this selection.

Select the type of overwriting procedure you want from the Security drop-down list. Simple Overwrite is fine for most situations. However, if you want CCleaner to behave like the cipher command, select Advanced Overwrite (3 passes). Finally, select the drive on which you want to securely wipe the free space in the Drives box and click Wipe.

How to overwrite free space securely in windows

Eraser

Another option for making sure your deleted data cannot be recovered is to delete your files and folders securely in the first place.

Eraser is a free, advanced security tool for Windows that allows you to securely delete data from your hard drive by overwriting it several times with carefully selected patterns, like the cipher command and CCleaner. The difference is you can do this when you delete the files and folders, not after. You can also securely wipe the free space on your hard drive to be extra safe.

When you download Eraser and install it, an option is added to the context (right-click) menu in File Explorer. Instead of deleting files and folders normally by pressing the Delete key, sending them to the recycle bin, and then emptying the recycle bin, you can use Eraser directly in File Explorer to securely delete files and folders.

To securely delete one or more files or folders, select what you want to delete, right-click on the selection, and then go to Eraser > Erase on the popup menu.

How to overwrite free space securely in windows

What do you use to securely wipe the free space on your hard drive? Or is this brand new information? Share your thoughts and experiences in the comments below.

Zerofill is a tiny program for Microsoft Windows devices that overwrites the unused disk space of any drive you point it to with zeros.

Designed to improve the compacting of allocated disk space on volumes, something which virtual machine tools or disk compression software benefit from, it makes old data that still sits on those drives unrecoverable as well.

Data that is deleted on PCs is not erased entirely when you hit the delete button or run remove operations. What happens is that Windows removes the reference to files instead but leaves the files on the hard drive.

File recovery software, like Recuva, R-Undelete or may restore deleted files partially or even fully. Whether that is possible or not depends on a single factor: whether the disk space the file occupies has been overwritten with other data since its deletion.

Zerofill

How to overwrite free space securely in windows

Zerofill is a command line utility developed by the author of FileOptimizer to overwrite free disk space with zeros. It has a size of just 10 Kilobytes and can be run without installation.

Note: the program should not be run on Solid State Drives.

The program runs in DOS environments only which is limiting; an attempt to run the program on a 64-bit Windows 10 system resulted in a not-compatible error.

Zerofill needs to be run with a drive letter as a command parameter, e.g. zerofill d: to fill the free disk space of the d: drive with zeros.

The time it takes to process the drive depends on several factors that include the drive’s performance, size and size of free space on the disk.

Zerofill displays a progress bar that visualizes the state of the operation.

Closing Words

The limitation to DOS environments makes Zerofill a specialized software program, one that most Windows users won’t run probably or may not even know how to run as they are used to do everything in Windows.

The program works fine when you run it though and it may be used in batch scripts to automate the process.

Alternatives that run on Windows are available, and the majority of Windows users likely prefers them as they run on Windows.

Zerofill is not the first program to offer that functionality. We reviewed programs like SDelete or Eraser before which you may run from within Windows to overwrite unused disk space to prevent restoration.

Now You: do you overwrite free disk space regularly?

I would like to wipe ALL free space on my SSD which Windows 10 is installed on, so that no previously deleted file can be recovered. How can I achieve this?

2 Answers 2

Assuming that the SSD has a properly implemented TRIM function, then Free Space should already be wiped for you, this is what TRIM does as a side effect of preparing deleted/unallocated files for reuse in an SSD.

To check if TRIM is on in Windows, from a command prompt:

fsutil behavior query disabledeletenotify

The response should be one of these:

NTFS DisableDeleteNotify = 0” Which means TRIM is ON.

NTFS DisableDeleteNotify = 1” Which means TRIM is OFF.

If for whatever reason you want to roll your own as it were, you can use any of a myriad of cleaning utilities or simply create a giant file of arbitrary data until you run out of space then delete the file.

That said, there are GOTCHAS to be aware of!

Wear Leveling – (Not an Issue)

This is an effect of SSD’s swapping physical storage cells with spares as the cells begin to wear out. Once swapped out, the old data in the cell is no longer reachable to be wiped. This is not a realistic concern. This data is beyond the reach of all standard forensic labs. The few that could perform the necessary chip off disassembly are rare, very expensive, and still have poor capabilities to reassemble the wear bits into anything coherent.

Windows Shadow Volume – (Big Concern)

Deleting and wiping files in Windows does not necessarily touch previous versions of those files kept by Windows for file recovery.

MFT and small files

Small files (in the under 1 KB range but varies) may be stored directly in the Master File Table instead of as their own file. This is important because when these small files are deleted, only the usage indicator is deleted from the MFT, but the MFT itself is NEVER deallocated.

Databases

Similar to the MFT, removal of an entry in a database does not deallocate the database file. Until that particular slot is reused or the database is compressed/vacuumed the data is potentially still there.

updated on 2018-01-22 to Data Erasure

It’s actually normal for Windows Vista users to find any information to solve their problems, including data erasure problems. I guess it’s hard for you to find the reliable way to permanently wipe all data on Windows Vista, just like when you’re trying to find other methods on anything you want to solve. That’s because Windows Vista is one of the Operating System which rarely used by current computer users. I can’t truly understand the reason why, but we all know the fact.

But if what you’re looking for is how to permanently wipe all data on Windows Vista, you just come into the right place. Because not only you can find how to wipe all data and make sure it’s gone forever, but also you’ll find the special tool which could wipe all data off Windows Vista computer as easy as counting 1 2 3.

Windows Vista Data Wiper Download

In fact, all you need to do to wipe all data from the Windows Vista hard drive is just doing a few simple clicks, and it’s done like magic. Because that Windows Vista disk wiper – AweEraser can help you do all the things you need, it securely and easily erase all data on the Windows Vista computer with a few clicks. The software offers you three Data Erasure options which could be used to:

  1. Erase files or folders you want to destroy individually.
  2. Completely wipe all the data from your hard drive.
  3. Wipe free space on your hard drive which could permanently destroy already deleted/lost data.

Although the software is unbelievably powerful, it comes in a tiny size. So you don’t have to worry it will eat a lot of space in your small hard drive space. And of course, this also means it could be downloaded and installed on your Windows Vista computer within a few seconds. Furthermore, on this article, you’ll also learn how to wipe all data on Windows Vista using AweEraser.

Three modes to permanently wipe data on Windows Vista

Note: Please make sure you backup all the important data you don’t want to lose. Remember, once the files are erased, it’ll be impossible for you to recover your data.

Mode 1: wipe files/folders on Windows Vista.

This mode allows you to selectively wipe files or folders from Windows Vista hard drive or external storage media device. Just add the files and click on “Erase” button. The selected files/folders will be permanently wiped.

How to overwrite free space securely in windows

Mode 2: wipe hard drive on Windows Vista.

This mode can help you wipe an entire hard drive on Windows Vista. It will permanently wipe all data on the selected hard drive.

How to overwrite free space securely in windows

Mode 3: wipe free disk space on Windows Vista.

How to prevent deleted file recovery on Windows Vista? This mode will wipe the free space of the hard drive on Windows Vista and permanently erase all deleted/lost data on the hard drive.

How to overwrite free space securely in windows

The second mode is highly recommended when you are going to sell or donate your Windows Vista computer. This mode will destroy all exiting data and deleted/lost data on the hard drive. No information can be recovered.

Related Articles

  • Reliable Windows XP Data Erasure Solution
  • Securely Wipe Hard Drive with Windows 10 Disk Wiper
  • How to Permanently Delete Files in Windows 7 with File Shredder?
  • How to Reformat an SD Card?

Related Products

Securely shred files and wipe hard drive with military data erasure standards.

Securely and permanently erase data from Mac hard drive or storage media.

Today’s Best Tech Deals

Picked by PCWorld’s Editors

Top Deals On Great Products

Picked by Techconnect’s Editors

Most Windows users know that when you delete a file on a PC, it isn’t truly gone and can still be recovered. In fact, those deleted files are actually just sitting there on your hard drive until they are overwritten with new data.

To truly wipe data, users often turn to apps like CCleaner or Eraser that wipe free space for you. But Windows also has a built-in feature called Cipher that will overwrite deleted files for you and may even free up some extra disk space in the process.

Commanding Windows

To use Cipher we have to dive into an area of your Windows machine that some hassle-free readers may have little experience with: the Command Prompt.

Don’t worry, though. While the command line can be a scary place, Cipher is a fairly safe feature. That said, it’s always best to make sure you have your data backed up before giving something like this a try.

Also, make sure you type the command correctly to avoid any unintended consequences. Cipher isn’t just a tool to overwrite deleted data it can also be used to encrypt data, which is not what we want in this case.

Dump the deletions

To get started you have to open a command prompt. To do this in Windows 8.1, hit the Windows key + S and type command prompt into the search box. Wait for the results to show up and then click the command prompt option. In Windows 7, it’s easiest to click on Start > Run and then type cmd into the box and press enter.

Now for the easy part. If you have a standard Windows installation type or copy and paste the following command:

What this tells Windows to do is to start the Cipher program. The ‘ /w ‘ switch says to remove any data from the available unused disk space, and C tells Windows to carry out this action on the C:\ drive.

If your data is on a different drive such as a partition labeled D:\ simply substitute C for the correct drive letter. For most people, however, C will be the right choice.

Now, just sit back and wait for Windows to do its magic. This is one of those tasks you should run when you’re not using your PC. Consider running it overnight or during downtime on the weekend.

Windows will also advise you to close as many running programs as possible to help the machine do a better job of clearing up your hard drive.

Not only will cipher clean up your drive, it may also have the added benefit of returning some extra disk space to you. Recently, I let cipher run and got back about 10GB on a four year-old PC.

Ian is an independent writer based in Israel who has never met a tech subject he didn’t like. He primarily covers Windows, PC and gaming hardware, video and music streaming services, social networks, and browsers. When he’s not covering the news he’s working on how-to tips for PC users, or tuning his eGPU setup.

This article describes how to use Cipher.exe to overwrite deleted data in Windows Server 2003.

Original product version: В Windows Server 2003
Original KB number: В 814599

Summary

Administrators can use Cipher.exe to encrypt and decrypt data on drives that use the NTFS file system. They can also use it to view the encryption status of files and folders from a command prompt. The version of Cipher.exe that’s included with Windows Server 2003 includes the ability to overwrite data that has been deleted so that it can’t be recovered or accessed.

When you delete files or folders, the data isn’t initially removed from the hard disk. Instead, the space on the disk that was occupied by the deleted data is deallocated. After it’s deallocated, the space is available to use when new data is written to the disk. Until the space is overwritten, you can recover the deleted data by using a low-level disk editor or data-recovery software.

When you encrypt plain text files, Encrypting File System (EFS) makes a backup copy of the file. So the data isn’t lost if an error occurs during the encryption process. After the encryption is complete, the backup copy is deleted. As with other deleted files, the data isn’t removed until it has been overwritten. The Windows Server 2003 version of the Cipher utility is designed to prevent unauthorized recovery of such data.

Use the Cipher security tool to overwrite deleted data

The cipher /w command does not work for files that are smaller than 1 KB. Therefore, make sure that you check the file size to confirm whether is smaller than 1 KB. This issue is scheduled to be fixed in longhorn.

To overwrite deleted data on a volume by using Cipher.exe, use the /w switch with the cipher command:

  1. Quit all programs.
  2. Select Start >Run, type cmd, and then press ENTER.
  3. Type cipher /w: folder , and then press ENTER, where folder is any folder in the volume that you want to clean. For example, the cipher /w:c:\test command causes all deallocated space on drive C to be overwritten. If C:\folder is a Mount Point or points to a folder on another volume, all deallocated space on that volume will be cleaned.

Data that isn’t allocated to files or folders is overwritten. The data is permanently removed. It can take a long time if you overwrite a large amount of space.

Free space in Windows operating system is an ambiguous and confusing thing. When you delete files in a window, it seems that the files have been erased from the hard disk memory. In reality, this is far from truth. Even though you find that the files have been removed, but it remains in the hard disk until it is overwritten by any new data. In Solid State Devices, it is difficult to recover deleted data because SSDs deploy TRIM and garbage collection which makes it difficult to recover those data. In Windows operating system, there is an in-built utility tool called Cipher. Cipher helps you to wipe off free space from a drive so that the data is actually removed from the memory of the computer. Cipher works on the basis of three passes. The first pass fills the free space with zero data, the second one fills it with 0xFF numbers, and the final pass fills it with random numbers. Hence, wiping off free space using cipher tool takes a lot of time.

You need to close all the applications while running the cipher utility tool.

Steps to wipe free space securely in Windows without third party tools

1. Press Win+X and tap on Command Prompt (Admin) to open the Elevated Command Prompt.

How to overwrite free space securely in windows

2. Now type the following command and then hit Enter.

cipher /w:C

You can replace the letter ‘C’ by another other drive letter whose free space has to be wiped off.

How to overwrite free space securely in windows

The wiping process will take some time.

How to overwrite free space securely in windows

How to overwrite free space securely in windows

About Nick

Nick is a Software Engineer. He has interest in gadgets and technical stuffs. If you are facing any problem with your Windows, feel free to ask him.