Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

can i create local users just using windows registry? i write the programm wich help me to migrate my from one computer to another. When i work with domain user i can save it settings with windows registry and saving ProfileImagePath folder. now i want to save local users by this way.

share|improve this question

With a little VBS scripting you can do this (copied from here):

strComputer = "MyComputer"
Set colAccounts = GetObject("WinNT://" & strComputer & "")
Set objUser = colAccounts.Create("user", "Admin2")
objUser.SetPassword "test"

Note: you do not interact with the registry at all, instead with the SAM.

share|improve this answer
good script but i want to transferred domain user applications setting from one computer to another. – Xaver Apr 29 '10 at 11:08
@Xaver: Please update the question then. Because moving a domain user's profile is a completely different thing (for a start, you don't create a user). – Richard Apr 30 '10 at 7:33
i write the 2 scripts for domain user. First save folder settings of domain user. Second load folder settings to domain user, if settings folder is not exist the script not working. – Xaver May 4 '10 at 9:32

No, you need more than the registry in order to create a user. You have to script it or use another language that can interact with something like WMI to create users. Some profile items and settings are stored in the registry, but you also have things like the user's profile folder (including the ntuser.dat file) and the password which are not part of the registry.

share|improve this answer
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList it contains info about all user's profile folder – Xaver Apr 28 '10 at 4:49
And the password resides in the systems SAM file, typically found at C:\Windows\System32\config\. This file is locked down to all but the SYSTEM account I believe. – Gomibushi Apr 28 '10 at 6:22
...and trying to edit it manually would be a Very Bad Thing (TM) – Massimo Apr 28 '10 at 9:00

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.