You’ll also want to read “OS X: About Disk Utility‘s erase free space feature. ” A note at the end starts to get to the heart of the matter. With an SSD drive, Secure Erase and Erasing. Erase Free Space on a Mac Hard Drive to Prevent File Recovery The Mac OS X Disk Utility app provides an ability to erase free space on traditional hard drives, which overwrites vacant disk space on the drive to prevent any potential recovery of deleted files (that is, files that have been removed traditionally, rather than through secure methods). Click the + Volume button in the toolbar. Set the new volume’s reserved space to slightly under the supposed “available” amount of space (the max space and name don’t matter) and save. Select the new volume (double checking you’ve selected the right one!) and click - Volume in the toolbar to delete it.
If you’re selling an old Mac, a spare hard drive, or you’re just quite paranoid about your deleted data, you’re either familiar with—or should be familiar with—the Erase Free Space button on the Erase tab in Disk Utility (found in your Applications -> Utilities folder).
When you click this button, you’re presented with three options for securely erasing the free space on your hard drive: write over the free space with zeros (fast and relatively safe), write over the free space three times (more secure, very slow), or write over the free space seven times (extremely slow).
I use this feature whenever I sell an old machine. First I format the drive and install a fresh copy of macOS, then I use Disk Utility to erase the free space (typically the one-time write-with-zeros option). This gives me a good sense of security, as it would take a team of dedicated professionals, and possibly special hardware, to have some chance of recovering any of my deleted data—though I really only care about a few financial files, and those are kept on an encrypted disk image, so they’re probably safe anyway.
Use Terminal to securely erase a drive
What if you want to do this from Terminal instead? In Terminal, a program named diskutil
provides most of the features of macOS’s Disk Utility.
(Please note that, as with many Terminal commands, there’s a chance of Really Bad Things happening if you make a mistake with the following instructions. Proceed with caution, and make sure your backups are current before you try any of the following.)
To find out about diskutil
in detail, type man diskutil
at the Terminal prompt. Within the man
pages, you’ll find the explanation for how to securely erase a disk’s free space using diskutil
:
But how do you figure out what to list for device
, which is the disk (or partition) that has the free space you’re trying to securely erase? diskutil
can provide that information, too. Just use diskutil list
to see a list of all drives and partitions. On the far right, you’ll see an IDENTIFIER
column; that column contains the identifier that diskutil
needs. Here’s an example of the list
output on my machine:
There’s just one last bit of information you need to know to erase the free space on a drive from the command line. In Unix, all devices appear as part of the file system tree, and in macOS, they’re all listed in the /dev
directory. So if I want to use diskutil
to erase the free space on my Apple_HFS Untitled
volume on my external drive, using the single-pass method, the final command would look like this:
diskutil secureErase freespace 1 /dev/disk2s1
Erase Free Space Mac Big Sur
Warning! It’s critically important that you include the freespace
portion of that command. If you don’t, diskutil
will happily start securely erasing the entire disk, instead of just the free space! Yes, that’s a Really Bad Thing, especially because it will be securely erased, meaning there’s no chance you’ll be able to recover the data.
Free Space On A Mac
Source link
If you are planning to sell your Mac or giving it to a third person for permanent use, then you must erase the hard drive first. This is how you can prevent your data falling into wide of the mark hands.
In case, you are using a newer Mac with an SSD, then you have to take extra care.
You can easily ensure in several ways that data saved on your traditional hard drive is securely deleted. But, they do not really help if you have an SSD. As your SSD won’t fall into the category of a hard drive.
AboutSecurely Erasing SSD:
If your Mac comes with an SSD, Apple’s Disk Utility won’t let you to securely erase the SSD. Yes, Secure Erase and Erasing Free Space options are not available in Mac Disk Utility.


People say these options are not required for an SSD since a standard erase itself is enough potential to make SSD data recovery hard. And, some says securely erasing an SSD, can cause wear and tear on its memory cells which affect the drive’s reliability and performance.
Leaving all these discussions, if you just want to securely erase free space on your SSD then here are two different ways you can try.
Before you getting started with it, let me tell something that “this is not really needed; as Apple itself made so hard to secure erase an SSD. But, if you are set on it then, give a second thought to your mind and proceed.
How to Securely Erase a Mac SSD?
Method 1: Steps to Securely Erase a Mac SSD from Terminal
Step 1: Open Applications folder and switch to Utilities folder.
Step 2: Run the Terminal application.
Step 3: Type diskutil secureErase freespace VALUE /Volumes/DRIVE and hit Enter key
Note: Type a number between 0 and 4 in place of VALUE. 0 for single-pass run of zeroes, 1 for single-pass run of random numbers, 2 for 7-pass erase, 3 for 35-pass erase, and 4 for 3-pass erase. Replace DRIVE with the name of your SSD. To run a 7-pass erase in “Peters-Macbook”, use diskutil secureErase freespace 2 /Volumes/Peters-Macbook code.
How To Wipe A Mac Hard Drive
And if, there is a space in the name of your drive, use a backslash instead of each space (for instance to denote Mac Drive -> Mac Drive).
Method 2: Steps to Securely Erase a Mac SSD Using Disk Utility
Secure Erase Free Space
Step 1: Reboot Mac, hold the OPTION key and select Recovery partition.
Step 2: Next, in OS X Utilities menu click on Disk Utility.
Step 3: Select the SSD primary partition and choose Erase option.
Step 4: Under Format, opt for Mac OS Extended (Journaled, Encrypted).
Add-On: Have you accidentally formatted a wrong volume or drive on your Mac machine? Then, try Yodot Mac Data Recovery and unformat the Mac drive or volume easily. |

Erase Free Space Mac 2020
Step 5: Hit Erase button, and set encryption password.
Secure Wipe Free Space Mac
Step 6: Wait till your drive gets erased and encrypted. It takes time, depending on type, size, and speed of the drive.
Step 7: Next opt Disk Utility and choose Mac OS Extended (Journaled).
Now, Erase Free Space and Security Options are accessible (they are not grayed out).
Erase Free Space Mac El Capitan
Step 8: Click on Security Options and select 35-Pass Erase.
Step 9: Hit the OK button and wait until completion of the process.