There are some times when we need to hide specific plugin from our client. When a plugin control very important and sensitive site settings and playing with it can affect website functionality and appearance, it will be better to hide the plugin from your client (even when he/she is an administrator).

Is there any plugin to hide a plugin from installed plugin list?

And my answer is “Yes”. There is a perfect plugin to hide any plugin from all other users even when they have administrator privileges. This plugin is very useful and it prevents your client from seeing and deactivating the plugin that you hide.

How to use the plugin

  • It is very easy to use this plugin. First install the plugin and activate it. This plugin is visible only to the administrator who activates it.

  • On activating the plugin, you will see an additional “Hide” link after “Delete” link for every plugin on installed plugin page

  • “Hide Plugin” will remain hidden for all other WordPress users even when they are site administrators
  • When you click on Hide button for any installed plugin, that plugin will be disappeared for all other users and for you that plugin will remain visible but with a “Show Button” instead. You can make the plugin visible again any time clicking on the “Show” link

Advantage of using Hide Plugins

Hide Plugins has an edge over using custom code to hide some plugins from plugin list. If you hide a plugin using a custom function, it will hide the plugin from you too and this way plugin will become unavailable for you too to update or deactivate that plugin.

Hiding plugins using custom code

You can also hide one or more plugins from plugin list adding a custom php function to WordPress theme function file. But I recommend you to add this function or any other custom function using “My Custom Functions” plugin. This plugin saves your custom PHP code to database and it will not be lost on updating or changing the theme. Add the following code to theme function file or in “My Custom Function” plugin

function secret_plugin_webcusp() {
global $wp_list_table;
$hidearr = array(‘my-custom-functions/my-custom-functions.php‘,’user-role-editor/user-role-editor.php‘ );
$myplugins = $wp_list_table->items;
foreach ($myplugins as $key => $val) {
if (in_array($key,$hidearr)) {
unset($wp_list_table->items[$key]);
}
}
}add_action(‘pre_current_active_plugins’, ‘secret_plugin_webcusp’);

In 3rd line of code, you can add the plugin main php file link and in the same way you can add multiple plugins

Video Tutorial

About Shams

Shams, a professional blogger, has expertise in WordPress and Web Hosting. He is used to playing around with WordPress plugins, themes, web hosting services and some other innovative stuff regarding web design. He sifts out good stuff for web designers and reviews it to help them choose what they really need.

Being an energetic tech enthusiast, he regularly pens down breaking news and tutorials related to technology particularly Smartphones and other gadgets. Sometimes writes tech tips too. It was the dawn of Internet age when he started dabbling in it and has since been delving into the realm of the internet. He occupies a permanent burrow in virtual world.

He can be reached at.- here

Related Post