Microsoft recently announced and released a new feature they call “Cloud Rebuild” which is a way to reinstall a Windows PC with a fresh download of the OS directly from Microsoft ( Windows update ). This is can used either directly from Windows or from WinRE ( Recovery environment ) if the PC fails to start correctly.
https://support.microsoft.com/en-us/windows/experience/backup-recovery/cloud-rebuild
https://learn.microsoft.com/en-us/windows/configuration/cloud-rebuild/
My question when I saw this was, can this be used for a bare metal deployment as well? Meaning, if there is no OS at all on the system, can we leverage Cloud Rebuild to download a fresh version of the OS and Install ? Short answer is – Yes! we can.
There are more to it than just Cloud Rebuild of course and this post is only to show how I got it working. To be honest I think with the current limitations there are probably better solutions out there but hey Its always fun to tinker with stuff.
We need:
– Win11 OS patched to support this new Cloud Rebuild ( October 2026 preview update KB5127936 or later )
– Build script from my Github repo
– USB stick
– Internet connection
I tested this on both Virtual machines and physical hardware and I got it working on all of it. Once the solution was working the main blockers is network connectivity in the sense of driver support. But this is not something new for anyone who’s been doing Operating system deployment ( OSD ) or bare metal deployments in the past. Your temporary OS environment needs the correct drivers to be able to connect to the world wide web.
Cloudrebuild CSP and Rebuild.exe
I wont dive to much in to the CSP policy in Windows as its only used by a MDM. In this scenario we are looking at today there is no MDM solution like Intune involved at all and since we are not runnings a full OS instance we have no need to use it either. But the policy is whats calling for the Rebuild.exe if used.
./Device/Vendor/MSFT/Recovery/CloudRebuild/
For our purpose we will call the rebuild.exe directly, skipping the CSP.
Rebuild.exe is located in X:\Windows\System32\Rebuild.exe within WinRE ( not sure if its part of newer version of WinPE ).
This executable is whats kicks off the process. This executable
Intent JSON
The json blob contains the information needed to tell the service which OS version to deliver to the system. This is handled by the Rebuild.exe in one of 2 ways.
-ScanOS this is used when there is a full OS on the system. It scans and identifies what version it should download, stage and Install. But in our case, we can’t use this as we have no full OS on this system.
-UseJson Here we can specify what version we want. If the specific version or Edition does not exist, you will get an error message. I tested a few different version and got it working but to my knowledge there is no public way of knowing what version are available through this service. Its down to trial and error.
{"product":"Client.OS.RS2.amd64","version":"10.0.26300.9974","branch":"ge_release","targeting":{"CBMRScan":"1"},"session_data":{"ModuleID":"DesktopCleanInstall","Edition":"Professional","SystemLanguage":"en-us","UserLanguages":["en-us"]}}

I also tried during my testing if there was a way to always get the latest version possible, but could not figure that out. If the version is not correct it will give you nothing more than an error code and a blank stare.
If the version in the JSON is not one Windows Update currently offers, Rebuild.exe stops during the scan and nothing is installed.
Version matches: The full OS Build number 10.0.26300.9974, must correspond to a build that’s offered by Windows Update, if the number is incorrect or not offered it will fail.
The error is 0xC1900500: Normally you get a page saying “Cloud rebuild failed. Error occurred during Rebuild.” With -Skip confirm there is no page at all; the program just exits with code 1, and the code is only in the log (X:\Windows\Logs\Rebuild\setupact.log).
It fails early: The scan is the first thing that talks to Windows Update, before any download. But for example a mistyped number (10.0.263000.99999) took several minutes to be rejected by the service.

Test it out !
First, download the build from the Github Repo: https://github.com/timmyit/BareMetalCloudRebuild
Once you have that, all you need to do is to run the buildscript on a Windows 11 machine with has the latest Cumulative updates.

Run the Build-RebuildUsb.ps1 script to create the necessary files needed to be put on the USB stick.
It creates the WinRE Image used during the process.



Next we will format a USB-stick, see options below from Rufus https://rufus.ie/en/

Copy the files located in the CloudRebuildLab\out\usb-files folder to the USB-stick.


Now we can use that USB.
The machine boots up on the USB-stick and gets presented with this UI here where some information is shown and can also be modified if needed. Once happy, selecting S and then typing in ERASE will format the drive on the machine and launch the Rebuild.exe to start downloading and applying the OS Image.
Booting on to the USB

GUI shows 1-7 which is the information sent to the service, this information can be changed but if it does not correspond with something that the service expects or offers it wont work and you’ll get an error message.
If you want to test and make sure the config is correct you can test it with “P”

Once happy, select “S” and then type “ERASE” to start the format of the drive and the cloud rebuild process.






Finished !
Here’s a video on how it looks like on a Virtual machine:
Github Repo
https://github.com/timmyit/BareMetalCloudRebuild
This repo contains all the source files and also instructions on how to use it.

That’s it for this time. If this was useful and you want more of the same, you can find me on X (twitter) @timmyitdotcom or over on LinkedIn