Helping people with computers... one answer at a time.
Before giving away a machine or returning a loaner it's important to remove personal information from it. That's both harder and easier than you think.
I'm about to give away my machine, but I want to leave Windows installed. How can I delete permanently everything except the OS?
Ultimately, you really can't.
It depends a lot on how paranoid you are about the various and sundry traces left on a machine that you've been using a while.
I'll describe a few steps that will delete a lot - perhaps even enough for your concerns.
But everything? There's only one way to do that.
Naturally the process starts where you might expect: by deleting your data files and uninstalling all the programs that you've used or added and don't want to be part of the machine when it's re-used by someone else.
For your data files, that means removing things from My Documents and wherever else you happen to keep data files.
A good start for programs is to take a walk through the Add/Remove programs application in the Contol Panel and just start uninstalling.
For extra security you might want to use Revo Uninstaller instead of control panel. Revo not only lists more things, but it also uninstalls more thoroughly. (It has a couple of levels of "aggressiveness" in determining what to remove, and this is one of the cases where it might make sense to risk being as thorough as possible.)
Removing all the users on the machine other than the required Administrator account should delete a plethora of files and settings associated with those users.
Run the built-in Disk Cleanup Utility, or better yet, grab a copy of CCleaner, (a free download - you do not need to buy support) and use it to clean up as much as it can.
The goal here is to remove traces from browser caches, temporary files, and a host of other things - many of which might well be benign, but many others might inadvertently contain things you'd rather not share with your machine's subsequent owner.
You might consider running a registry scan. I'm not a big fan of registry cleaners, but this is a case where they might remove additional information you don't want left behind, and the cost of failure (an unbootable machine) is relatively low. You may want to take an image backup prior to the cleaning just in case you want to be able to recover from that worst case scenario.
Set your virtual memory to zero and delete the paging files.
Turn off Hibernation, and remove the hibernation file.
Turn off System Restore.
All of these can contain private information, and can be turned back on by the machine's new owner should they so desire.
Using a tool like SDelete to securely erase the unused space on your hard disk. By default just deleting files doesn't overwrite the data, and it could still be recovered. Tools like SDelete actually overwrite all of the unused space on your hard drive with random data so as to completely remove all traces of what had been stored there before.
That's about as good as you can get using this approach.
The problem with this approach is that you don't know what you might have missed.
There might be system files that contain information about you. Registry settings that remain even after all the deletion and cleaning above that contain settings for programs - perhaps even programs no longer installed - that indicate something about who you are or what you used the machine for.
You just don't know.
And that's why it's not an approach I ever recommend.
Using a tool like DBAN, erases the hard drive completely. It's easy, and every single bit of every single byte - operating system, settings, programs and data - is removed from the hard drive.
Including all your personal information.
Then, if you like (and if you can) reinstall the operating system from an install disk.
If you don't have one, then perhaps grab a copy of Ubuntu Linux, and install that.
But erasing the hard disk completely is the only way to be absolutely sure that you haven't left personal information on the machine prior to handing it off to someone else.
Well, that or remove the drive and give them the machine without it. But even then you'll want to erase the drive before disposing of it.