Attention Interested in functions, hooks, classes, or methods? Check out the new WordPress Code Reference!

Function Reference/get user by email

This function has been deprecated. That means it has been replaced by a new function or is no longer supported, and may be removed from future versions. All code that uses this function should be converted to use its replacement if one exists. See also wp-includes/deprecated.php. Use get_user_by instead.


This function is an alias for get_user_by( 'email', $email ).

function get_user_by_email( $email ) {
	return get_user_by( 'email', $email );


<?php get_user_by_email$email ); ?>


(string) (required) A user's email address.
Default: None

Return Values

WP_User object or false if no user is found.

Source File

get_user_by_email() is located in wp-includes/pluggable-deprecated.php since version 2.5. Before that it was located in wp-includes/pluggable.php.

This page is marked as incomplete. You can help Codex by expanding it.