WP Upload Cleaner
Find and safely remove orphaned files from wp-content/uploads. Preview in admin or run via WP-CLI.
Install
This is the repository archive. It installs, but the folder name will carry the branch suffix and updates will not flow.
Install straight from GitHub with WP-CLI:
wp plugin install https://github.com/bestwebsite-legacy/wp-upload-cleaner/archive/refs/heads/master.zip
WP Upload Cleaner
Find and safely remove orphaned files from wp-content/uploads.
When sites are migrated, rebuilt, or heavily edited over time, the uploads folder collects files that are no longer referenced by any media attachment. This plugin scans for those orphaned files, lets you preview them in the dashboard, and delete safely — or automate via WP‑CLI.
Features
- Scan
uploads/for files not referenced by any attachment - Preview results in Tools → Upload Cleaner
- Delete selected files or Delete All from the last scan
- WP‑CLI:
scan,delete_all,delete <path> - Safety checks ensure deletions stay inside the uploads directory
Installation
- Upload
wp-upload-cleanerto/wp-content/plugins/ - Activate via Plugins
- Go to Tools → Upload Cleaner
WP‑CLI
wp upload-cleaner scan --format=table
wp upload-cleaner delete_all --yes
wp upload-cleaner delete 2025/01/old-image.jpg
Author
Built and maintained by Best Website — https://bestwebsite.com
Contact: support@bestwebsite.com
License
GPL‑2.0 or later
Releases
1 release.
These releases are tags only. The author does not attach a packaged zip, so there are no download counts to report.