User password management
These methods on the User
object help you manage a user's password.
The following examples assume that you have followed the quickstart in order to add Clerk to your JavaScript application.
updatePassword()
Updates the user's password. Passwords must be at least 8 characters long.
- Name
newPassword
- Type
string
- Description
The user's new password.
- Name
currentPassword?
- Type
string
- Description
The user's current password.
- Name
signOutOfOtherSessions?
- Type
boolean | undefined
- Description
If set to
true
, all sessions will be signed out.
removePassword()
Removes the user's password.
- Name
currentPassword
- Type
string
- Description
The user's current password.
Feedback
Last updated on