Description
SweepPress is an easy-to-use WordPress plugin built around 43 different Sweepers for database cleanup (the Pro version has 46), support for WP-CLI, and WP REST API to perform the cleanup operations. The plugin also features a powerful WordPress Options database table management panel.
Quick Video Overview
Options Management
The WordPress Options database table holds settings for WordPress Core, all the plugins, and themes. This table can grow significantly, especially since records are not auto-deleted when removing a plugin or theme. SweepPress has Sweepers that deal with transient cache records (stored in this table), and now, since version 3.0, it has a full Management panel where you can see all the records in the Options
table, detect source for the record and status to help you decide if you should delete the record or not.
SweepPress has two methods to detect the source of the record, and it will mark all the recognized records. This panel doesn’t show transient records (used for cache) or WordPress options (deleting these options is a terrible idea).
Options deletion process is not automatic! No matter how precise options usage detection is, you need to verify and confirm that you want to delete one or more records.
SweepPress Pro It also has advanced management panels for all the WordPress metadata and multisite Sitemeta database tables.
Modes of Sweeping
- Auto Sweep: available on the dashboard, running many (not all) sweepers without user input.
- Quick Sweep: available on the dashboard, allowing the sweepers to be selected.
- Full Sweep: available on its panel, with detailed information about sweepers and no limit run.
- CLI Sweep: the plugin supports WP-CLI and adds commands to run all the sweepers with the command line.
- REST API Sweep: the plugin supports WP REST API and allows sweeping via the new REST endpoints.
All sweepers use optimized SQL queries to find the data for removal, which is also done using SQL queries. This is the fastest and most efficient way to remove a large amount of data quickly.
List of Sweepers
- Posts: Auto Drafts
- Posts: Spam Content
- Posts: Trashed Content
- Posts: Posts Revisions
- Posts: Posts Orphaned Revisions
- Posts: Draft Posts Revisions
- Posts: Postmeta Locks
- Posts: Postmeta Last Edits
- Posts: Postmeta Oembeds
- Posts: Postmeta Old Data
- Posts: Postmeta Orphans
- Comments: Spam Comments
- Comments: Trashed Comments
- Comments: Unapproved Comments
- Comments: Orphaned Comments
- Comments: Comments User Agents
- Comments: Commentmeta Orphans
- Comments: Pingbacks Cleanup
- Comments: Trackbacks Cleanup
- Comments: Akismet Meta Records
- Terms: Terms Orphans
- Terms: Termmeta Orphans
- Terms: AMP Validation Errors
- Users: Usermeta Orphans
- Options: Expired Transients
- Options: RSS Feeds
- Options: All Transients
- Options: CRON Jobs
- Options: Unhooked CRON Jobs
- Network: Expired Transients
- Network: All Transients
- Network: Inactive Signups
- Database: Optimize Database Tables
- Database: Repair Database Tables
- ActionScheduler: Log Entries
- ActionScheduler: Orphaned Log Entries
- ActionScheduler: Failed Actions
- ActionScheduler: Completed Actions
- ActionScheduler: Canceled Actions
- BuddyPress: Activity Meta Orphans
- BuddyPress: Groups Meta Orphans
- BuddyPress: Messages Meta Orphans
- BuddyPress: Notifications Meta Orphans
WP-CLI and WP REST API Support
The plugin registers new CLI commands for running sweep operations from the command line (WP-CLI is required). It also registers the REST API endpoint for the same purpose: running remote sweep operations (only for the administrator role!). CLI and REST API support can be enabled through plugin settings.
Action Scheduler Support
The plugin can clean up the ActionScheduler tables. These tables are used by the Action Schedule plugin and components developed for WooCommerce but also in many other WordPress plugins, including WP Rocket and Rank Math. For these sweepers to be visible, at least one plugin using those tables needs to be active.
Additional Features
- Sweeper File Log: log every sweeper execution into a log file with all sweeper/removal SQL queries executed by each used sweeper.
Special Notice
The plugin will show the backup reminder notice by default (and it can be disabled) on every page. It is essential to understand that once the plugin deletes data, it can’t be restored. So, if you change your mind later, it is important to make the backup before the data removal. The sweepPress plugin is not responsible for any data loss — ensure backups!
Plugin Home Page
- Learn more about the plugin: SweepPress Home Page
- Plugin knowledge base: SweepPress on Dev4Press
- Support for the Lite version: Support Forum on Dev4Press
SweepPress Pro
SweepPress Lite edition, available on WordPress.org, is a fully functional plugin with no limits to its operations. But SweepPress Pro contains a lot of additional features not available in the Lite version:
- Management for ALL the WordPress Metadata tables: supports
postmeta
,termmeta
,commentmeta
,usermeta
andblogmeta
. - Management for the WordPress Multisite Sitemeta table: this table is equivalent of the Options table, but for all the blogs in the multisite.
- Create and manage Sweeper Jobs: create custom background sweeper jobs to run at a specific date or as a recurring job.
- Control and track WordPress CRON jobs: list all the WordPress CRON jobs, track and display the source, and more.
- Sweeper Monitor: monitor the website for cleanup daily or weekly, and send notifications when the sweeping limit is reached.
- Database Tables: an overview of all tables in the database with source information and various actions for better control.
- GravityForms Support: three additional sweepers to remove all trashed forms, spammed, and trash entries by form.
- CLI Command to list CRON jobs: list all registered WP CRON jobs via the command line
Future updates will include more exclusive Pro features.
Screenshots
Installation
General Requirements
- PHP: 7.4 or newer
PHP Notice
- The plugin doesn’t work with PHP 7.4 or older versions.
WordPress Requirements
- WordPress: 5.9 or newer
Basic Installation
- Plugin folder in the WordPress plugins should be
sweeppress
. - Upload the
sweeppress
folder to the/wp-content/plugins/
directory. - Activate the plugin through the ‘Plugins’ menu in WordPress.
- Plugin adds a new top-level menu called ‘SweepPress.’
- Check all the plugin settings before using the plugin.
FAQ
-
Where can I configure the plugin?
-
The plugin adds a top-level ‘SweepPress’ panel in the WordPress Admin menu.
Reviews
Contributors & Developers
“SweepPress: Website Cleanup and Optimization” is open source software. The following people have contributed to this plugin.
Contributors“SweepPress: Website Cleanup and Optimization” has been translated into 1 locale. Thank you to the translators for their contributions.
Translate “SweepPress: Website Cleanup and Optimization” into your language.
Interested in development?
Browse the code, check out the SVN repository, or subscribe to the development log by RSS.
Changelog
Version: 5.5 (2024.09.19)
- New: sweep panel option to clear estimation cache
- New: for each sweeper shows
Refresh
link to reload - New: show the limit of the days to keep for affected sweepers
- Edit: many improvements to the PHP code structure
- Edit: few optimizations in the main JavaScript file
Version: 5.4.0.1 (2024.09.10)
- Edit: updated Library font CSS file
Version: 5.4 (2024.09.02)
- New: tested and compatible with
PHP
8.4 Beta 4 - New: many major changes to the code organization
- New: sweeper log feature now available in the lite edition
- New: non-licensed installation works as a lite edition
- Edit: updated some plugin system requirements
- Edit: improvements to the license handling for Pro features
- Edit: many updates related to the
Library
changes - Edit: Dev4Press Library 5.1
Full changelog: SweepPress Changelog