...

How to Enable Automatic Updates in WordPress for Major Releases

124

WordPress recently released its latest version 3.7. It has some important improvements, but automatic updates is definitely the most significant feature of this release. WordPress can now automatically update itself when there is a new minor or security release available. Previously, we showed you how to disable automatic updates in WordPress. But if you really like the idea of auto-updating, then you can actually enable it for major versions as well. In this article, we will show you how to enable automatic updates in WordPress for major releases.

Automatic updates in WordPress 3.7 only run when there is a minor or security release. For example a typical WordPress website running 3.7 will automatically update itself to 3.7.1 without any user input, but it will not update to 3.8 which will be a major release.

For users who run many WordPress sites without any managed WordPress hosting, updating all their WordPress sites can be time consuming.

Turn on Autmatic Updates for Major WordPress Releases

The core team didn’t enable automatic updates for all WordPress releases because usually a major release comes with significant changes. This means that sometimes your site may not be ready to update immediately specially if it has a lot of customization. But if you are confident about your WordPress hosting provider, your site’s plugins and themes, then you can enable automatic updates for major releases as well.

Simply add this single line of code in your site’s wp-config.php file.

define( 'WP_AUTO_UPDATE_CORE', true );

There is one little problem with this code. It also enables development or nightly updates. To disable nightly builds and development updates you need to add this code in a site-specific plugin or in your theme’s functions.php file.

  add_filter( 'allow_dev_auto_core_updates', '__return_false' );

This filter will disable automatic updates for nightly builds or development updates.

With this solution, your WordPress site is now ready to automatically update itself, without your input, whenever there is a new WordPress version available. Let us know what you think about automatic updates? Leave a comment below.

Seraphinite AcceleratorOptimized by Seraphinite Accelerator
Turns on site high speed to be attractive for people and search engines.