Although you can easily reset your account’s password after you’ve successfully logged in to your MacBook Pro, the password can’t be reset if you are not able to log in at all.
In such a case, you can reset your password from the Recovery Mode.
- ■Get to Recovery Mode
Power on your MacBook Pro (or restart if it is already on), press the Command + R keys together as soon as the computer starts up, and release the keys when you see the Apple logo. This boots your MacBook Pro in Recovery Mode. From here you can troubleshoot issues related to your hard disk, inconsistencies in your operating system, restore your data, etc.
■Open the Terminal window
Select your preferred language in the Language window (English for this example), click the Next button, click Utilities from the menu bar at the top, and click Terminal from the drop-down menu. This opens the Terminal window. Here you can enter your commands to perform various administrative and non-administrative tasks on your MacBook Pro.
■Open the Reset Password window
Type resetpassword in the Terminal window, and press Enter. This opens the Reset Password window. From here you can reset the password for any account your MacBook Pro has without any restrictions.
■Reset the password
Select the account you lost the password for in the Reset Password window (Jacob for this example), click Next, type and confirm a new password in the New Password and Verify Password fields respectively, type a password hint in the Password hint field (optional), click Next, and click Restart. This resets your password, and restarts your MacBook Pro. Upon restart, you can use your new password to log in to your account.