wordpress change email new user template

  1. Log in to your WordPress admin dashboard.

  2. Navigate to the "Appearance" menu and select "Theme Editor."

  3. In the Theme Editor, locate and click on the "functions.php" file in the right-hand column.

  4. Add the following code at the end of the "functions.php" file:

function custom_new_user_email_content($message, $user_id, $user_data) {
    // Modify the subject
    $message['subject'] = 'Your custom subject';

    // Modify the message body
    $message['message'] = 'Your custom message';

    return $message;
}

add_filter('wp_new_user_notification_email', 'custom_new_user_email_content', 10, 3);
  1. Customize the subject and message in the code with your desired content.

  2. Click the "Update File" button to save the changes.

Now, the email template for new user notifications in WordPress has been modified.