Key points
- Delete the contents of ~/Library/Caches, never the folder, and quit the apps you are cleaning first.
- ~/Library/Caches is per-user; /Library/Caches is shared by all users and needs an administrator password.
- Never delete /System/Library/Caches — those are Apple-managed system caches.
- Clearing cache is not a permanent space win: apps regenerate it as you use them.
- Slower first launches and repeated sign-ins after clearing are normal, not damage.
Clearing cache on a Mac means deleting the files apps keep so they can open faster next time. Those files are regenerable, which makes cache one of the safer things to remove. It is not a permanent fix, and a few cache locations should be left alone. This guide covers where cache lives, how to measure it before deleting, and what to expect afterwards.
What a cache actually is
A cache is a local copy of data that is expensive to fetch or compute: decoded images, thumbnails, web assets, API responses. The app reads from the cache instead of doing the slow work again. When the cache is missing or stale, the app rebuilds it.
Where caches live on macOS
| Location | What it holds | Safe to remove |
|---|---|---|
~/Library/Caches | Per-user app caches | Yes, the contents |
/Library/Caches | Caches shared by all accounts | Usually, needs admin rights |
~/Library/Containers/<app>/Data/Library/Caches | Caches for sandboxed apps | Yes, the contents |
| Browser profile folders | Web cache, cookies, site data | Yes, via browser settings |
/System/Library/Caches | Apple system caches | No |
The user library holds nearly all reclaimable space. The shared folder is smaller and mostly holds content macOS and installer packages manage.
How to check cache size before deleting
Measure first. Blind deletion is how people lose data they meant to keep.
du -sh ~/Library/Caches/* | sort -hr | head -20
du -sh prints a human-readable total per item, sort -hr orders by size, and head -20 shows the twenty largest. Add 2>/dev/null if permission warnings clutter the output. For the shared folder, run the same command with sudo and /Library/Caches.
If one app dominates the list, check whether you still need its cache. A 20 GB cache usually belongs to a browser or a creative tool — clearing it costs a slow next launch, not lost projects.
How to clear app caches
- Quit the apps you intend to clean, including menu bar helpers and background agents.
- Open
~/Library/Cachesin Finder (Go → Go to Folder, then paste the path). - Move the contents to the Trash instead of deleting the folder. Keeping the folder preserves permissions and expectations.
- Empty the Trash once you have confirmed the apps still work.
Browser caches
Clear browser cache from the browser, not from Finder. Safari exposes it under Settings → Privacy → Manage Website Data; Chrome under Settings → Privacy and security → Delete browsing data. Removing browser cache files by hand while the browser is open can corrupt its profile.
Decide separately about cookies. Clearing cached images and files is harmless; clearing cookies signs you out everywhere.
DNS cache
The DNS cache maps hostnames to IP addresses. It is not a file you can browse, and flushing it deletes no data:
sudo dscacheutil -flushcache; sudo killall -HUP mDNSResponder
Use it when a site resolves to the wrong address, after editing /etc/hosts, or when one domain fails while others load. There is no maintenance benefit to running it on a schedule.
What happens after you clear caches
Expect slower first launches while apps rebuild, repeated sign-ins where sessions lived in cache or cookies, and thumbnails repopulating over the following hours.
Space returns gradually. On a machine in daily use, much of what you deleted comes back as the same apps run again. Cache clearing is a temporary reclaim or a fix for stale data, not a strategy for staying below a storage limit.
What not to delete
/System/Library/Caches— Apple-managed system caches; deleting them can break system behavior and is not supported.- The
~/Library/Cachesfolder itself — delete its contents, keep the folder. - Caches of apps that are currently running — quit first.
~/Library/Application Support— this is app data, not cache. Removing it loses projects, profiles and databases.~/Library/Containers— sandboxed app data, including browser profiles and messages.~/Library/Keychains— passwords and certificates.- Xcode
Archives— the only copy of shipped builds, not a cache.
Any sudo rm -rf command with a wildcard deserves a second look. A typo in a path can remove an entire library folder, and there is no undo outside your backups.
How Maclean handles caches
Maclean scans known cache locations and lists them with sizes and risk labels, so you can see what each item is before removing it. It never bulk-deletes ~/Library, excludes protected Apple applications, and moves large items to the Trash so they can be restored.
The free CLI covers the same ground without a GUI:
maclean scan --deep
maclean clean --dry-run
--dry-run prints what would be removed and changes nothing; --json gives machine-readable output, and scheduled runs are available through the app. Maclean is Apache-2.0 licensed, runs on macOS and Windows, and knows more than 60 developer cache types in addition to app caches. All scanning happens on the device — file names and paths are not uploaded.
If you want the full picture rather than one category, start with what Mac System Data contains and how to free up space on a Mac. When an app itself is the problem, uninstalling it with its leftovers removes more than cache ever will.
Bottom line
Clear cache by quitting the app, removing the contents of its cache folder, and letting it rebuild. Skip /System/Library/Caches, keep Application Support and Containers untouched, and expect the space to return. Cache clearing solves stale data and buys temporary room; it does not solve a disk that is genuinely too full.