You cannot recover a forgotten Mac password, but you can reset it
If you have forgotten your Mac password, Apple does not have a way to retrieve it. Instead, you will need to reset it using one of three methods: your Apple ID, a recovery key, or macOS Recovery mode. Which method works depends on whether you remember your Apple ID password, whether you set up a recovery key when you first created your account, and which version of macOS you are running.
The fastest route is usually your Apple ID, because you can reset your password when ready without restarting your Mac. If you do not remember your Apple ID password either, you will need to restart into Recovery mode, which takes longer but does not require any other credentials.
Key Takeaways
- Your Mac password and your Apple ID password are separate — forgetting one does not mean you forgot the other, and resetting one does not reset the other.
- If you remember your Apple ID password, you can reset your Mac password without restarting by going to System Settings, clicking your name at the top, and selecting Password.
- If you set up a recovery key when you created your account, you can use it to reset your password in System Settings without needing your Apple ID password.
- If you remember neither your Mac password nor your Apple ID password, restart into Recovery mode by holding Command and R during startup, then use your Apple ID to create a new password.
- On newer Macs with Apple Silicon chips, you may need to use your recovery key or Apple ID to reset your password because Recovery mode works differently than on Intel Macs.
Resetting your password with your Apple ID
If you remember your Apple ID email and password, this is the quickest method. Click the Apple menu in the top left corner, then System Settings. Click your name at the very top of the sidebar. Look for Password in the left sidebar and click it. Enter your current Mac password when prompted — if you cannot remember it, skip to the Recovery mode section below. Then click Change Password and follow the prompts to create a new one.
Your Mac will ask you to enter the new password twice to confirm it matches. Once you do, your old password stops working when ready. You will need to use the new password the next time you log in, restart your Mac, or unlock your screen.
Using a recovery key to reset your password
When you first set up your Mac account, Apple may have offered you a recovery key — a long string of numbers and letters that looks like 1A2B-3C4D-5E6F-7G8H. If you saved this key somewhere safe, you can use it to reset your password without needing your Apple ID password.
Go to System Settings, click your name, and select Password. You will see an option that says "Can't remember your password?" Click it. Choose "I have a recovery key" and enter the key when prompted. Then create a new password. This method works on any Mac and does not require you to restart.
Resetting your password in Recovery mode
If you do not remember your Apple ID password and do not have a recovery key, you will need to restart your Mac into Recovery mode. Shut down your Mac completely. Turn it back on and when ready hold down Command and R at the same time. Keep holding until you see the Apple logo or a spinning globe. This usually takes 10 to 20 seconds. Release the keys when the macOS Utilities window appears.
Click Utilities in the menu bar at the top, then select Terminal. Type resetpassword and press Enter. A password reset window will open. Select your user account from the dropdown menu at the top. You will be asked to sign in with your Apple ID. Once you do, you can create a new Mac password. Click Reset Password, then restart your Mac when prompted.
On newer Macs with Apple Silicon chips (M1, M2, M3, and later), Recovery mode may ask you to enter your Apple ID password before you can access Terminal. If that happens, you will need to remember your Apple ID password to proceed. If you do not, you will need to contact Apple Support or take your Mac to an Apple Store.
What to do if you do not remember your Apple ID password either
If you have forgotten both your Mac password and your Apple ID password, you have two options. The first is to reset your Apple ID password through Apple's website before attempting to reset your Mac password. Go to iforgot.apple.com on another device, enter your Apple ID email, and follow the steps to reset it. Once you have a new Apple ID password, you can use the Recovery mode method above.
The second option is to contact Apple Support or visit an Apple Store in person. Bring a photo ID and proof that you own the Mac, such as the original receipt or your AppleCare documentation. Apple can verify your identity and help you regain access to your account. This process usually takes longer than resetting it yourself, but it is the only option if you cannot access another device to reset your Apple ID password.
Preventing password loss in the future
Once you have reset your password, consider taking steps to avoid this situation again. Write your recovery key down and store it in a safe place — a locked drawer, a safe deposit box, or a password manager all work well. Do not store it in a text file on your Mac, because if you forget your password, you will not be able to access that file.
You can also set up a second administrator account on your Mac. If you forget the password on your main account, you can log in with the second account and reset the first one from System Settings. Go to System Settings, click General, then Users & Groups, and click the lock icon to make changes. Click the plus button to add a new account and choose Administrator as the account type.
Differences between your Mac password and your Apple ID password
Your Mac password is what you use to log in to your computer. Your Apple ID password is what you use to sign in to iCloud, the App Store, and other Apple services. They are completely separate. You can change one without changing the other, and forgetting one does not mean you forgot the other.
When you reset your Mac password using your Apple ID, you are not changing your Apple ID password — you are only changing the password you use to log in to your Mac. Your Apple ID password stays the same. This is why you need to remember at least one of the two passwords to regain access to your Mac.
Frequently Asked Questions
Can I see my Mac password after I set it?
No. macOS does not display passwords after you create them, and Apple does not store them. If you forget it, you must reset it using one of the methods above. You cannot recover the original password.
Will resetting my password delete my files?
No. Resetting your Mac password does not affect your files, photos, documents, or any other data on your computer. It only changes the password you use to log in. Your files remain exactly as they were.
What if I see a message saying my account is locked?
If you enter your password incorrectly too many times, macOS may temporarily lock your account for security. Wait 15 minutes without trying to log in, then try again. If the account remains locked after waiting, use the Recovery mode method to reset your password.
Do I need to be connected to the internet to reset my password?
If you use your Apple ID to reset your password, yes — your Mac needs internet access to verify your Apple ID. If you use a recovery key, you do not need the internet. In Recovery mode, you will need internet to sign in with your Apple ID, but not if you use a recovery key.
What happens if I reset my password but still cannot log in?
If you reset your password successfully but still cannot log in, try restarting your Mac and waiting a few minutes before trying again. If the problem continues, restart into Recovery mode and run Disk Utility to check for errors on your drive. If that does not work, contact Apple Support.