15-Sep-2020

Blocking WordPress Auto Update Emails

With the release of WordPress version 5 comes the option to automatically update plugins. A great idea but the emails you get are annoying. Learn how to turn them off.

WordPress now updates plugins automatically, and each time it does it an email is sent to the administration email address. If you want to turn them off simply add the following code to the functions.php file in the WordPress theme.

// Stop plugin auto update emails
add_filter('auto_plugin_update_send_email', 'wpb_stop_plugin_emails', 10, 4);
function wpb_stop_plugin_emails($send)
{
    return false;
}

// Stop core update success emails.
add_filter('auto_core_update_send_email', 'wpb_stop_auto_update_emails', 10, 4);

function wpb_stop_update_emails($send, $type, $core_update, $result)
{
    if (! empty($type) && $type == 'success') {
        return false;
    }
    return true;
}

Leave a Reply

linkedin facebook pinterest youtube rss twitter instagram facebook-blank rss-blank linkedin-blank pinterest youtube twitter instagram