How to reset Windows 11 administrator password using Command Prompt (CMD)

Being locked out of your account can be a frustrating scenario. We have all been there at one point or another. If you’ve wrecked your brain enough and still come short, perhaps it’s time to reset your password so you can log back in and resume your work. 

Though there are a few ways to reset your administrator account on Windows 11, in this article, we take a look at the methods to do so using the command prompt (CMD) depending on the resources that you currently have access to. 

What to do if you forget your Windows 11 administrator password?

Being unable to access your Windows 11 administrator account is no joke. This is especially true if there are no other administrator accounts on the computer and you’re locked out with no way in. But Windows offers a few ways to recover or reset your administrator password.

When you type the wrong password, Windows will provide a “Reset password” link. When selected, Windows will try to jog your memory by prompting you with security questions. Alternatively, you can even reset the password by going to account.microsoft.com. 

However, those things can be a little tedious. And if you don’t remember answers to the security questions that you would have typed at the time of setting up Windows, then the Command Prompt is your only resort. 

But since the Command Prompt can be evoked from a few different screens, there are a few different ways in which you can use it to reset the password of your Windows 11 administrator account. 

How to reset Windows 11 administrator password using the command prompt

Here are three methods through which you can reset your Windows 11 administrator account’s password.

Method 1: When you’re logged in

Before we get to the tough bits, let’s consider the scenario in which you are already logged in and need the password to your administrator account to change certain settings. Here’s how to reset it using the command prompt:

Press Start, type cmd, then right-click on the best-matched result and select Run as administrator.

Then type the following command to get a list of all the users on this computer:

net user

Hit Enter. Find your administrator account in the list.

Now type the following command:

net user "Username" password

Make sure to replace Username with the actual username of your administrator account (and keep the quotes). And replace password with the new password.

Then hit Enter.

If you get the “command completed successfully” message, your administrator password is reset. 

This method also works if there is another administrator account present on your computer. Just ask the other administrator to run the same commands and make sure to choose your username and then set your new password. 

Method 2: Without logging in (Using Safe Mode Command Prompt)

Another way to change the password to your admin account is to do so from Safe Mode. If certain applications or services are blocking the other administrator from implementing the changes to your account password, switching to safe mode will allow them to bypass the issues.  

Here’s how to go about it:

Click on the Power button on the login screen.

Then hold down the Shift key and click on Restart.

Once your computer restarts, it will boot straight to the Windows Recovery Environment. Here, select Troubleshoot.

Then click on Advanced options.

Choose Startup Settings.

Click on Restart.

Once the Startup Settings screen comes up, press 6 to choose Enable Safe Mode with Command Prompt.

Once the system restarts and you’re in the Safe Mode command prompt, type the following command:

net user

Hit Enter. Find your administrator account in the list. Then type the following command:

net user "Username" password

Make sure to replace Username with the actual username of your administrator account. (and keep the quotes). And replace password with the new password.

Then hit Enter.

If you get the “command completed successfully” message, your administrator password is reset. 

Method 3: When logged out (Using a bootable USB)

If there is no other administrator account on your Windows PC and you’re not logged in (or have any other login options), then you will have to activate a temporary administrator account using the command prompt from the login screen. But, as you would already know, the login screen doesn’t provide a way to access CMD.

It does, however, have an Accessibility button next to the Power button. This can be configured to open the Command Prompt. How can this be done? Follow the steps below:

Requirements

  • A USB drive with at least 8 GB of storage space.

Guide

Now, the first thing to do is to download Windows 11 installation media. Of course, since you can’t log in to your system, this has to be done on another computer.

Windows 11 Installation Media | Download link

Follow the link given above and click on Download Now under “Create Windows 11 Installation Media”.

Once downloaded, double-click on it to run it.

Click Accept.

Then click Next.

With the USB flash drive option selected, click Next.

Make sure your USB drive is recognized and selected, then click Next.

Click on Finish.

Wait for the process to finish, Once done, plug in the USB to your own computer whose password you want to reset. Then power on your computer. Access the BIOS by pressing the F2, F10 or Delete key (it’s different on different systems). Refer to our guide on How to get to BIOS in Windows 11 to know more. 

In the BIOS, change the boot option to Removable Devices or CD-ROM drive. Once done, save the changes and boot up.

This will take you to the Windows Setup screen.

Here, press Shift + F10 to open the command prompt. Once the command prompt opens, type the following:

C:

Then press Enter. This will change the directory from X: to C: – the system drive. If you have Windows installed on any other drive, type and enter that letter instead. Then type the following command:

cd windows\system32

Press Enter. Then type the following:

ren utilman.exe utilman.exe.bak

Then hit Enter. This will rename the utility manager executable file and replace it in the login screen. Now type the following:

ren cmd.exe utilman.exe

And hit Enter. This will rename the command prompt to utilman, so that when you click on Accessibility button later, instead of the Accessibility options, the command prompt will open up. Finally, to reboot, type the following and hit Enter.

wpeutil reboot

Once your computer reboots, click on the Accessibility button towards the bottom right of the screen.

This will open up the Command Prompt instead. In the command prompt, type the following command:

net user Administrator /active:yes

Hit Enter.

This will turn on a new administrator’s account which we’ll be using temporarily to change your account’s password. Click on it to log into it.

Wait for the account to set up.

Once you’re in, press Start, type computer management, and hit Enter.

In the Computer Management app, expand the Local users and Groups branch.

Then click on Users.

You will see a list of all users on the right. 

Right-click on your account and select Set Password…

Click on Proceed.

Type and then confirm your new password, and click OK.

Click on OK.

Now log out of this temporary Administrator account and use the new password to log in to your account.

You’re all done! The only thing that’s left to do is to clean your tracks and set everything as it was before. 

Firstly, to delete the temporary Administrator account, open the command prompt from the Accessibility button as before. Then type the following command:

net user Administrator /active:no

Then hit Enter.

Now restart your system. The Administrator account should disappear. 

The last thing left to do is to put the Utility Manager and the Command Prompt back where they belong. To do so, open the Command Prompt using the USB boot media as shown before. Then type the following command:

C:

Hit Enter. Then type:

cd Windows\system32

Hit Enter. Then type:

ren utilman.exe cmd.exe

Hit Enter. Finally, type the following:

ren utilman.exe.bak utilman.exe

Hit Enter. Then type wpeutil reboot to restart your PC. 

Everything will now be in its right place. 

Do note that although this process can help you reset your Windows 11 administrator account’s password, it won’t be of any help if you were logged in with your Microsoft account. To reset your Microsoft account’s password, you will have to visit account.live.com/password/reset.

FAQs

Here’s a look at a few commonly asked queries about resetting the Administrator passwords on Windows 11 and their solutions.

How do I reset my Administrator password on Windows 11?

You can reset your administrator account password in a few ways. You can answer the security questions prompted by Windows, ask another administrator on the same computer to reset your account’s password, or activate the temporary Administrator account from where you can change your own account’s password.

How do I change Administrator password using CMD?

To change the Administrator password using CMD, you will have to use a bootable USB to change the Accessibility button on the logon screen with the command prompt. After that, activate a temporary administrator’s account and use that to change your account’s password. Alternatively, if there is another administrator account on your computer, you can use that to change the password of your current admin account. To know how to go about these methods, refer to the guide above.

Can you change your Microsoft account password with CMD?

No, you cannot change your Microsoft account password with the command prompt. This is regardless of whether you do it with access to another admin account or are activating a temporary administrator account. If you are using your MS account as your main account, you will have to change the password from the page account.live.com/password/reset.

We hope you were able to change your administrator password with the help of this guide. 

1 Comment

  1. Thanks for this. I was wondering if I can follow the same settings just like back in Windows 10.

Leave a Reply

Your email address will not be published.