Bundle$29.99/yr

BroomDisk space analyzer and cleanerDrippyNetwork usage in your menu barBuckyDownload manager

More apps

Batch File RenamerRename hundreds of files at onceCapzAnimated captions for any videoTorrieFree, open source torrent client

Find and delete every node_modules folder

Every JavaScript project you've ever cloned left a node_modules behind. Rust leaves target, Python leaves .venv. Together they're often the biggest thing on a developer's disk.

The Terminal way

find ~ -name node_modules -type d -prune lists them, and adding -exec rm -rf {} + deletes them. It works, but it deletes permanently and doesn't check whether the folder belongs to a real project.

The Broom way

Broom finds build folders during its normal scan and only offers one when the project file that recreates it is still next to it. So node_modules needs a package.json beside it, target needs Cargo.toml, Pods needs a Podfile. Each item tells you the command that brings it back.

Build folders Broom recognizes

  • node_modules, .next, .nuxt, .turbo, .svelte-kit, .parcel-cache, .angular
  • target (Rust), .build (Swift), Pods (CocoaPods)
  • build and .gradle (Gradle, CMake, Flutter), .dart_tool
  • .venv and venv (Python)

Package manager caches too

Homebrew, npm, Cargo, pip and Gradle keep every download they've ever made. Broom lists those caches with their sizes alongside the build folders.

Questions

Is it safe to delete node_modules?

Yes, if you still have the package.json and lockfile. Run npm install (or your package manager's install) to bring it back.

How much space do node_modules folders take?

A single project is commonly 200 MB to 1 GB. A few dozen old projects can easily add up to tens of GB.

Will Broom touch my Git repositories?

It only offers the rebuildable build folder inside a project, never your source files, and everything goes to the Trash first.

Download Broom

Download for macOS