pip, conda, npm, .gradle, .cargo caches — are they safe to clear?
Short answer: yes. Every package manager keeps a download cache so it doesn't refetch the same package twice. They're pure caches — clearing one just means the next install re-downloads what it needs. On a dev machine they routinely add up to 5–20 GB.
Where each cache lives (Windows) and how to clear it
pip
Cache: %LOCALAPPDATA%\pip\Cache — often several GB thanks to large CUDA/torch wheels.
pip cache info # see the size
pip cache purge # clear it
conda
Cache: C:\Users\you\.conda\pkgs (or your Anaconda pkgs dir).
conda clean --all
npm / yarn / pnpm
npm: %LOCALAPPDATA%\npm-cache. yarn: %LOCALAPPDATA%\Yarn\Cache. pnpm keeps a global store.
npm cache clean --force
yarn cache clean
pnpm store prune
Gradle
Cache: C:\Users\you\.gradle\caches — one of the biggest offenders for Android/JVM devs.
# safe to delete; Gradle rebuilds it on next build
Remove-Item "$env:USERPROFILE\.gradle\caches" -Recurse -Force
Cargo (Rust)
Registry + git caches: C:\Users\you\.cargo\registry and .cargo\git.
cargo cache -a # needs: cargo install cargo-cache
# or delete .cargo\registry\cache manually
NuGet (.NET)
dotnet nuget locals all --clear
Instead of running seven commands, SweepDisk finds every package cache across your drives, totals them, and moves the ones you pick to the Recycle Bin.
When not to bother
If you build the same projects daily, a warm cache speeds you up — clearing it just to reclaim a couple of GB you'll refill tomorrow isn't worth it. Target the caches from tools and languages you no longer use: the Gradle cache from that one Android experiment, conda envs from a finished course, the Rust registry from a project you shipped a year ago.
Free categorized scan for Windows 10 & 11 — sizes, safety confidence, and one-click cleanup to the Recycle Bin.