Helping people with computers... one answer at a time.

Erasing your hard drive before you give it away is important. Exactly how thorough an erase you need depends on your data and level of paranoia.

I would like to clear off/erase all of the programs on my hard drive and clean it up before I donate my computer to a worthy cause. What's the best/simplest way to do this?

To begin with, good on you not only for your donation, but for thinking to do this. All too frequently we hear of computers being donated by banks, hospitals, or other institutions and then turning up with all sorts of private information that should have been erased first.

The best way? Well ... how paranoid are you?

Not an option: Leaving anything

Quite often, I get this question with an additional caveat - how to remove all of your personal information while leaving Windows installed.

“Well ... how paranoid are you?”

You can't.

The problem is that even after removing all of your data - even if you remember to remove every scrap and even after removing every single application - some of your personal information will still be left on the machine.

If nothing else, there's likely to be random information left in the Windows registry, and unless you take additional steps, all of those files that you carefully deleted could potentially be recovered.

What's worse, of course, are the people that do nothing and leave everything on the machine. It's not uncommon to hear stories of second-hand machines containing a wealth of personal and private information from the previous user.

Let's not do that.

Basic precaution: Format the drive

Conventional wisdom is that reformatting your disk is the right thing to do. And I agree with that, if done properly.

What do I mean by "properly"?

Windows (all versions), and even MS-DOS before it, have the option to perform what's called a "quick format". In reality, a quick format does very little except create an empty root directory on the hard disk and possibly add a label. The rest of the disk is actually assumed to be properly formatted already and left alone. That's why it's quick.

And that's why it's also insecure. Because the rest of the disk is left untouched, any data that is already there will remain. Many commonly available disk recovery tools will be able to recover data from a "quick" formatted disk.

So the basic and common answer is to reformat the disk, making sure to specify unconditional format.

Unfortunately, if that's your C: drive, you won't be able to format the drive if you've booted from it and are running Windows from it. You'll need to either install the disk in a different machine to be able to reformat it or boot from something else.

For the later, I have just the thing...

A safe, practical approach: DBAN

DBAN, which stands for "Darik's Boot And Nuke", is a free utility designed to do exactly what we're talking about by living up to its name: it's a CD that you boot from that then "nukes" the information on the drive.

DBAN start screen

Download the DBAN CD image, burn it to a CD, and then boot from the CD. I need to be really clear on what happens next:

DBAN will automatically and completely delete the contents of any hard disk that it detects.

DBAN does this not by simply deleting files, but by performing a careful overwrite of the entire hard disk surface. When it's done, everything is erased.

Everything.

In fact, DBAN has options to overwrite/erase the hard disk multiple times, so as to prevent any possibility of future data recovery.

DBAN is now my recommendation when you're about to dispose of a hard disk or give a computer away.

Over the top: Physical destruction

It's a common recommendation to use a big heavy magnet to really erase a hard disk. My advice is to forget it. Any magnets that you're likely to have around the house, even your big speaker magnets, are unlikely to affect your hard disk in any significant way. I believe that there have been studies that show that even some exceptionally large magnets still leave the contents of hard disks in a recoverable state.

Another approach to really, positively, and permanently destroy your data is to physically destroy the disk.

Personally, DBAN is more than enough for me, but if I care enough to go this far, I use a drill press and drill a few holes all the way through the hard drive casing, through the disk platters, and out the other side.

Unfortunately, that level of destruction also makes your gift significantly less useful.

If you want to leave Windows on the machine...

As I said before, it's common to want to leave Windows installed as part of your gift.

That may or may not be legal (it depends on the terms of the license for your particular copy of Windows). To keep it at least ethical, it means you would no longer keep or use that copy of Windows yourself.

The right and safe way to transfer Windows in this case is to, after running DBAN, reinstall Windows from scratch using your original installation media. If your system didn't come with installation media, then you could try the restore media that you received or you could restore to an image backup that you took immediately after receiving the machine.

And part of your gift would be to include the product key that activated that copy of Windows.

A product key that, as I said, you would no longer use yourself, having given it away.

(This is an update to an article originally published December 24, 2004.)

Article C2247 - December 9, 2011

A version of this article that can be republished without cost is available at ArticlesByLeo.com terms).
Leo Leo A. Notenboom has been playing with computers since he was required to take a programming class in 1976. An 18 year career as a programmer at Microsoft soon followed. After "retiring" in 2001, Leo started Ask Leo! in 2003 as a place for answers to common computer and technical questions. More about Leo.

Not what you needed?

Recent Comments
98 Comments

7 years ago after buying a new HP notebook the drive died after just 6 months. The people at HP talked me through trouble shooting the drive and decided it had died, and sent me a new drive, free. I only needed to return the dead drive. Not being able to format the drive, I took a strong magnet and sat it on the drive for several hours. I don't know if this worked, but it was the best solution I could come up with.

Posted by: Ken in San Jose at January 21, 2012 9:31 PM

@Ken
That magnet probably did nothing, but if you haven't had any problems 7 years later you're probably OK. HP probably immediately destroyed the drive pretty quickly anyway. It's unlikely they would go to the expense of trying to recover the data as it would have no value to them. Sometimes, unfortunately, we're forced to trust the people who fix our computers. Our data is exposed whenever we bring our computer to a tech for repairs. If you have sensitive data you might want to think about using Truecrypt. Otherwise, after the fact, as Leo said, drilling through the drive may be our best alternative.

Posted by: Mark J at January 22, 2012 12:53 AM

Do you know if a degaussing coil has sufficient strength to erase date on a hard drive? I worked in TV repair years ago and used this regularly to degauss(or rearrange) the magnetic properties of
old CRTs? I am looking for a quick fix obviously, but this may determine whether I donate or recycle. Thanks!

To the best of my knowledge degausing coils (and large magnets) do not have sufficient power to erase today's hard disks. Reformat or use a tool like DBaN to erase the hard drive before donating.
Leo
11-Feb-2012
Posted by: Jeff R at February 11, 2012 11:59 AM

I'm looking to sell an alienware computer, which has the hard drive formatted for RAID (I'm still not entirely sure what this means). Anyway, I tried to use Dban and RAID hard drives aren't supported. I've already used my alienware respawn disks just to get the ball rolling. How can I completely erase all my personal information and get by this unsupported Dban problem?

Posted by: Michael at February 21, 2012 7:49 PM

@Michael
It's probably too late now but you need to open the BIOS and change the SATA mode to IDE then erase each disk. You can then change it back to RAID in the BIOS to reinstall using recovery disk or system image but you may need to recreate the RAID.

Posted by: James at April 2, 2012 4:23 PM
Post a comment on "How should I erase my hard drive before I give it away?":





Remember Me?

(You may use HTML tags for style)

Before commenting, please...

  • READ THE ARTICLE. A comment that shows you didn't will be deleted and ignored.

  • Comment only on the article. Use the search box at the top of the page if you have a question about something else.

  • NO PERSONAL INFORMATION in the comment. No email addresses. No phone numbers. No physical addresses.

  • Anything that looks the least bit like spam will be deleted. Links to unrelated sites or links that appear to be primarily promotional will be deleted, or the comment will be deleted.

  • Don't ask me to recover lost passwords or hacked accounts. I can't. Those comments will be deleted.

  • I can't respond to every comment. And I can't vouch for the accuracy of others who do.

Please wait. Your comment is being processed ...