{"id":268375,"date":"2025-12-28T06:32:43","date_gmt":"2025-12-28T06:32:43","guid":{"rendered":"https:\/\/wordpress.org\/plugins\/mega-database-cleanup\/"},"modified":"2026-08-15T10:38:40","modified_gmt":"2026-08-15T10:38:40","slug":"mega-database-cleanup","status":"publish","type":"plugin","link":"https:\/\/hat.wordpress.org\/plugins\/mega-database-cleanup\/","author":23424496,"comment_status":"closed","ping_status":"closed","template":"","meta":{"version":"3.0.0","stable_tag":"3.0.0","tested":"7.1","requires":"6.0","requires_php":"7.4","requires_plugins":null,"header_name":"Mega Database Cleanup","header_author":"MegaWix Technologies","header_description":"Mega \u2014 Full DB cleanup for WordPress. Modern settings UI + ACF\/Empty-meta cleaner + scheduled cleanup + backups. Single-file production-ready version.","assets_banners_color":"020c27","last_updated":"2026-08-15 10:38:40","external_support_url":"","external_repository_url":"","donate_link":"https:\/\/www.megapluginhub.com","header_plugin_uri":"https:\/\/megapluginhub.com\/plugins\/mega-database-cleanup\/","header_author_uri":"https:\/\/megapluginhub.com","rating":0,"author_block_rating":0,"active_installs":0,"downloads":611,"num_ratings":0,"support_threads":0,"support_threads_resolved":0,"author_block_count":0,"sections":["description","installation","faq","changelog"],"tags":{"1.0.0":{"tag":"1.0.0","author":"megawixtech","date":"2025-12-28 06:30:29"},"1.1.0":{"tag":"1.1.0","author":"megawixtech","date":"2026-02-25 17:21:27"},"2.0.0":{"tag":"2.0.0","author":"megawixtech","date":"2026-08-15 10:38:40"},"3.0.0":{"tag":"3.0.0","author":"megawixtech","date":"2026-08-15 10:38:40"}},"upgrade_notice":{"3.0.0":"<p>Major Hub integration update. Enables real-time settings sync from Mega Plugin Hub and license-tier-based feature gating. Recommended for all users.<\/p>","2.0.0":"<p>A major performance and safety upgrade with a new health dashboard, expanded cleanup modules, and a professional modular engine. Recommended for all users.<\/p>","1.1.1":"<p>Critical hotfix that improves PHP compatibility and fixes a bug where the plugin would deactivate itself after an update. Recommended for all users.<\/p>","1.0.0":"<p>Initial release of Mega Database Cleanup.<br \/>\nAdds full database cleanup toolkit with backup, preview, and automated cleanup scheduler.<\/p>"},"ratings":[],"assets_icons":{"icon-128x128.png":{"filename":"icon-128x128.png","revision":3648450,"resolution":"128x128","location":"assets","locale":"","width":128,"height":128},"icon-256x256.png":{"filename":"icon-256x256.png","revision":3648450,"resolution":"256x256","location":"assets","locale":"","width":256,"height":256},"icon.svg":{"filename":"icon.svg","revision":3428489,"resolution":false,"location":"assets","locale":false}},"assets_banners":{"banner-1544x500.png":{"filename":"banner-1544x500.png","revision":3648450,"resolution":"1544x500","location":"assets","locale":"","width":1544,"height":500},"banner-772x250.png":{"filename":"banner-772x250.png","revision":3648450,"resolution":"772x250","location":"assets","locale":"","width":772,"height":250}},"assets_blueprints":{},"all_blocks":[],"tagged_versions":["1.0.0","1.1.0","2.0.0","3.0.0"],"block_files":[],"assets_screenshots":{"screenshot-1.png":{"filename":"screenshot-1.png","revision":3648450,"resolution":"1","location":"assets","locale":"","width":1672,"height":941},"screenshot-2.png":{"filename":"screenshot-2.png","revision":3648450,"resolution":"2","location":"assets","locale":"","width":1672,"height":941},"screenshot-3.png":{"filename":"screenshot-3.png","revision":3648450,"resolution":"3","location":"assets","locale":"","width":1672,"height":941},"screenshot-4.png":{"filename":"screenshot-4.png","revision":3648450,"resolution":"4","location":"assets","locale":"","width":1672,"height":941},"screenshot-5.png":{"filename":"screenshot-5.png","revision":3648450,"resolution":"5","location":"assets","locale":"","width":1672,"height":941},"screenshot-6.png":{"filename":"screenshot-6.png","revision":3648450,"resolution":"6","location":"assets","locale":"","width":1672,"height":941},"screenshot-7.png":{"filename":"screenshot-7.png","revision":3648450,"resolution":"7","location":"assets","locale":"","width":1672,"height":941},"screenshot-8.png":{"filename":"screenshot-8.png","revision":3648450,"resolution":"8","location":"assets","locale":"","width":1672,"height":941}},"screenshots":{"1":"Overview &amp; Health Dashboard - A futuristic real-time control center displaying database health metrics, optimization scores, and automated cleanup activity.","2":"Database Cleanup - Watch our automated system sweep away junk data, orphaned blocks, and bloat to keep your database crystal clean.","3":"Meta Scanner - Advanced scanner detects corrupted metadata, empty blocks, and broken arrays with deep diagnostic filtering.","4":"Auto Cleanup - Set it and forget it! A smart scheduling system runs hands-free automated cleanups to optimize your database around the clock.","5":"Safety Vault - Your data is protected by our secure safety vault, safely storing deleted items before cleanup for easy restoration.","6":"WooCommerce Cleanup - Specifically optimized data flow to clean up expired shopping carts, failed orders, and junk WooCommerce session data.","7":"Hub Sync - Secure cloud API integration that synchronizes your settings and license key directly from the Mega Plugin Hub.","8":"Activity Logs - Comprehensive analytics and monitoring logs to track every optimization and database cleanup action."}},"plugin_section":[],"plugin_tags":[2211,3786,153,187,4672],"plugin_category":[52],"plugin_contributors":[252915],"plugin_business_model":[],"class_list":["post-268375","plugin","type-plugin","status-publish","hentry","plugin_tags-acf","plugin_tags-cleanup","plugin_tags-database","plugin_tags-optimization","plugin_tags-postmeta","plugin_category-performance","plugin_contributors-megawixtech","plugin_committers-megawixtech"],"banners":{"banner":"https:\/\/ps.w.org\/mega-database-cleanup\/assets\/banner-772x250.png?rev=3648450","banner_2x":"https:\/\/ps.w.org\/mega-database-cleanup\/assets\/banner-1544x500.png?rev=3648450","banner_rtl":false,"banner_2x_rtl":false},"icons":{"svg":"https:\/\/ps.w.org\/mega-database-cleanup\/assets\/icon.svg?rev=3428489","icon":"https:\/\/ps.w.org\/mega-database-cleanup\/assets\/icon.svg?rev=3428489","icon_2x":false,"generated":false},"screenshots":[{"src":"https:\/\/ps.w.org\/mega-database-cleanup\/assets\/screenshot-1.png?rev=3648450","caption":"Overview &amp; Health Dashboard - A futuristic real-time control center displaying database health metrics, optimization scores, and automated cleanup activity."},{"src":"https:\/\/ps.w.org\/mega-database-cleanup\/assets\/screenshot-2.png?rev=3648450","caption":"Database Cleanup - Watch our automated system sweep away junk data, orphaned blocks, and bloat to keep your database crystal clean."},{"src":"https:\/\/ps.w.org\/mega-database-cleanup\/assets\/screenshot-3.png?rev=3648450","caption":"Meta Scanner - Advanced scanner detects corrupted metadata, empty blocks, and broken arrays with deep diagnostic filtering."},{"src":"https:\/\/ps.w.org\/mega-database-cleanup\/assets\/screenshot-4.png?rev=3648450","caption":"Auto Cleanup - Set it and forget it! A smart scheduling system runs hands-free automated cleanups to optimize your database around the clock."},{"src":"https:\/\/ps.w.org\/mega-database-cleanup\/assets\/screenshot-5.png?rev=3648450","caption":"Safety Vault - Your data is protected by our secure safety vault, safely storing deleted items before cleanup for easy restoration."},{"src":"https:\/\/ps.w.org\/mega-database-cleanup\/assets\/screenshot-6.png?rev=3648450","caption":"WooCommerce Cleanup - Specifically optimized data flow to clean up expired shopping carts, failed orders, and junk WooCommerce session data."},{"src":"https:\/\/ps.w.org\/mega-database-cleanup\/assets\/screenshot-7.png?rev=3648450","caption":"Hub Sync - Secure cloud API integration that synchronizes your settings and license key directly from the Mega Plugin Hub."},{"src":"https:\/\/ps.w.org\/mega-database-cleanup\/assets\/screenshot-8.png?rev=3648450","caption":"Activity Logs - Comprehensive analytics and monitoring logs to track every optimization and database cleanup action."}],"raw_content":"<!--section=description-->\n<p><strong>Mega Database Cleanup<\/strong> is a modern, high-performance database optimization utility built to remove unused, bloated, and orphaned data from your WordPress database - safely and automatically.<\/p>\n\n<p>Instead of leaving your database cluttered with post revisions, spam, expired transients, and orphaned metadata, this plugin gives you a centralized control center to clean, monitor, and automate your database health. It connects directly to the Mega Plugin Hub dashboard so you can manage all settings remotely without touching your WordPress admin every time.<\/p>\n\n<p>Ideal for site owners, developers, agencies, and power users who want a faster, leaner database without risking important data.<\/p>\n\n<h3>External services<\/h3>\n\n<p>This plugin relies on external third-party services and APIs to provide licensing and settings synchronization features. By using this plugin, you agree to their respective terms and privacy policies:<\/p>\n\n<ol>\n<li>Mega Plugin Hub (https:\/\/api.megapluginhub.com \/ https:\/\/www.megapluginhub.com)\n\n<ul>\n<li><strong>Usage<\/strong>: Used to verify your license key, sync plugin settings, and trigger cleanup actions remotely from the Mega Plugin Hub dashboard.<\/li>\n<li><strong>Data Sent<\/strong>: Sends your license key and plugin settings during sync. No database content or user data is ever transmitted.<\/li>\n<li><strong>Terms &amp; Privacy<\/strong>: Terms of Service: https:\/\/www.megapluginhub.com\/terms-condition\/ , Privacy Policy: https:\/\/www.megapluginhub.com\/privacy-policy\/<\/li>\n<\/ul><\/li>\n<\/ol>\n\n<h4>Highlights<\/h4>\n\n<ul>\n<li><p><strong>Real-Time Health Dashboard<\/strong>\nMonitor your database health score, junk size, overhead, and last cleanup time at a glance from the plugin dashboard.<\/p><\/li>\n<li><p><strong>Targeted Cleanup Modules<\/strong>\nFast, one-click optimization for Post Revisions, Trashed Content, Spam Comments, and Expired Transients.<\/p><\/li>\n<li><p><strong>Empty &amp; Orphaned Meta Scanner<\/strong>\nDetects empty, null, serialized-empty, or JSON-empty metadata across Post, User, Term, and Comment tables.<\/p><\/li>\n<li><p><strong>ACF Cleanup Engine<\/strong>\nAutomatically identifies patterns used by Advanced Custom Fields to detect and remove orphan entries safely.<\/p><\/li>\n<li><p><strong>Automated Background Cleanup<\/strong>\nSchedule automatic cleanups to run hourly, daily, or weekly using WordPress Cron - completely hands-free.<\/p><\/li>\n<li><p><strong>Safety Vault System<\/strong>\nAutomatically secures deleted data in a temporary vault before any cleanup operation for easy recovery.<\/p><\/li>\n<li><p><strong>Snapshot Management<\/strong>\nCreate manual snapshots of your metadata before cleanup and restore them whenever needed.<\/p><\/li>\n<li><p><strong>Hub Settings Sync<\/strong>\nSettings are synced in real-time from the Mega Plugin Hub dashboard via secure webhook with license-key authentication.<\/p><\/li>\n<li><p><strong>WooCommerce Junk Cleaner<\/strong>\nClean expired shop sessions, failed order entries, and abandoned shopping cart records with a single click.<\/p><\/li>\n<li><p><strong>100% Clean Uninstall<\/strong>\nWhen you delete the plugin, all settings, custom tables, and scheduled tasks are cleanly removed from your database.<\/p><\/li>\n<\/ul>\n\n<h4>Who Is This For?<\/h4>\n\n<p><strong>Website Owners<\/strong>\n- Improve site performance by keeping your database lean and fast.<\/p>\n\n<p><strong>Agencies &amp; Developers<\/strong>\n- Manage and automate database cleanup for client sites from one centralized dashboard.<\/p>\n\n<p><strong>WooCommerce Stores<\/strong>\n- Clean up expired sessions, failed orders, and junk data to keep your store running smoothly.<\/p>\n\n<h4>Why Mega Database Cleanup Is Different<\/h4>\n\n<ul>\n<li>Built around a <strong>Hub-Connected Architecture<\/strong> - manage everything from one dashboard<\/li>\n<li><strong>Safety-first design<\/strong> - every cleanup is backed by a vault and snapshot system<\/li>\n<li><strong>No bloat<\/strong> - lightweight plugin that offloads settings management to the cloud<\/li>\n<li><strong>Real-time webhooks<\/strong> - settings sync to your site instantly when you change them in the Hub<\/li>\n<\/ul>\n\n<h3>Privacy Policy<\/h3>\n\n<p>Mega Database Cleanup is committed to transparency regarding user data:<\/p>\n\n<ul>\n<li><strong>No external data transmission<\/strong> - No database content ever leaves your site.<\/li>\n<li><strong>License sync only<\/strong> - Only your license key and plugin settings are sent to Mega Plugin Hub for verification and sync. No user data, posts, or database rows are transmitted.<\/li>\n<li><strong>Database backups<\/strong> - Backup data is stored in a dedicated custom table on your own database server and never sent externally.<\/li>\n<li><strong>Activation popup (optional)<\/strong> - If you enter your email in the welcome popup, it is saved to your site's <code>wp_options<\/code> table only. It is never sent to any third-party server.<\/li>\n<li><strong>Deactivation feedback (optional)<\/strong> - If you submit a deactivation reason, it is saved locally to your site's <code>wp_options<\/code> table. It is never sent externally.<\/li>\n<\/ul>\n\n<h3>Developer Hooks<\/h3>\n\n<h4>Filters<\/h4>\n\n<ul>\n<li><code>mega_db_cleanup_patterns<\/code> - Modify cleanup patterns<\/li>\n<li><code>mega_db_cleanup_retention_limit<\/code> - Change default \"keep latest N\" count<\/li>\n<\/ul>\n\n<h4>Actions<\/h4>\n\n<ul>\n<li><code>mega_db_cleanup_before_delete<\/code> - Fires before deletion<\/li>\n<li><code>mega_db_cleanup_after_delete<\/code> - Fires after deletion<\/li>\n<\/ul>\n\n<h3>Credits<\/h3>\n\n<p>Developed with \u2764\ufe0f by <a href=\"https:\/\/www.megawix.com\/\">MegaWix Technologies<\/a><\/p>\n\n<ul>\n<li>Plugin Development: MegaWix Technologies<\/li>\n<li>Testing &amp; QA: MegaWix Technologies<\/li>\n<\/ul>\n\n<h3>Support<\/h3>\n\n<p>Need help? Have a question or feature request?<\/p>\n\n<ul>\n<li>Website: https:\/\/www.megapluginhub.com<\/li>\n<li>Email: support@megapluginhub.com<\/li>\n<\/ul>\n\n<p>We are committed to providing reliable support and regular updates to ensure this plugin remains compatible with the latest WordPress versions.<\/p>\n\n<!--section=installation-->\n<h4>Automatic Installation<\/h4>\n\n<ol>\n<li>Log in to <strong>WordPress Admin \u2192 Plugins \u2192 Add New<\/strong><\/li>\n<li>Search for <strong>Mega Database Cleanup<\/strong><\/li>\n<li>Click <strong>Install Now<\/strong> \u2192 <strong>Activate<\/strong><\/li>\n<li>Navigate to <strong>Mega Database Cleanup<\/strong> in your WordPress sidebar<\/li>\n<\/ol>\n\n<h4>Manual Installation<\/h4>\n\n<ol>\n<li>Download the plugin ZIP<\/li>\n<li>Go to <strong>Plugins \u2192 Add New \u2192 Upload Plugin<\/strong><\/li>\n<li>Select the ZIP and install<\/li>\n<li>Click <strong>Activate Plugin<\/strong><\/li>\n<\/ol>\n\n<h4>Initial Setup<\/h4>\n\n<ol>\n<li>Open <strong>Mega Database Cleanup<\/strong> from your WordPress sidebar<\/li>\n<li>Enter your Mega Plugin Hub License Key to connect.<\/li>\n<li>Once connected, your settings sync automatically from the Hub dashboard.<\/li>\n<li>Run your first cleanup or enable automated scheduling - your database is now under control!<\/li>\n<\/ol>\n\n<!--section=faq-->\n<dl>\n<dt id=\"is%20it%20safe%20to%20use%20on%20a%20live%2Fproduction%20site%3F\"><h3>Is it safe to use on a live\/production site?<\/h3><\/dt>\n<dd><p>Yes. Mega Database Cleanup is designed with safety as the top priority. Before any cleanup operation, data is stored in the Safety Vault. You can also create manual snapshots at any time. We strongly recommend running a full backup before enabling aggressive cleanup rules on a production site.<\/p><\/dd>\n<dt id=\"will%20it%20delete%20content%20i%20still%20need%3F\"><h3>Will it delete content I still need?<\/h3><\/dt>\n<dd><p>No. The plugin only removes data that WordPress itself considers orphaned or junk - such as expired transients, spam comments, and post revisions. Your published content, pages, products, and user data are never touched.<\/p><\/dd>\n<dt id=\"how%20does%20hub%20settings%20sync%20work%3F\"><h3>How does Hub Settings Sync work?<\/h3><\/dt>\n<dd><p>When you update settings in your Mega Plugin Hub dashboard, a secure webhook is sent to your WordPress site with your license key in the request header. The plugin verifies the key and applies the new settings instantly - no manual saving required on the WP side.<\/p><\/dd>\n<dt id=\"what%20is%20the%20safety%20vault%3F\"><h3>What is the Safety Vault?<\/h3><\/dt>\n<dd><p>Before any cleanup runs, deleted metadata is stored in a dedicated custom table on your own server. You can view and restore this data from the plugin's Snapshot Manager tab. The vault is completely private and never leaves your server.<\/p><\/dd>\n<dt id=\"how%20safe%20is%20the%20automated%20cleanup%20scheduler%3F\"><h3>How safe is the automated cleanup scheduler?<\/h3><\/dt>\n<dd><p>Very safe - it follows the same rules as manual cleanup, including retention rules, vault backup, and license-tier checks.<\/p><\/dd>\n<dt id=\"what%20happens%20if%20i%20deactivate%20or%20uninstall%20the%20plugin%3F\"><h3>What happens if I deactivate or uninstall the plugin?<\/h3><\/dt>\n<dd><p>Deactivating the plugin pauses all scheduled cleanups. Uninstalling it completely removes all settings, custom tables, and cron jobs from your database, leaving no trace behind.<\/p><\/dd>\n\n<\/dl>\n\n<!--section=changelog-->\n<h4>3.0.0<\/h4>\n\n<ul>\n<li>New: Real-time Settings Sync via Mega Plugin Hub webhook integration.<\/li>\n<li>New: Secure <code>X-Mega-License<\/code> header authentication for all Hub communications.<\/li>\n<li>Improved: Modular settings architecture with per-setting toggle persistence.<\/li>\n<li>Improved: Background cleanup actions now report status back to Hub dashboard.<\/li>\n<li>Fixed: Settings not persisting correctly across plugin updates.<\/li>\n<\/ul>\n\n<h4>2.0.0<\/h4>\n\n<ul>\n<li>Major Overhaul: Completely redesigned modular class-based architecture.<\/li>\n<li>New: Health Score Dashboard with real-time database diagnostics.<\/li>\n<li>New: Support for User, Term, and Comment metadata cleanup.<\/li>\n<li>New: Targeted cleanup modules for Revisions, Trash, Spam, and Transients.<\/li>\n<li>New: Safety Vault system to temporarily secure deleted data.<\/li>\n<li>New: Metadata Snapshot system for manual backups and restoration.<\/li>\n<li>New: Modern tabbed UI with improved user experience.<\/li>\n<\/ul>\n\n<h4>1.1.1<\/h4>\n\n<ul>\n<li>Fixed: Critical PHP compatibility issue by replacing modern arrow functions with traditional anonymous functions, ensuring support for older server environments.<\/li>\n<li>Fixed: Resolved a glitch that caused plugin deactivation during the update process due to script execution timeouts on some servers.<\/li>\n<li>Improved: Better handling of plugin state during version transitions.<\/li>\n<\/ul>\n\n<h4>1.1.0<\/h4>\n\n<ul>\n<li>Added optional activation popup: subscribe to plugin update tips (email stored locally only)<\/li>\n<li>Added deactivation feedback popup: 6 selectable reasons + custom text (stored locally only)<\/li>\n<li>Plugin now appears as a top-level menu item in the WordPress sidebar<\/li>\n<li>Quick-access link added to the WordPress admin bar (header)<\/li>\n<li>All new features are fully WordPress.org compliant<\/li>\n<\/ul>\n\n<h4>1.0.0 - Initial Release<\/h4>\n\n<ul>\n<li>Empty meta scanner and preview mode<\/li>\n<li>ACF orphan cleanup with pattern-based detection<\/li>\n<li>Scheduled automatic cleanup (hourly\/daily\/weekly)<\/li>\n<li>Backup table to store deleted meta rows<\/li>\n<li>Retention rule: keep latest N entries per meta_key<\/li>\n<li>One-click delete all empty metadata<\/li>\n<li>Add\/remove ACF patterns<\/li>\n<li>Inline logs and real-time reports<\/li>\n<li>Fully optimized SQL cleanup<\/li>\n<li>Admin UI with jQuery enhancements<\/li>\n<\/ul>","raw_excerpt":"The ultimate WordPress database optimization suite with real-time health monitoring, automated cleanup, meta scanning, and Mega Plugin Hub sync.","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/hat.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin\/268375","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/hat.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin"}],"about":[{"href":"https:\/\/hat.wordpress.org\/plugins\/wp-json\/wp\/v2\/types\/plugin"}],"replies":[{"embeddable":true,"href":"https:\/\/hat.wordpress.org\/plugins\/wp-json\/wp\/v2\/comments?post=268375"}],"author":[{"embeddable":true,"href":"https:\/\/hat.wordpress.org\/plugins\/wp-json\/wporg\/v1\/users\/megawixtech"}],"wp:attachment":[{"href":"https:\/\/hat.wordpress.org\/plugins\/wp-json\/wp\/v2\/media?parent=268375"}],"wp:term":[{"taxonomy":"plugin_section","embeddable":true,"href":"https:\/\/hat.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_section?post=268375"},{"taxonomy":"plugin_tags","embeddable":true,"href":"https:\/\/hat.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_tags?post=268375"},{"taxonomy":"plugin_category","embeddable":true,"href":"https:\/\/hat.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_category?post=268375"},{"taxonomy":"plugin_contributors","embeddable":true,"href":"https:\/\/hat.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_contributors?post=268375"},{"taxonomy":"plugin_business_model","embeddable":true,"href":"https:\/\/hat.wordpress.org\/plugins\/wp-json\/wp\/v2\/plugin_business_model?post=268375"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}