Question Is it possible to modify Windows 11 install media to add "oobe\bypassnro" command back into registry?

gernstsmit

Distinguished
Feb 16, 2010
53
5
18,535
Hello guys,

Like all techies who install Windows 11 regularly on computers for other users, installing Windows 11 without creating an online account is important. So far hitting shift-F10, entering the command oobe\bypassnro and then rebooting has been a very minor hassle. However it seems in the next build Microsoft will be blocking this option. According to articles online there is a way to unblock it:

When faced with the Microsoft Account sign-in screen, users need to open a command prompt (Shift + F10) and type:
reg add “HKLM\SOFTWARE\Microsoft\Windows\CurrentVersion\OOBE” /v BypassNRO /t REG_DWORD /d 1 /f
shutdown /r /t 0
On restart, the Shift + F10 and typing OOBE/BYPASSNRO trick will again work its magic. By this, we mean you will restart again and be able to finalize the installation offline and without a Microsoft Account.


This now becomes a real irritation. I have to enter a long command (will probably save in a text file on install media to execute, maybe even build a batch file that I can run?). But I also have to reboot twice now if I understand the procedure correctly. First boot to bring the feature back, second to execute it.

My question is this: Surely there must be a way to edit the install media so that when installing Windows 11 the above key is already present in the resigtry and does not have to be added manually? Even better, the command is pre-run and I dont' even have to enter oobe\bypassnro and reboot at all?

Obviously the easiest way to get around all of this is to keep using older install media where it is not blocked. But that will require more time wasted on Windows updates, which really slows down the process of getting a PC ready.

I'm hopeful that there are people on this forum with the skills to accomplish this. It is way above my skill level. Cheers.
 
I hope it's ok to post technical solutions to this question.

I've never had to create a Microsoft Account for Windows 10 or 11 . I always disconnect the PC from the Internet. When the oobe.networkconnectionflow package executes during the W11 install I am presented with a screen that has an option "I do not have an internet connection" which allows me to bypass the requirement for a Microsoft account.

Second, as tweaker I've found that you can also bypass the process completely by removing the oobe.networkconnectionflow package from the image.

Thirdly, you can also add the registry entry by tweaking the image - this is the method described below.

Be careful with 2 and 3. You can totally brick your image.

For method 3: Assuming you have the sources\install.wim on your install media;

1. Copy the install.wim to a temporary location. Eg C:\temp
2. Create a mount folder. Eg C:\mount
3. Mount the install.wim using DISM
4. I'm assuming there is only 1 windows version on the install media, or that the version you want is the first one (index:1)
5. This must be done from an elevated command prompt.

Code:
dism /mount-image /mountdir:c:\mount /imagefile:c:\temp\install.wim /index:1

You want to add the registry bypass in hklm\software, which is located in the c:\mount\windows\system32\config folder.
Code:
reg load "hklm\myreg" "C:\mount\Windows\System32\Config\software"
reg add "HKLM\myreg\Microsoft\Windows\CurrentVersion\OOBE” /v BypassNRO /t REG_DWORD /d 1 /f
reg unload  "hklm\myreg"

Instead of using reg add you could also just type regedit, navigate the myreg entry and manually add the key.

Now save the changes back to the install.wim file

Code:
dism /unmount-image /mountdir:c:\mount /commit

The install.wim file in C:\temp has now been modified to include the tweak.

I recommend making a copy of the install media, or at least making a backup copy of the install.wim file before proceeding.

Having made a backup copy the c:\temp\install.wim back to the install media's sources folder.

You're good to go.

Again, please be careful. If you're not famaliar with this sort of tweaking you can break your installation media.
 
You can either use Rufus to create an installation media with the Microsoft account requirement disabled (trivial to do with Rufus), or use this new trick:

Open a terminal with shift-f10 as you would do for the bypassnro and type

start ms-cxh:localonly