Dark mode switch icon Light mode switch icon

Safely Wipe a Mac's SSD

1 min read

Disclaimer: This is an old post. Content may be out of date.

Overwrite the macOS disk partition table and re-partition over encrypted data without causing excessive wear by explicitly erasing the full SSD:

# Replace N in diskN with the disk number of your choice
# Use "diskutil list" to confirm, and ALWAYS back up your data

dd if=/dev/zero of=/dev/diskN bs=512 count=1
diskutil partitionDisk /dev/diskN 1 GPT APFS "Macintosh HD" 100%

Gist on GitHub

Originally published on by Lucas Cantor