Prevent WordPress automatic updates

WordPress automatic updates were introduced in WordPress 3.7 to protect WordPress enabled websites from security vulnerabilities. This feature comes in handy to keep your website safe and up to date.

However, in some cases, you would prefer to keep track of updates and test them locally before applying them to your live site.  Doing it this way will help you avoid crashes and conflicts with your theme and plugins.

The snippet below will disable all WordPress automatic updates and will give you full control on adding them manually when you are ready to do so.

In order for the code to work, you should insert it in your wp-config.php which is located in your website’s root.

PHP
//Disable Wordpress automatic updates
define('WP_AUTO_UPDATE_CORE', false);