pnpm store prune: Usage & Common Errors
Reclaim disk by pruning the pnpm store.
pnpm store prune deletes packages from the global content-addressable store that are no longer referenced by any project - the way to reclaim disk without breaking installs.
What it does
Removes store entries with no remaining hard links from any project. Because the store is content-addressable and shared, only truly orphaned packages are deleted, so active projects are unaffected. pnpm store status reports what would change.
Common usage
pnpm store prune # remove orphaned packages
pnpm store status # check store integrity
pnpm store path # print the store locationCommon CI pattern: free disk on no-space-left
A self-hosted runner fills its disk over many builds because the pnpm store grows unbounded. Run pnpm store prune in a cleanup step (or periodically) to drop orphaned packages - far safer than deleting the whole store, which forces every project to re-fetch.
pnpm store prune # reclaim disk between builds