Table of Contents
    Home / Insights / How to Clean a Computer’s Hard Drive  
    Computers 7 min read

    How to Clean a Computer’s Hard Drive  

    The hard disk drive within a computer stores all of the device’s persistent, or secondary, storage. As computer users download more applications, create more documents, or even use a browser window, data piles up on the hard drive. Because computers have limited storage, users may want to create more space on their hard drive or wipe it altogether.

    Compressing files can open more space on the hard drive, but decompressing files requires  significant computing power. Your C drive should also never be compressed.

    This guide to cleaning hard drives lists instructions for both Windows and Mac computers and recommendations for completely wiping a computer’s hard drive of all personal data.

    Jump ahead in this article:

    How to clean a Windows computer hard drive

    To create space on your PC hard drive, you can perform a few different maintenance tasks and clear unnecessary files or applications.

    Deleting unnecessary files

    Windows computers collect files and programs that clog disk space, some of which aren’t necessary for the computer or any programs to run. In particular, after updating, Windows operating systems continue to store upgrade logs and temporary installation files on the hard drive. To find and remove these files:

    1. Click the Start button.
    2. Type “Disk Cleanup” in the search bar at the bottom of the Start menu
    3. Select the drive you want to clean up (often C in Windows)
    4. Click OK
    5. Click Clean up system files
    6. Select “Windows upgrade log files” and “Temporary files”
    7. Click OK
    8. When prompted, confirm that you really do want to delete the selected files

    If you delete these files, you won’t be able to revert to a previous version of the operating system. This isn’t as dire as it sounds; from a security standpoint, returning to an old system version isn’t recommended.

    Cleaning the Recycle Bin

    Windows users can also clean out their Recycle Bin. The Recycle Bin appears as an icon on the computer’s desktop.

    The recycle bin icon on Windows computers.

    To empty the Recycle Bin, simply right-click the icon on your desktop. You can also search for it:

    • Click the Start button on your desktop
    • Select Settings
    • Select System
    • Select Storage
    • Choose This PC

    The window will show Temporary Files, which includes the Recycle Bin, as well as all other temporary files.

    Once you are inside the Recycle Bin, the menu that lists Trash will list everything currently in the Bin. To empty it completely, click Empty Recycle Bin.

    how to empty the recycle bin on a Windows computer.

    The computer will then make sure you truly want to delete the selected files.

    Confirming the recycle bin is empty on Windows.

    Once you select Yes, the file will be deleted from your hard drive. This will free space on the drive. However, if the file is sensitive and you want to ensure full erasure, you should use a more secure method of wiping the data.

    Deleting apps you don’t use

    Another way to partially clean a hard drive and create space is deleting applications you don’t use or need. Some apps use a large amount of drive storage space.

    To view and delete apps, first launch the Start menu. Select Settings.

    Settings Option in Start on Windows—how to clean hard drive.

    Within the Settings menu, select Apps and other features.

    Apps Option in Settings Menu Windows—how to clean hard drive.

    In the application settings menu, a list of applications will show how much hard drive space each app takes up and give an option to uninstall the app.

    How to wipe a Windows computer hard drive

    Completely wiping the computer’s hard drive consists of a couple different steps. If you want to completely erase your hard drive’s data and reuse the drive yourself, then perform the following process:

    Click the Start button, and then click Settings.

    Settings Option in Start on Windows—how to clean hard drive.

    Select the Update & Security button.

    Recovery Option in Settings Menu Windows—how to clean hard drive.

    Select Recovery from the menu of options.

    Select Recovery on Left Side on Windows computer.

    There are multiple choices in the Recovery tab. Under Reset this PC, select Get started.

    Recovery options in Windows.

    If you want to delete all data, select Remove everything.

    Reset PC Options on Windows—remove everything.

    If you don’t plan on keeping the hard drive and want to ensure your personal data can’t be recovered, using disk wiping software adds another layer of security. Some disk wiping programs overwrite all data, which makes it unrecoverable in most cases. For organizations that need to reuse employee computers, disk wiping software is a good choice. Programs like this include DBAN and CCleaner.

    How to clean a Mac hard drive

    To create space on your hard drive and delete files that are cluttering the computer, you can complete several simple disk maintenance tasks.

    Emptying the trash

    The Trash on Mac computers doesn’t automatically remove files from the computer. They remain in the Trash available for retrieval for a set period of time before completely disappearing. To preemptively empty the trash, navigate to the far right or bottom of your Dock, double-click the Trash icon, and empty it. The Trash icon is pictured below at the bottom right corner of the desktop window.

    Desktop image of the trash on Mac.

    Note that deleting files, though it frees up disk space, does not ensure that the file’s data will be erased from the drive. Deleting a file from the computer system removes the computer’s path to that file, but it’s often still traceable on the hard drive and may be recoverable by software.

    Read More: Are Deleted Files Completely Erased Forever?

    Deleting applications

    If you want to delete an application, click and drag one down to the Trash icon. If you want the application to be instantly removed from the hard drive, follow the Trash-emptying process again.

    At the far left end of your dock, select Finder. 

    locating Finder on a Mac computer.

    Within Finder, choose the Applications folder. You can view them by icon or by written list. You can drag and drop any application from the list into the Trash below.

    dragging applications to the trash on a mac computer.

    You can also view a list of all your applications ordered by how much drive space they occupy.

    a list of applications in order of drive space they take up on Mac.

    How to wipe a Mac hard drive

    Erasing a drive is a good choice if you intend to keep the Mac. If you plan to get rid of it, you may want to pursue even more secure methods of deletion.

    However, if you want to retain data on another device, the first step before erasing any data is to back up all the data you need to keep. Using an external hard drive or a cloud storage account is a good option, but having both adds protection in case one should fail.

    To erase a disk on a Mac computer, navigate to the Disk Utility. In your Finder, select the Applications tab and scroll to Utilities.

    Applications on Mac and the Utilities folder.

    Select Disk Utility.

    The disk utility application on a Mac computer.

    The initial Disk Utility window shows the following:

    Mac info within Disk Utility.

    To see all drives, click View at the top, and select Show All Devices.

    show all devices in Disk Utility on Mac.

    The window will list Mac drives, and at the top of the page is an option to Erase each one.

    If you’re selling or redistributing the computer, using drive-wiping software adds more security to the erasure process. Running software to wipe a drive further decreases the chance someone will be able to recover your personal data from the disk. Clean My Mac, for example, has a Shredder feature that permanently deletes data.

    Additional options for erasing data from hard drives

    If you no longer want to keep the disk or redistribute it, and are only concerned about destroying any data, you can use a strong rare earth magnet on the physical disk. If you remove the hard drive and apply the magnet, it will deform the metal plate that stores data. This will make the disk unusable. Alternatively, you could smash the disk to make it unusable.

    Also Read: How to Reformat Your Hard Drive