Create a User Account using PowerShell in Server 2012

Updated: Aug 2, 2019

This is simple step in how to create a user account using Windows PowerShell in Windows Server 2012.


For this demo, I'm using MIZI01.cpx.local domain that I previously deploy in Hyper-V, and for the client I prepare Windows 8 so that I can simulate the account created.


1 - Open your Windows Powershell which located in your taskbar.

- 2 Next, in your Powershell, type New-ADOrganizationalUnit MelakaBranch to create 1 new Organizational unit (for this demo, I create 1 new OU name MelakaBranch)

3 - Open Active Directory User & Computer to confirm the new OU succesfully created.

4 - After your new OU successfully created, now you can create your new user (for this demo I'm using a new user call Maler Selvarajah). In Powershell, type New-ADUser -Name Maler -DisplayName "Maler Selvarajah" -GivenName Maler -Surname Selvarajah -Path "ou=MelakaBranch,dc=cpx,dc=local" and press Enter. ** Refresh Active Directory User and Computer to confirm your new user is created successfully.


5 - Next, you must create password for your new user by typing Set-ADAccountPassword Maler

6 - Once your User password successfully created, you need to enable the account so that your new user can log in to their Windows 8 machine. Type Enable-ADAccount Maler and press Enter.

7 - Next, go to Windows 8 machine and try log in using Maler account.


My new user now successfully log in to her Windows 8 machine..


Our Office :

OSI TECHNOLOGY SDN BHD

16-1 Jalan Opera D U2/D,

Taman TTDI Jaya,

40150 Shah Alam,

Selangor Darul Ehsan

Tel : 603 7846 3080

Fax : 603 7848 3180

Email : info_osi@osi.com.my

Training Centre & Exam Centre : 

OSI TECHNOLOGY SDN BHD

20-1 Jalan Opera G U2/G,

Taman TTDI Jaya,

40150 Shah Alam,

Selangor Darul Ehsan