Disable plugin update notification for specific plugin in WordPress

The major WordPress plugins get updated on regular basis and we often login to the WordPress dashboard and notice notification for one or more plugin updates. If we ignore these updates, these notifications can pile up.

It is strongly recommended to update the WordPress plugins always to the latest versions. 

Now, think differently, if the website developer has some customization done in the plugin core file. So, if the plugin get updated, all the customized work will be gone away and your website may not work as per the previous customized version. If we can disable the specif plugin update notification, then there will be no chance to update the plugin.

There are 2 common ways to do disable specific plugin update notification.

Option 1 (Preferred):

Open the main PHP file of the plugin and just below the plugin header put the following code.

// Stop Plugin Updates
add_filter('site_transient_update_plugins', 'remove_update_notification');
function remove_update_notification($value) {
 unset($value->response[ plugin_basename(__FILE__) ]);
 return $value;
}
plugin-code-screenshot

Restriction: the name of the function (remove_update_notification) is unique. You can not add the same function in different plugins to disable update notifications. If you want to disable for multiple plugins then you have to change the function name different in different plugins.
Option 2:

Get the folder and main file name of the specific plugin and put the following code in the ‘functions.php’ file of your theme.

function filter_plugin_updates( $value ) {
 // Replace the plugin folder name and main file name with your plugin's folder and file name
 unset( $value->response['akismet/akismet.php'] );
 return $value;
}
add_filter( 'site_transient_update_plugins', 'filter_plugin_updates' );

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.