wp_check_password ( $password, $hash, $user_id = '' )

  • (string) password Plaintext user's password.
  • (string) hash Hash of the user's password to check against.
  • (string|int) user_id Optional. User ID.
  • PasswordHash::CheckPassword
  • (bool) False, if the $password does not match the hashed password.
Defined at:


Checks the plaintext password against the encrypted Password.Maintains compatibility between old version and the new cookie authentication protocol using PHPass library. The $hash parameter is the encrypted password and the function compares the plain text password when encrypted similarly against the already encrypted password to see if they match. For integration with other applications, this function can be overwritten to instead use the other package password checking algorithm.

Related Functions

wp_set_password, wp_hash_password, wp_generate_password, wp_get_password_hint, check_password_reset_key

Top Google Results

User discussions

wpseek mobile