Join our mailing list to receive the latest news and updates from our team.

<p>Thanks for signing up! :)</p>

read more.mapouter{overflow:hidden;height:500px;width:600px;}.gmap_canvas {background:none!important;height:500px;width:600px;}
Home / Computer / How to Change the Windows User Password via Command Line

How to Change the Windows User Password via Command Line

Posted on

Changing your password is simple in Windows. While you can jump through a few menus to change the password for your own account (or someone else’s if you’re an administrator), if ever you can’t do it that way, you can always use the Command Prompt instead.

It might scare new users, but the Command Prompt is great for quickly doing common tasks. Next time you want to change a password on your PC, try this method.

How to Change the Windows User Password via Command Line

  1. First, open an administrator Command Prompt (assuming you have administrator privileges). To do this, type cmd into the Start Menu. Right-click on the Command Prompt entry and choose Run as administrator.
  2. Type the following command and press Enter to list all the users on your system:
    net user
  3. Take note of the account name you want to change the password for, then use this command. Replace USERNAME and NEWPASS with the actual username and new password for the account. Further, if the username is more than one word, you’ll need to place it inside quotes:
    net user USERNAME NEWPASS
    net user "USER NAME" NEWPASS
  4. After you press Enter to run this command, you’ll see a message that it completed successfully. Now you can use the new password to log into this account.

Windows-Change-Password-Command-Line

For extra security, you can use a slightly different command to prevent the new password from appearing on-screen.

We can also change a user password from Windows command line using net use command. The command is explained below with examples.

How to change local user password

net user  loginid  newpassword

For example, if you want to reset the password for the user John on the local computer, you can run the below command. Let’s say the new password is pq12d*12@

net user  John  pq12d*12@

You may not want to provide the new password in the command prompt for obvious security reasons. Net use command allows to reset the password so that none around your desk can see it. You need to provide * in the place of password while executing net use command. You will be prompted to type the password and the password you enter won’t be printed on the screen. But you need to feed the password twice to make sure that you have entered the password you intended to.

example:

C\>net user John *
Type a password for the user:
Retype the password to confirm:
The command completed successfully.

If you see an Access denied message, make sure that you started the Command Prompt as an Administrator. Standard users can’t change the password for other users.

 

Sources:
Make Use Of
Windows Command Line

Leave a Reply

Top
%d bloggers like this: