Jump to content

How to Add Users from CMD

From freem

To add users from the command prompt (CMD) in Windows, you can use the "net user" command. Here are the steps:

1. Open the command prompt as an administrator. You can do this by searching for "cmd" in the Start menu, right-clicking on "Command Prompt," and selecting "Run as administrator."

2. Type the following command to add a new user: ``` net user [username] [password] /add ``` Replace "[username]" with the desired username for the new user and "[password]" with the desired password.

3. If you want to require the new user to change their password at their first login, type the following command: ``` net user [username] /passwordchg:yes ```

4. If you want to add the new user to a specific group, type the following command: ``` net localgroup [groupname] [username] /add ``` Replace "[groupname]" with the name of the group you want to add the user to.

5. To verify that the new user has been added, type the following command: ``` net user ``` This will display a list of all the users on the computer, including the new user you just added.

That's it! You've successfully added a new user from the command prompt.