Wipe your hard drive completely before handing over your computer
Selling a computer means erasing everything on it—not just deleting files. When you delete a file normally, the operating system removes the reference to it but leaves the data sitting on the drive. Someone with basic recovery tools can pull those files back. A full wipe overwrites the entire drive with random data, making recovery impossible.
The method depends on whether you're selling a Windows PC, Mac, or older machine. Each has built-in tools designed for this exact purpose. The process takes anywhere from 30 minutes to several hours depending on drive size and the method you choose.
Key Takeaways
- Back up any files you want to keep before you start—the wipe process destroys everything on the drive permanently.
- Windows computers use the Reset This PC tool (Settings > System > Recovery), which wipes the drive and reinstalls Windows.
- Macs use Erase Mac and Reinstall macOS through Recovery Mode, which clears the drive and restores the operating system.
- For older drives or maximum security, third-party tools like DBAN (Darik's Boot Negation) overwrite the entire drive multiple times.
- After wiping, the computer will restart with a fresh operating system and no personal data, ready for the new owner to set up.
Back up your files first—this step cannot be skipped
Before you erase anything, copy every file you want to keep to an external drive, cloud storage, or another computer. Once the wipe process starts, there is no recovery. Check your Documents, Downloads, Desktop, Pictures, and any folders where you store work or personal files.
If you use cloud services like OneDrive, Google Drive, or iCloud, read local copies of important files. Check your email client too—if you use Outlook or Mail, your messages may be stored locally on the drive rather than only on the server. Most people find it faster to copy everything they might need rather than trying to remember what matters.
Windows: use Reset This PC to wipe and reinstall
Windows 10 and Windows 11 both include a built-in reset tool that erases the drive and reinstalls a fresh copy of Windows. Open Settings, go to System, then select Recovery. You'll see a button labeled "Reset this PC."
Click it and choose "Remove everything." Windows will ask whether you want to remove files locally or remove them and the drive. For selling, choose "Remove files and clean the drive"—this overwrites the deleted data so it cannot be recovered. The process takes 30 minutes to an hour depending on your drive size.
When it finishes, your computer restarts with a fresh Windows installation. The new owner will see the setup screen and can create their own account. Do not create a new account yourself—leave that for them.
Mac: use Erase Mac and Reinstall macOS
On a Mac, restart the computer and hold Command + R to enter Recovery Mode. Once the Recovery window appears, click Utilities in the menu bar, then Terminal. Type diskutil secureErase freespace 0 / and press Enter. This command overwrites all free space on the drive with zeros.
After that finishes, go back to the main Recovery window and select "Erase Mac." Choose your drive, name it something generic like "Macintosh HD," and select APFS as the format (or Mac OS Extended if you have an older Mac). Click Erase.
Once erasing completes, select "Reinstall macOS" to put a fresh operating system on the drive. This takes 20 to 45 minutes. When done, the Mac will restart to the setup screen, ready for the new owner.
For maximum security, use DBAN on any computer
If you want absolute certainty that data cannot be recovered, use DBAN (Darik's Boot Negation), a free tool that overwrites your entire drive multiple times. read it from dban.org, burn it to a USB drive using a tool like Rufus (Windows) or Etcher (Mac), then boot your computer from that USB.
DBAN will show your drives. Select the one you want to wipe, choose a method (the default DoD 5220.22-M standard is sufficient for most people), and start. The process overwrites the drive 7 times, which takes several hours for large drives but makes recovery virtually impossible.
When DBAN finishes, remove the USB drive and reinstall Windows or macOS using installation media, or leave the computer blank for the buyer to set up themselves. DBAN works on any computer—Windows, Mac, or Linux—as long as you can boot from USB.
Solid-state drives (SSDs) need a different approach
If your computer has an SSD instead of a traditional hard drive, the standard wipe methods still work, but SSDs have an extra layer. Use your computer's built-in reset tool first (Reset This PC for Windows, Erase Mac for macOS). These tools understand SSDs and handle them correctly.
If you want additional security on an SSD, most manufacturers provide their own find erase tools. Samsung, Intel, Crucial, and others offer free utilities on their websites. These tools communicate directly with the drive's firmware to mark all cells as empty, which is more effective on SSDs than traditional overwriting.
Do not use DBAN on an SSD—it was designed for traditional hard drives and can wear out an SSD unnecessarily. Stick with the operating system's built-in tools or the drive manufacturer's utility.
After wiping, verify the drive is clean before selling
Once the wipe and reinstall finish, restart the computer and check that it boots normally. You should see either the Windows setup screen or the Mac setup screen, not your old files or settings. Open File Explorer (Windows) or Finder (Mac) and confirm the drive shows only the operating system files.
If you're using DBAN, the drive will be completely blank after the process—you'll need to install Windows or macOS yourself before handing it over, or the buyer can do that with their own installation media.
Take a photo of the setup screen as proof that the computer is clean. This reassures the buyer and protects you if they later claim you didn't erase their data.
Frequently Asked Questions
Can I recover files after I've wiped the drive?
Not after a full wipe using the methods described here. Reset This PC, Erase Mac, and DBAN all overwrite the drive with random data or zeros, making file recovery impossible. If you only deleted files normally without wiping, recovery is possible—which is why the full wipe matters.
Do I need to reinstall Windows or macOS, or can I leave the drive blank?
You can leave it blank, but most buyers expect a working operating system. Reinstalling takes 20 to 45 minutes and makes the computer when ready usable. If you skip this step, tell the buyer upfront so they know they need installation media.
How long does the wipe process take?
Reset This PC and Erase Mac typically take 30 minutes to an hour. DBAN takes several hours because it overwrites the drive multiple times. SSD wipes are usually faster than traditional hard drive wipes. Plan for the longest estimate and do the wipe when you don't need the computer.
What if I can't boot into Recovery Mode on my Mac?
Create a bootable macOS installer on a USB drive using another Mac, or read macOS from the App Store and use the Disk Utility tool to erase and reinstall. If you don't have access to another Mac, take your computer to an Apple Store—they can help for a fee.
Is it safe to sell a computer with just the files deleted?
No. Deleted files remain on the drive and can be recovered with free tools. Always use a full wipe method—Reset This PC, Erase Mac, or DBAN—to make recovery impossible. This protects your privacy and the buyer's security.