The fastest way depends on what you remember and what device you use

If you have forgotten your administrator password, the path forward depends on whether you can still log in as a different user on the same computer, whether you have a password reset disk from before you forgot it, or whether you need to use recovery tools built into your operating system. Windows, Mac, and Linux each have different recovery routes, and some are faster than others. The method that works for you also depends on whether you set up a recovery email or phone number when you created the account.

Start by identifying which operating system you use, then follow the steps for that system. Most people can reset their password without losing files or reinstalling the operating system, though the process takes longer on some systems than others.

Key Takeaways

  • Windows users with another account on the computer can use Settings to reset the forgotten password in minutes, or use a Microsoft account recovery email if they do not have a second account.
  • Mac users can reset a password using Recovery Mode and an Apple ID, or by using a password reset disk created before the password was forgotten.
  • Linux users can boot into single-user mode or use a live USB to reset the root password without needing a recovery email or disk.
  • If you have no recovery method available, you will need to reinstall the operating system, which erases all files on the computer.
  • Creating a password reset disk or recovery email now prevents this problem in the future and takes less than five minutes.

Resetting your password on Windows 10 or 11

If you have another user account on the same computer with administrator rights, you can reset the forgotten password from Settings without needing a recovery email. Log in with the other account, then open Settings, go to Accounts, select the account with the forgotten password, and click "Reset password". Windows will ask you to create a new password and confirm it. This method works even if the other account is not an administrator account, as long as you can log in to it.

If you do not have another account on the computer, you will need to use your Microsoft account recovery email. On the Windows login screen, click "I forgot my password", then enter your Microsoft email address. Microsoft will send a reset link to the recovery email address you set up when you created the account. Click the link, create a new password, and return to the login screen to use it. This process usually takes a few minutes, though the email may take up to an hour to arrive.

If you do not remember your Microsoft email address or no longer have access to the recovery email, you will need to use a password reset disk if you created one before forgetting the password. Insert the disk into the computer, click "Reset password" on the login screen, and follow the prompts to create a new password. If you have no reset disk and no recovery email, you will need to reinstall Windows, which erases all files on the computer.

Resetting your password on Mac

The fastest method on Mac is to use your Apple ID. Restart the computer and hold Command + R to enter Recovery Mode. Once the recovery tools appear, open Utilities from the menu bar and select "Reset Password". Choose your user account from the dropdown, then click "Reset". You will be asked to enter your Apple ID and password. After you do, macOS will let you create a new administrator password without erasing any files.

If you do not remember your Apple ID password, you can reset that through Apple's account website on another device, then return to the Mac and use the new Apple ID password to reset your administrator password. If you do not have access to an Apple ID at all, you can use a password reset disk if you created one before forgetting the password. Insert the disk, restart the Mac, hold Command + R, go to Utilities, select "Reset Password", and choose the disk from the dropdown menu.

If you have no Apple ID access and no reset disk, your only option is to erase the computer and reinstall macOS. This removes all files and programs. You can do this from Recovery Mode by selecting "Erase Mac" from Utilities, then reinstalling macOS afterward.

Resetting your password on Linux

Linux systems allow you to reset the root password by booting into single-user mode, which does not require a recovery email or disk. Restart the computer and hold Shift (on most distributions) or Escape (on some older systems) to enter the GRUB boot menu. Select the line that ends with "single" or "recovery mode", then press Enter. The system will boot into a command line where you are already logged in as root. Type passwd username (replacing "username" with the account name), then enter a new password twice. Restart the computer normally, and you can log in with the new password.

If you are not sure which key to hold during startup, restart the computer and try holding Shift for a few seconds after you see the manufacturer's logo. If that does not work, try Escape. Different Linux distributions use different keys, and some newer systems with UEFI firmware may require different steps. If you cannot access GRUB, you can use a live USB with a Linux distribution on it to reset the password. Create a live USB on another computer, insert it into the locked computer, restart, and boot from the USB. Once the live system starts, open a terminal and use the passwd command to reset the password on the installed system.

What to do if you have no recovery method

If you have no second account, no recovery email, no password reset disk, and cannot access recovery mode, you will need to reinstall your operating system. This erases all files on the computer, so it should be your last option. Before you do this, try restarting the computer several times and waiting a few minutes between restarts — sometimes the system will offer additional recovery options after a failed login attempt.

To reinstall, you will need a USB drive with at least 8 gigabytes of space and a second computer to create the installation media. On the second computer, read the operating system installer (Windows, macOS, or Linux) and use a tool like Rufus, Etcher, or the built-in recovery tool to write it to the USB drive. Insert the USB into the locked computer, restart, and boot from the USB. Follow the installation prompts, and when asked where to install, select the main drive. The installer will erase it and install a fresh copy of the operating system. You will then create a new administrator account during setup.

Preventing this problem in the future

The easiest way to avoid a forgotten password is to create a password reset disk or recovery email now, before you need it. On Windows, open Settings, go to Accounts, select "Password", and click "Create a password reset disk". On Mac, open System Preferences, go to Users & Groups, select your account, and click "Reset Password" — if you have not set up an Apple ID recovery option, the system will prompt you to do so. On Linux, most distributions do not offer a built-in recovery method, but you can create a live USB with your distribution on it and keep it in a safe place.

You should also consider using a password manager like Bitwarden, 1Password, or KeePass to store your administrator password in an encrypted file. Password managers let you generate strong passwords and retrieve them on another device if you forget. Some password managers can also sync across devices, so you can look up your password on your phone if you forget it on your computer.

Frequently Asked Questions

Can I reset my password without losing my files?

Yes, in most cases. Using a recovery email, a second account, or a password reset disk will let you create a new password without erasing anything. Only a full operating system reinstall erases files, and that should be your last resort.

How long does it take to reset a password using a recovery email?

Usually a few minutes to an hour. The reset link arrives in your email inbox within a few minutes on most systems, though it can take up to an hour. Once you click the link and create a new password, you can log in when ready.

What if I forgot both my administrator password and my recovery email password?

You can reset your recovery email password on another device by going to the email provider's website and using account recovery options there. Once you regain access to the email, you can use it to reset your administrator password. If you cannot recover the email account, a password reset disk or second user account are your next options.

Is there a way to reset my password without restarting the computer?

No. All password reset methods require you to restart the computer and either log in as a different user, access recovery mode, or use a recovery email. You cannot reset an administrator password while logged in as that administrator.

Will resetting my password affect my programs or documents?

No. Resetting your password changes only the password itself. All your programs, documents, photos, and other files remain on the computer and in the same locations. Only a full operating system reinstall removes files.