Function: wpmu_validate_user_signup

wpmu_validate_user_signup( string $user_name, string $user_email )

Sanitize and validate data required for a user sign-up.

Verifies the validity and uniqueness of user names and user email addresses, and checks email addresses against admin-provided domain whitelists and blacklists.

The \'wpmu_validate_user_signup' hook provides an easy way to modify the sign-up process. The value $result, which is passed to the hook, contains both the user-provided info and the error messages created by the function. \'wpmu_validate_user_signup' allows you to process the data in any way you'd like, and unset the relevant errors if necessary.


Name Type(s) Default Value Description
$user_name string

The login name provided by the user.

$user_email string

The email provided by the user.



Contains username, email, and error messages.

WordPress Developer Newsletter

Stay on top of the latest WordPress API changes, developer tool updates, security alerts and more.