# Getting started (/docs/guides/getting-started)

purgeit runs on macOS, Linux and Windows. Via npm it needs **Node.js 22 or newer**; the [standalone binaries](https://github.com/nandan-varma/purgeit/releases) need nothing. Releases are published to npm with [signed provenance](https://docs.npmjs.com/generating-provenance-statements), so you can verify what you run with `npm audit signatures`.

<Steps>
<Step>
### Run it [#run-it]

No install needed:

<Tabs items={["npx","bunx","pnpm","global","binary"]} groupId="pm" persist>
<Tab value="npx">
`npx purgeit ~/dev`
</Tab>

<Tab value="bunx">
`bunx purgeit ~/dev`
</Tab>

<Tab value="pnpm">
`pnpm dlx purgeit ~/dev`
</Tab>

<Tab value="global">
`npm install -g purgeit`, then `purgeit ~/dev`
</Tab>

<Tab value="binary">
No Node needed: download `purgeit-<platform>` for macOS, Linux or Windows from [GitHub Releases](https://github.com/nandan-varma/purgeit/releases) (each release lists `SHA256SUMS`), make it executable, and run it.
</Tab>
</Tabs>

With no directory it scans the current one. Add `--discover` to also scan the places this machine keeps projects (`~/dev`, `~/Projects`, `~/Code`, AI agent worktrees, and any home folder that holds projects).
</Step>

<Step>
### Look around [#look-around]

The [interactive UI](/docs/guides/interactive-ui) fills in as artifacts are measured. Press `space` on what you want gone, `enter` to review, `y` to delete.
</Step>

<Step>
### Or stay in the shell [#or-stay-in-the-shell]

List without changing anything, then clean with a preview first:

<Terminal title="~/dev">
$ purgeit scan ~/dev --min-size 100MB
$ purgeit clean ~/dev --min-size 100MB --dry-run   # runs every check, deletes nothing
$ purgeit clean ~/dev --min-size 100MB             # asks first
</Terminal>
</Step>
</Steps>

## What you are looking at [#what-you-are-looking-at]

`purgeit` lists **projects**, not individual folders:

<Terminal title="~/dev">
$ purgeit scan ~/dev
PROJECT                 SIZE  ITEMS  ACTIVE  ECOSYSTEMS
old-api              1.3 GB      2     4mo  JS/TS
mail                 6.9 GB      1      5m  Rust
pushstack (+1 worktree) 2 GB     5      2m  JS/TS

8 artifacts · 10.2 GB reclaimable — scanned 1 root in 2.1s
1.3 GB of that is in 1 dormant project — `purgeit clean --stale` targets exactly those.
</Terminal>

| Column | Meaning |
| --- | --- |
| **SIZE** | Disk space deleting would free |
| **ITEMS** | Artifacts in the project (`node_modules`, `target`, `.next`, …) |
| **ACTIVE** | When the project was last worked on — from git's log; *dormant* after 30 days |
| **ECOSYSTEMS** | Which tools' output it holds |

Use `--by artifact` for one line per folder, and `purgeit explain <path>` to see exactly why a folder was matched or skipped.

<Callout title="Start with what is dormant" type="idea">
The biggest safe win is output from projects you haven't touched in months. `purgeit clean --stale` targets exactly those, and in the UI `R` selects them.
</Callout>

<Callout title="Safe by default" type="info">
`clean` leaves anything modified in the last **7 days** alone, never deletes without confirmation (or `--yes`), and refuses anything it cannot verify. See [Clean safely](/docs/guides/clean-safely) and the [safety model](/docs/concepts/safety-model).
</Callout>

## Make it yours [#make-it-yours]

```bash
purgeit init                              # a starter purgeit.config.ts
source <(purgeit completion zsh)          # shell completions (bash, zsh, fish)
```

## Next steps [#next-steps]

<Cards>
<Card title="Tour the interactive UI" href="/docs/guides/interactive-ui" />

<Card title="Run purgeit on a schedule" href="/docs/guides/automation" />

<Card title="Add your own rules" href="/docs/guides/custom-rules" />

<Card title="Use it from an AI agent" href="/docs/guides/ai-agents" />
</Cards>