You can also enable the built-in admin account to log into Windows first and then reset your PIN.
Step 1: Access the Command Prompt in Windows RE
On the PC's login screen, click the Power icon.
Hold down the Shift key on your keyboard and click Restart. Keep holding Shift until you see the Choose an option screen.
Select Troubleshoot.
Select Advanced options.
Select Command Prompt.
Step 2: Load the System Registry Hive
You must manually load the registry files from your Windows installation to modify them.
Determine the Windows Drive Letter: Try D: or C: and use the dir command to confirm the partition containing the Windows folder. Assume your Windows is on the D: drive.
- Start the Registry Editor: regedit
- Load the Hive:
In the Registry Editor, click and select HKEY_LOCAL_MACHINE in the left pane.
Click the File menu > Load Hive....
- Navigate to your Windows directory and find the SAM (Security Accounts Manager) registry file: D:\Windows\System32\config\SAM
(Remember to replaceD:with your actual drive letter) In the dialog box that appears, enter a temporary name (e.g.,TempSAM) and click OK.
Step 3: Modify the Registry Key Value to Enable Administrator Account
Now you will modify the binary data under TempSAM to enable the built-in Administrator account.
- Navigate to the following path: HKEY_LOCAL_MACHINE\TempSAM\Domains\Account\Users\Names\Administrator
- In the right pane, note down the RID (Relative Identifier) corresponding to this account. This is usually found in the parent
Usersfolder and is a four-digit hexadecimal value (e.g.,000001F4).
- In the right pane, note down the RID (Relative Identifier) corresponding to this account. This is usually found in the parent
- Navigate to the account's data path:
HKEY_LOCAL_MACHINE\TempSAM\Domains\Account\Users\[Your RID, e.g., 000001F4]Double-click theFvalue in the right pane (this is aREG_BINARYvalue). In the binary editor, locate the 59th byte of data (or the 15th value on line 0038). Crucial: The default value for this byte is typically11(which indicates the account is disabled).Change this byte's value from __`11`__ to __`10`__. Click __OK__.
Step 4: Unload the Hive and Restart
In the left pane, click and select your temporary hive HKEY_LOCAL_MACHINE\TempSAM.
Click the File menu > Unload Hive....
Close the Registry Editor and the Command Prompt.
On the Choose an option screen, select Continue to restart and boot into the Windows login screen.
Step 5: Log In and Recover
After the restart, you should now see the Administrator account listed on the login screen. It should not require a password (unless one was set previously).
- Log in using the Administrator account.
- Once logged in, you can use the
net usercommand (in an elevated Command Prompt) to reset your main account's password, or you can delete the corrupted NGC folder to fix your PIN issue permanently.