Transient Cleaner
Clean expired transients from your options table. The original and best! Transient housekeeping was added to the core of WordPress after version 5.8. However, I have decided to open up this plugin to all versions to allow for manual transient cleaning. Longer term I am working on a new version of the plugin, designed specifically for all WordPress releases. Tested up to PHP 8.2 Fully complies with WordPress coding standards Compliant with the stronger WordPress VIP coding standards, as well as compatibility with their platform Community plugin – visit the Github page to get involved with the latest code development, request enhancements and report issues “Transients are a simple and standardized way of storing cached data in the WordPress database temporarily by giving it a custom name and a timeframe after which it will expire and be deleted.” Unfortunately, expired transients only get deleted when you attempt to access them. If you don’t access the transient then, even though it’s expired, WordPress will not remove it. This is a known “issue” but due to reasons, which are explained in the FAQ, this has not been adequately resolved. Why is this a problem? Transients are often used by plugins to “cache” data (my own plugins included). Because of this it means that expired data can be left and build up, resulting in a bloated database table. Meantime, this plugin is the hero that you’ve been waiting for. Simply activate the plugin, sit back and enjoy a much cleaner, smaller options table. It also adds the additional recommendation that after a database upgrade all transients will be cleared down. The Settings Screen Within Administration -> Tools -> Transients an options screen exists allowing you to tweak when you’d like cleaning to happen, including the ability to perform an ad-hoc run, and when you’d like the to be automatically scheduled. You can even request an optimization of the options table to give your system a real “pep”! Running in Lite mode A “lite” mode is available. By activating this the options screen will no longer appear and default settings will be used. The advantage? Improved performance to Admin and, especially if you’re running multi-site, no chance of anybody “tinkering” with the settings. To activate, use the following… define( 'TC_LITE', true ); This should be added to your wp-config.php file. Using hooks If you’re the type of odd person who likes to code for WordPress (really?) then I’ve added a couple of hooks so you can call our rather neat cleaning functions… housekeep_transients – this will clear down any expired transients clear_all_transients – this will remove any and all transients, expired or otherwise Acknowledgements I’d like to thank WordPress Developer Andrew Nacin for his early discussion on this. Also, I’d like to acknowledge the useful article at Everybody Staze for ensuring the proposed solution made sense, and W-Shadow.com for the cleaning code. Iconography is courtesy of the very talented Janki Rathod.
Top keywords
- transients10×2.00%
- wordpress8×1.60%
- expired6×1.20%
- options5×1.00%
- cleaning4×0.80%
- table4×0.80%
- added3×0.60%
- code3×0.60%
- data3×0.60%
- database3×0.60%
- expired transients3×0.60%
- options table3×0.60%
Statixly – Static Site Generator
Statixly converts your WordPress site into a fully static HTML website — eliminating PHP, databases, and server-side dependencies from your production host. The result: faster load times, a reduced attack surface, and the freedom to deploy on any web server or CDN. ⚡ Benefits: Why Statixly? 🚀 Faster page loads: Static websites load 3 to 5 times faster than WordPress sites by serving pre-rendered HTML without PHP execution or database queries. 🔒 Reduced attack surface: Static sites have no login page, database connection, or server-side code on your production host. This eliminates primary attack vectors such as SQL injection and brute-force attacks. 🌍 Deploy anywhere: Host on Cloudflare Pages, GitHub Pages, AWS S3, or any standard web server. No PHP, MySQL, or WordPress dependency is required in production. 💰 Lower hosting costs: Static files can be served from free or low-cost CDN-based hosts instead of a PHP-capable server. Managed WordPress hosting typically costs $25 to $100 or more per month, while static hosting is often free or very affordable on platforms like Cloudflare Pages or Netlify, which offer unmetered bandwidth on their free tiers. 🛠️ Zero production maintenance: Your live site is pure HTML. With no WordPress running in production, there are no security patches, plugin updates, or server-side dependencies to manage on your public host. 🎛️ Live export control: Start, pause, resume, or abort the export from the admin screen and monitor progress in real time. 📦 One-click download: The entire static site is packaged as a ZIP file, ready for extraction and upload. 🔄 Auto-resume on interruption: If internet connectivity drops during export, the job resumes automatically once the connection is restored. 🔍 SEO Benefits 📊 Better Core Web Vitals scores: Static HTML loads faster, directly improving Time to First Byte (TTFB) and Largest Contentful Paint (LCP), which are metrics Google uses as ranking signals. 🤖 Improved crawl efficiency: Search engine bots fetch plain HTML instantly, with no server-side rendering delay. This signals high crawl health and allows engines to index content more effectively. ⏱️ Higher uptime reliability: Static files served from a CDN experience near-zero downtime, helping avoid Google ranking penalties for frequently unreachable URLs. 🧹 No WordPress footprint in production: Common WordPress paths such as /wp-admin and /wp-login.php are removed from the live site, reducing spam crawling and preserving crawl budget. The admin screen provides the following capabilities: Start a static export job Monitor live export status in real time Pause, resume, or abort the export Download the generated static site as a ZIP file Download or delete export logs Delete temporary export directories Statixly systematically crawls website URLs, renders content, rewrites links for static output, and packages the results for deployment. Typical workflow First, build and set up your site as you normally do in WordPress. Make sure all content and settings are finalized before exporting. Next, open the Statixly admin screen and select the Generate/Export Static Site button to start the export process. After the export finishes, download the generated ZIP file containing your static website. Extract the files from the ZIP archive. Upload the extracted files to your chosen static hosting provider. For example, use your website’s document root on a web hosting server, Cloudflare Pages, GitHub Pages, AWS S3, etc. Important Requirements If the current WordPress website is on example.com and you want to make the static website available on example.com as well, move the WordPress website to a subdomain and protect it with HTTP Basic Auth, or move it to your localhost computer using a backup and migration plugin such as Duplicator. Permalink structure must not be set to Plain. Keep the Statixly export tab open while export is running. Not for e-commerce, etc. Statixly will not work on any WordPress website that generates content dynamically based on user interaction, e.g., an e-commerce or subscription-based website. Contact forms will not work. The contact form requires immediate backend processing upon submission by the user. However, this is on our roadmap. HTTP Basic Authentication If your WordPress install is protected with HTTP Basic Auth (for example, a staging or subdomain install), enter your credentials under Statixly → Settings → Security so Statixly can authenticate during export. Credentials are encrypted before storage and never exposed in logs or diagnostics output. Advanced Opt-In Options Statixly includes two optional safety/compatibility flags, both disabled by default and configurable from the Statixly → Settings → General screen. Allow insecure local HTTP fetch Enable this only for expired, invalid, or self-signed certificate environments where same-site HTTPS fetches fail TLS verification. This turns off SSL verification only for local same-site fetches. Prefer temporary storage above document root Enable this only if you explicitly want Statixly working directories outside wp_upload_dir(). By default, Statixly uses WordPress uploads paths. Please note that this option works only if the intended directory is readable and writable by the web server user. Both flags can also be set directly in the options table if preferred. Need Help? If you face any issues after installing the Statixly plugin, please open a support ticket with detailed information, and we will be happy to fix the issue.