It is always good practice for WordPress administrators to be very selective when it comes to installing plugins on their WordPress website. Having a wide-range of 3rd party WordPress plugins installed, developed by a varied range of authors, can often cause minor conflictions between them.
This can lead to a variety of issues for both administrators and visitors alike. So it’s a good idea to sweep through your active plugin collection regularly to get rid of any dead wood. Let’s have a look at some steps you can follow to completely remove all traces of deactivated WordPress plugins.
Plugin Leftovers in Database: Removing Database Tables
In general, when a WordPress plugin is deleted, it should be tidying up after itself. That is for example removing any tables it may have added to your WordPress database. Unfortunately not all plugins adhere to this unwritten rule. In fact some of them are leaving behind a trail of information related to the deactivated WordPress plugin. This can clog up your tidy database after a while.
Using the tools available to you provided by your hosting or server provider, you can get rid of this unwanted data with ease using phpMyAdmin. Once logged in, open your WordPress database by clicking on it. There you will be presented with a series of tables that contain your WordPress data.
By default, WordPress database tables are prefixed with wp_. Any other tables that are prefixed differently will be related to your plugins or else. Typically, if a plugin is adding tables to your database it will prefix these tables with a unique identifier that will relate to the plugin name. This allows you to quickly identify them for deletion. For example, instead of tables being prefixed with wp_ they may be prefixed with a different identifier relevant to the plugin name, such as ga_ or else.
Database Maintenance: Backing Up and Optimization
Ensure you always have an up to date backup of your database should anything unexpected happen. You are directly modifying the database that your WordPress site relies on to function correctly. Any mistakes made without having a backup to fallback upon could cause you a loss of data. There are a handful of popular backup plugins available that can help you make backups of your database. Also, further optimize tables and backup your WordPress contents directly from your dashboard.
- WP-Optimize is a very popular backup plugin that will help you keep your database clean by removing any redundant tables, spam comments and trash posts, plus much more. You can also create backup schedules that will create timed database backups automatically for you.
- WP-DB-Backup is another quite popular and lightweight plugin with almost half-a-million active installations. It allows you to backup your WordPress core database tables with ease.
- WP-Sweep is also a trusted solution that will clean-up your data, and optimize your database tables for a squeaky clean WordPress installation. Using a simple interface, this WordPress backup plugin will sweep through your sites’ contents, removing any redundant items such as old post revisions, drafts, terms, and a variety of comment and meta information.
Plugin Leftovers on Server: Removing Files and Folders
Deactivated or deleted WordPress plugins may also be leaving behind files and folders within your WordPress installation. These files and folders are no longer needed and can therefore be safely deleted. In addition, if you’ve previously used a WordPress caching plugin and remove it, then it is likely that you will also need to manually remove the folder where the cache is being stored.
Typically, cache folders are kept within your wp-content folder. Yet, some WordPress caching plugins do store their cache in other locations such as your root folder. You can access the folders and files on your server using either an FTP client or File Manager software provided to you by your hosting or server provider, such as cPanel and Plesk.
Conclusion: Cleaning up after WordPress Plugins
In general, most WordPress plugins will have been developed to carry out some clean-up duties after deactivation. That way they ensure nothing is left behind should you decide to no longer use certain plugins. The steps above will help you remove any unwanted data left behind by those plugins that don’t carry out these clean-up tasks. This will help maintaining a speedy, tidy WordPress website.
It is recommended to be selective in the amount of WordPress plugins you have installed on your WordPress website. That will help you keep a clean WordPress installation which will not only be error-free for you within the WordPress dashboard, but also for your valuable website visitors.