Change Your Mac Password from the Terminal
Rotate your own login password with the standard passwd command.
Run `passwd`, enter your current password once, then the new one twice.
01Command
Command
$ passwd02What it does
passwd updates the password for your current account — the same credential you use at the login screen, for sudo, and for unlocking your keychain. Run `passwd username` with admin rights to change another local account's password. After changing it, remember that other devices and saved sessions still use the old password until re-signed in.
03Risk
!Warning: The new password also unlocks your login keychain only if you enter the old keychain password when prompted; otherwise keychain items stay under the old password.
04Undo
✓No undo needed — this command does not change persistent state.
05Sources
- passwd — change a user password (macOS man page)Evidence: Documents passwd prompting for the current password and a new one for the invoking user.
Last verified: 2026-09-18 · Category: Security & Privacy