WordPress – How to disable new user notification emails

The following code can be used to disable the WordPress new user notification emails.

To use copy into your theme’s functions.php file, below the opening <? line.

// DISABLE default WordPress new user notification emails
if (!function_exists('wp_new_user_notification')) :
 function wp_new_user_notification($user_id, $plaintext_pass = '') {
 return;
 }

How does it work?

The wp_new_user_notification function is the part of the WordPress core that handles the email notification.

It’s also a pluggable function – meaning we can call it through a theme or a plugin and completely override it.

The code above does this and returns nothing, meaning no email is created or sent when it is triggered by a new user registering.