How to Manage User Accounts with Command Prompt in Windows

Table of contents:

How to Manage User Accounts with Command Prompt in Windows
How to Manage User Accounts with Command Prompt in Windows
Anonim

The Windows "Command Prompt" is a shell, just like the "Terminal" window of Apple's macOS operating system. It is a very powerful tool that allows you to issue commands directly to the machine's operating system. Most of the actions that are usually performed by users using the graphical interface of the operating system (for example accessing a folder) can also be performed through the use of specific commands. It is for this reason that you can use the "Command Prompt" to create a new user account or to delete an existing one. Read on to find out how.

Steps

Part 1 of 2: Access the Command Prompt

Add and Delete Users Accounts With Command Prompt in Windows Step 1
Add and Delete Users Accounts With Command Prompt in Windows Step 1

Step 1. Access the menu or "Start" screen

You can do this by pressing the "Start" button located in the lower left corner of the desktop. Remember that, in order to create a new user account or delete an existing one, you must use an administrator account for the system in use.

Alternatively, you can press the ⊞ Win key on your keyboard

Add and Delete Users Accounts With Command Prompt in Windows Step 2
Add and Delete Users Accounts With Command Prompt in Windows Step 2

Step 2. Type the string "Command Prompt" into the search field of the menu or the "Start" screen

The "Command Prompt" icon should appear in the first position of the results list.

You can also use the hotkey combination ⊞ Win + X to access the context menu of the "Start" button, where there is a shortcut to the "Command Prompt"

Add and Delete Users Accounts With Command Prompt in Windows Step 3
Add and Delete Users Accounts With Command Prompt in Windows Step 3

Step 3. Select the "Command Prompt" icon with the right mouse button

This will bring up a context menu.

Add and Delete Users Accounts With Command Prompt in Windows Step 4
Add and Delete Users Accounts With Command Prompt in Windows Step 4

Step 4. Choose the "Run as administrator" option

Using a "guest" user account you will not be able to log into the "Command Prompt" as a system administrator.

If you are using the "Start" button context menu, you will need to choose the "Command Prompt (Admin)" option. Do not choose the "Command Prompt" item

Add and Delete Users Accounts With Command Prompt in Windows Step 5
Add and Delete Users Accounts With Command Prompt in Windows Step 5

Step 5. Press the "Yes" button located in the "User Account Control" pop-up window

This way, you will have access to the "Command Prompt" as a system administrator.

Part 2 of 2: Adding and Deleting User Accounts

Add and Delete Users Accounts With Command Prompt in Windows Step 6
Add and Delete Users Accounts With Command Prompt in Windows Step 6

Step 1. Select the "Command Prompt" window

In this way, you will be sure that the window cursor is active allowing you to enter the desired commands.

Add and Delete Users Accounts With Command Prompt in Windows Step 7
Add and Delete Users Accounts With Command Prompt in Windows Step 7

Step 2. Add a new user account

To do this, type the command net user [username] [password] / add, then press the Enter key. This will create a new user account within your system.

Replace the information inside the square brackets with the real username and password of the account you want to create. Also, be sure to delete the brackets before running the command

Add and Delete Users Accounts With Command Prompt in Windows Step 8
Add and Delete Users Accounts With Command Prompt in Windows Step 8

Step 3. Delete an existing account

To do this, type the command net user [username] / delete and press the Enter key. The specified user account will be deleted from the system permanently.

After you have successfully created or removed a user account, you will see the "Command Executed Successful" message appear within the "Command Prompt" window

Add and Delete Users Accounts With Command Prompt in Windows Step 9
Add and Delete Users Accounts With Command Prompt in Windows Step 9

Step 4. Close the "Command Prompt" window

Now you know how to create or delete a user account using the Windows command line directly.

Recommended: