How to Clear a Hard Drive Cache
In this article
Clearing a hard drive cache (often called the disk cache or buffer) frees up space and can resolve issues like slow performance, corrupted files, or programs that won't load. This guide walks you through clearing the cache on both Windows and macOS, as well as the browser and system caches that commonly cause confusion. You don't need any special tools—just a few minutes and basic access to your computer's settings.
What You'll Need
- Administrator or owner access to your computer (to clear system caches).
- Knowledge of which apps you use most (browser, photo editor, etc.)—this helps target the right cache.
- Optional: a backup of important files (though clearing cache rarely affects personal data).
Step-by-Step
- Identify the type of cache you want to clear. There are three main types: system cache (temporary files used by the OS), app cache (files stored by individual programs), and browser cache (web page elements). This guide covers all three.
- Clear the system cache on Windows:
- Press Windows + R, type
%temp%, and press Enter. - Select all files in the folder (Ctrl+A) and delete them. Some files may be in use—skip those.
- Open the Start menu, type “Disk Cleanup,” and run it. Select the drive (usually C:), check “Temporary files” and “Thumbnails,” then click OK.
- Press Windows + R, type
- Clear the system cache on macOS:
- Open Finder, press Cmd + Shift + G, and type
~/Library/Caches. - Select the folders inside (e.g., com.apple.mail, com.google.Chrome) and drag them to the Trash. Do not delete the entire Caches folder—only its contents.
- Empty the Trash to free space.
- Open Finder, press Cmd + Shift + G, and type
- Clear your browser cache (Chrome, Edge, Firefox, Safari):
- In Chrome/Edge: press Ctrl + Shift + Delete (Windows) or Cmd + Shift + Delete (Mac). Choose “Cached images and files,” set the time range to “All time,” and click “Clear data.”
- In Firefox: press Ctrl + Shift + Delete, select “Cache,” and click “Clear.”
- In Safari: go to Safari > Settings > Privacy, click “Manage Website Data,” then “Remove All.”
- Clear the cache of specific apps (e.g., Adobe, Steam, Discord):
- Most apps store cache in a subfolder under
%appdata%(Windows) or~/Library/Application Support(macOS). - For Windows: press Windows + R, type
%appdata%, and navigate to the app’s folder (e.g., \.discord\Cache). Delete the contents. - For macOS: use Finder > Go > Go to Folder, type
~/Library/Application Support, and delete the cache subfolder for the app.
- Most apps store cache in a subfolder under
- Restart your computer. This ensures all cache files are cleared from memory and that the system rebuilds necessary ones cleanly.
Common Mistakes
- Deleting the entire “Caches” folder (especially on macOS) can break apps. Always delete contents, not the folder itself.
- Clearing cache while an app is running—files may be locked, causing errors or partial deletion. Close apps first.
- Using third-party “cache cleaner” tools that may delete important data or install bloatware. Stick to built-in methods.
- Forgetting to empty the Trash/Recycle Bin—files still occupy space until you do.
- Clearing browser cache too often—it slows down browsing initially because sites need to reload assets.
Tips
- Set a schedule: Clear system cache monthly, browser cache weekly if you notice issues.
- Use the built-in Storage Sense (Windows) or Optimized Storage (macOS) to automate cache cleanup.
- If you’re low on space, focus on browser cache first—it often holds gigabytes of data.
- After clearing, restart your browser or app to ensure it rebuilds cache correctly.
- For SSDs, avoid frequent cache clearing—it causes unnecessary write cycles, though modern SSDs handle it fine.
Troubleshooting
- Files won’t delete (error “file in use”): Close the app that uses the file, or restart the computer and try again.
- System becomes slower after clearing: This is normal—the OS and apps rebuild cache over time. Give it a few hours.
- You accidentally deleted a needed file: If you emptied the Trash, try a recovery tool like Recuva (Windows) or Disk Drill (macOS) immediately—the sooner, the better.
- Disk Cleanup doesn’t show temporary files: Run it as Administrator (right-click > Run as administrator).
- Browser cache clearing doesn’t seem to work: Ensure you selected “All time” and not just “Last hour.”
Frequently Asked Questions
Will clearing cache delete my passwords or saved logins?
No, cache and passwords are stored separately. Clearing cache removes temporary files like images and scripts, not your saved credentials.
How often should I clear the cache?
Only when you experience issues like slow performance or corrupted files. Over-clearing can actually slow your system down because it has to rebuild cache.
Does clearing cache free up a lot of space?
It can—browser caches often hold 1–5 GB, and system caches can be similar. But it varies by usage.
Is it safe to delete all files in the temp folder?
Yes, for the user temp folder (%temp%). Files in use will be skipped automatically. Just don’t delete the folder itself.
Can I clear cache without admin rights?
Yes, for user-level caches (browser, app). System caches may require admin, but you can usually clear them without it.
Why does my cache keep coming back?
Because apps and websites constantly create new cache files to improve performance. That’s normal—clearing is a temporary fix.