I edited the Add New User Profile page to add some custom fields (I'm not using multisite). My question is if there is a way to send out an activation/confirmation email to new users once I manually add them in?


2 Answers 2


If you add a new user via the backend a confirmation email is sent automatically, unless you check the skip checkbox. The new user shouldn't appear in the UI until confirmed

  • When adding a user via the backend, the only option I have is "Send this password to the new user by email". However, it doesn't seem to work. Could it be because I'm using add_user_meta on the user_register action? Commented Dec 7, 2012 at 18:03
  • user meta etc should have no impact. I advise you test with a gmail account and the + feature to simulate multiple accounts
    – Tom J Nowell
    Commented Dec 7, 2012 at 18:55

Solved it by adding this code to save_extra_profile_fields() in add_action ( 'user_register', 'save_extra_profile_fields');

$hash = md5( $random_number );
add_user_meta( $user_id, 'hash', $hash );

$user_info = get_userdata($user_id);
$to = $user_info->user_email;           

$subject = 'Member Verification'; 
$message = 'Hello,';
$message .= "\n\n";
$message .= 'Welcome...';
$message .= "\n\n";
$message .= 'Username: '.$un;
$message .= "\n";
$message .= 'Password: '.$pw;
$message .= "\n\n";
$message .= 'Please click this link to activate your account:';
$message .= home_url('/').'activate?id='.$un.'&key='.$hash;
$headers = 'From: [email protected]' . "\r\n";           
wp_mail($to, $subject, $message, $headers); 

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.