How to disable updates to WordPress, plugins, themes

Sometimes you may need to disable updates to plugins, themes, and the WordPress core so that there is no mention of updates in the console.A good solution is to install the Disable all WordPress Updates plugin.

There is also a Clearfy – WordPress optimization plugin and disable ultimate tweaker plugin. It also has a feature to disable WordPress updates, as well as many other useful features.

You can also prevent updates without using plugins. To do this, add the following code to the file functions.php:

  • to disable the WordPress core update:
    add_filter('pre_site_transient_update_core',create_function('$a', "return null;"));
    wp_clear_scheduled_hook('wp_version_check');
  • to disable plugin updates:
    remove_action( 'load-update-core.php', 'wp_update_plugins' );
    add_filter( 'pre_site_transient_update_plugins', create_function( '$a', "return null;" ) );
    wp_clear_scheduled_hook( 'wp_update_plugins' );
  • to disable theme updates:
    remove_action('load-update-core.php','wp_update_themes');
    add_filter('pre_site_transient_update_themes',create_function('$a', "return null;"));
    wp_clear_scheduled_hook('wp_update_themes');
    

Updated: 19.04.2020

Did this article help you? Rate it!
(No Ratings Yet)
Loading...

Support on Patreon https://www.patreon.com/processby

Leave a Reply

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

Contacts

E-mail: processby@gmail.com
Skype: inprocess.by
Belarus, Grodno

Send message