How to Manually Deactivate WordPress Plugins

Last updated on August 22nd, 2019 by Mark Grima. Filed under WordPress Admin Tips

Plugins are a great aspect of using WordPress. However, at some point, you’ll need to uninstall or deactivate a plugin for one reason or another. This might present a problem, in that, the default method for deactivating WordPress plugins might not be always available.

For example, to fix an issue where you lose access to your WordPress dashboard because of an internal server error or plugin conflict, you’d need to manually disable one or more plugins. However, without access to the dashboard, you could only do so using a manual approach.

In this article, we’ll highlight the differences between regular and manual plugin deactivation. Then we’ll show you three ways to manually deactivate WordPress plugins.

The simplest way to manually deactivate a WordPress plugin

Before we start digging into your website’s back end, let’s see how to deactivate WordPress plugins when you do have access to the dashboard. Simply navigate to the Plugins tab, where you’ll find a list of installed plugins:

List of installed plugins on a WordPress website

Find the plugin you want to deactivate and click Deactivate. As an example, in the below screenshot we are highlighting the Deactivate of the plugin Classic Editor:

Deactivating a WordPress plugin
Once you click Deactivate, WordPress will deactivate the plugin. Note that a deactivated plugin will still be installed on your site. If you wish to delete it altogether (you should delete every plugin you are not using), you can do so from the same page.

3 ways to manually deactivate WordPress plugins without admin access

If you lose access to your WordPress admin pages for any reason, there are still several ways you can deactivate your plugins. Let’s run through them, starting with the easiest one.

1. Rename your plugin’s folder via SFTP or SSH

Deactivating a single plugin

When you rename the plugin’s folder on a WordPress website, that plugin is deactivated. You can access your website’s files via Secure File Transfer Protocol (SFTP) or Secure Shell (SSH). In this example we explain how you can rename your plugin’s folder using SFTP.

Firstly, you need a FTP client to access your website’s files. We use and recommend FileZilla, a free and very reliable FTP client. Refer to the tutorial how to use FTP to transfer files to WordPress for details of how to access your website’s files.

Once you connect to your website via SFTP, you can access your WordPress root directory, which is where all your website’s files reside:

The files of your WordPress website

Navigate to the wp-content/plugins folder. The plugins folder is where all the plugins files are store on your website. Inside, you’ll find a unique directory for each of both inactive and active plugins on your website. Deleting any of these folders can cause problems, so we don’t recommend you take this path.

Instead, rename the folder for the plugin you want to disable. Change its name to anything you like. In the below screenshot we renamed the classic-editor folder name to classic-editor-deactivated. This will automatically deactivate the plugin.

Renamed plugin folder

To reactivate the plugin revert the folder to its original name and activate it from the plugin’s page in the WordPress dashboard.

Deactivating all plugins

If you have a problem on your website but not sure which plugin it is, disable all the plugins by renaming the directory where the plugins are installed: /wp-content/plugins/. Once you regain access to your WordPress dashboard, rename the plugins folder to plugins and activate the plugins one by one until you reproduce the problem. At which point you know which is the problematic plugin.

2. Deactivating all plugins from the WordPress database

WordPress stores practically all of the website’s information in its database. Therefore you can also disable plugins from the database. It is a fairly painless process. Use a tool such as phpMyAdmin in your web host’s control panel to access the database.

Web host database tools

Once you connect you can see the databases you have access to. If you have more than one website you will see a list of databases. Click on the database that corresponds to your website from the list to the left. Then click on the wp_options table (note that the wp_ prefix in the table names could vary ) to browse the data inside it:

WordPress database tables in phpMyAdmin

 

Search for the active_plugins option name. The option name gives you a clue as to what it contains:

Search in the WordPress database

Once you find the row, click the Edit button. A new page with multiple fields will open, one of which is called option_value. In it you will see a list of installed plugins. Change the value to a:0:{} to deactivate all plugins. Click Go to change the settings.

Changing the value of an option in the database

3. Deactivate Plugins Using the WordPress Command Line (WP-CLI)

For the uninitiated, WP-CLI is a tool that provides a command line interface  for WordPress websites. Some web hosts offer WP-CLI as a pre-installed feature. If not, you can set it up manually if you have Secure Shell (SSH) access and are able to log into your WordPress back end.

You can use WP-CLI to do a lot of admin tasks on WordPress, one of which is to disable WordPress plugins. Start with listing all the installed plugins on your website by using the wp plugin list command:

Using the wp plugins list command

 

 

To deactivate a single plugin, use the wp plugin deactivate command.  So to deactivate the classic-editor plugin use the following command: wp plugin deactivate classic-editor. If the process is successful, WP-CLI will show you a message to let you know the plugin has been disabled.

Deactivating a plugin with WP-CLI

You can also deactivate all the installed plugins on your WordPress website with the command wp plugin deactivate –all.

A Quick Recap on WordPress Manual Plugins Deactivation

Usually, disabling plugins in WordPress is a straightforward procedure. However, there will be times when you won’t have access to your dashboard. That’s where knowing how to manually deactivate plugins come in handy. Best of all, it’s not as complicated as you’d think.

Here are the three ways you can go about deactivating plugins manually:

  1. Renaming your plugin(s) directory.
  2. Disabling plugins from the WordPress database.
  3. Using the WP-CLI.

WordPress Hosting, Firewall and Backup

This Website is:

Leave a Reply

Your email address will not be published. Required fields are marked *