# rimraf

> rm -rf for Node.js, cross-platform

Source: https://talira.ai/catalog/rimraf-dg86ye06
Every listing: https://talira.ai/catalog.md

- Kind: Open source
- Types: Library, Command-line tool
- Categories: [libraries / javascript / utilities](https://talira.ai/categories/libraries/javascript/utilities), [languages / javascript](https://talira.ai/categories/languages/javascript)
- Licence: BlueOak-1.0.0[^2]
- Pricing: Free and open source[^2]
- Pricing notes: Free and open source.
- Free tier: yes[^2]
- Backed by: [Isaac Z. Schlueter](https://talira.ai/orgs/isaacs.md)

rimraf is the Unix rm -rf command for Node.js in a cross-platform implementation: a library (async with promises, sync, and native variants) and a command-line tool that delete files and directories recursively. On Windows it retries with exponential backoff on EBUSY, EMFILE and ENFILE errors and falls back to a move-then-remove strategy, and it supports glob patterns (with the glob option), an AbortSignal to cancel, and protection against deleting the filesystem root. Its README warns never to pass it untrusted input.

## Links

- GitHub: https://github.com/isaacs/rimraf

## Problems it solves

- delete a directory recursively in an npm script on Windows and macOS alike
- remove a build folder from Node.js without shelling out to rm -rf
- clean up files that Windows reports as busy when deleting from Node
- delete files matching a glob pattern from a Node script

## Features

- async, sync and native APIs
- CLI for npm scripts
- Windows retries with backoff and move-then-remove fallback
- glob patterns
- AbortSignal support
- root deletion protection

## Limitations

- Deletes recursively by design: never pass it untrusted input, and security reports that rely on untrusted input are rejected[^1]

## Capabilities

- Has a command line tool: plan not known

## Trust

Overall: 0.54 out of 1.
Signals: maintenance 0.62, adoption 0.75, momentum 0.45, community 0.62, backing 0.30, extensibility 0.20.

- last commit 21 days ago
- 3 commits in the last 90 days
- 5.9k GitHub stars
- 34 contributors
- accepts sponsorship (Github)
- backed by Isaac Z. Schlueter

## Sources

[^1]: https://github.com/isaacs/rimraf (checked 23 Nov 2026)
[^2]: https://github.com/isaacs/rimraf/blob/main/LICENSE.md (checked 23 Nov 2026)
