How to do a Clean Install of Windows 11 Using UnattendedWinstall & WIMUtil!

Formatting your PC and reinstalling Windows can seem intimidating, but with a structured approach, it’s a manageable and even efficient task. In this guide, I’ll walk you through how I formatted my PC, backed up essential files, and set up a fresh Windows installation using some handy tools. This process is designed to ensure you don’t lose any critical data and make the transition to a fresh Windows install as smooth as possible.

Key Takeaways

  • Back Up Before You Start: Always save important files from the drive you’re formatting to another location.
  • Streamline with Tools: Use utilities like Ventoy, WIMUtil, and UniGetUI to simplify setup and software restoration.
  • Organize User Files: Storing user files on a separate drive makes future Windows installations much easier.

Requirements

To format your PC and reinstall Windows, you’ll need:

  • A USB drive (16 GB or larger).
  • A Windows ISO file (downloadable from Microsoft).
  • Tools such as Ventoy for creating bootable media and UniGetUI for managing software reinstallation.
  • External storage or a secondary drive to back up important files.

Why Format and Reinstall Windows?

Reinstalling Windows breathes new life into your PC. Whether you’re troubleshooting issues, upgrading your operating system, or decluttering your system, a fresh install ensures optimal performance. It also gives you the chance to reorganize files and adopt best practices for file management.

Windows Setup screen with Install Now button highlighted.

Step-by-Step Process to Format Your PC

Back Up Your Data

Before formatting your PC, save all essential files from the drive you’re formatting (typically the C drive). Here’s how:

  • Identify important folders like Desktop, Documents, Downloads, and others.
  • Move these folders to an external drive or another drive on your PC.
Screenshot showing user files backed up to D drive.

If you already store user files on a separate drive (e.g., D drive), you can skip this step.


Create a Custom Windows ISO with WIMUtil

Download and Prepare the Tools

Screenshot of the Microsoft Windows 11 ISO download page.
  • Launch WIMUtil in an elevated PowerShell window via this command.

irm "https://github.com/memstechtips/WIMUtil/raw/main/src/WIMUtil.ps1" | iex

Screenshot of WIMUtil command being run in PowerShell.

Customize the ISO

  • Open WIMUtil, load your downloaded ISO file, and select a working directory.
Screenshot of WIMUtil loading a Windows ISO file.
  • Add the UnattendedWinstall Answer File:
    • Click Download UW to automatically add the latest UnattendedWinstall answer file or click Add Answer File to choose your own autounattend.xml answer file to include on the root of the installation media.
    • An answer file is a configuration file that automates setup steps like disabling unnecessary features or preloading settings.
    • WIMUtil will integrate this file into the ISO.
Screenshot of WIMUtil adding the latest UnattendedWinstall answer file to the installation media.

Export Drivers

  • Extract drivers from your current Windows installation:
    • Use WIMUtil to export drivers using DISM into the ISO.
    • The drivers will be stored in the sources\$OEM$\$1\Drivers folder of the installation media and will be automatically detected and installed during the Windows installation process.
Screenshot of WIMUtil exporting drivers from the current installation.
  • Finally, save the customized ISO to your computer.
Screenshot of WIMUtil creating the custom Windows ISO file.

Create a Bootable USB Drive with Ventoy

  • Use Ventoy to make your USB drive bootable:
    • Download and install Ventoy.
    • Run Ventoy2Disk and select your USB drive. Click Install.
Screenshot showing Ventoy installation on a USB drive.
  • Copy the New Windows ISO file created by WIMUtil to the USB drive.

Save a Software Package Bundle with UniGetUI

Create a Bundle

  • Open UniGetUI and navigate to the Installed Packages tab.
  • Select all installed apps and save them as a package bundle.
    • Save this bundle to the USB drive or an external drive.
Screenshot of UniGetUI saving a package bundle file.

Benefits of a Package Bundle

  • Use it as a reference for reinstallation.
  • Quickly reinstall apps with available sources after setting up Windows.

Prepare for Windows Installation

  • Unplug any external drives or secondary disks (optional).
  • Rename the drive you plan to format (e.g., “Delete Me”) for easy identification during installation.
Screenshot of renaming a drive in Windows Explorer.

Install Windows

  • Restart your PC and boot from the USB drive.
    • Access the boot menu, commonly F12 during startup, but you might have to check your motherboard manual for the exact key.
    • Select the UEFI option for your USB drive if it’s available, else just use the option you have available which will boot from the USB drive in Legacy/CSM mode.
Screenshot of boot menu showing UEFI option.
  • Follow the on-screen instructions to install Windows:
    • Identify the drive labeled “Delete Me” (if you renamed it as mentioned in a previous step).
    • Take note of the Disk number of the drive (labeled “Delete Me”)
    • Delete all partitions on that particular disk only until the selected drive only has “unallocated space” left.
    • Select the disk and click on Next.
    • Proceed with installation.
Screenshot of Windows installation process showing unallocated drive space.

Once Windows is installed, create a User Account in the OOBE phase and follow the prompts until you get to the desktop.

Screenshot showing Windows 11 OOBE phase prompting for a username.

What to do After Windows has been Installed

Restore Files and Set Up Software

  • Reorganize User Files:
    • Move the location of user folders like Desktop and Documents to your secondary drive where the data is stored.
Screenshot of folder location settings in Windows.
  • Reinstall Software:
    • Use UniGetUI to install previously used apps. Import your saved bundle file from the USB drive.
Screenshot of UniGetUI showing package bundle import.
  • Install Drivers:
    • Check Device Manager for missing drivers.
    • Use exported drivers from your previous installation located at C:\Drivers or download from the manufacturer’s website.
Screenshot of Device Manager showing driver installation.
StartAllBack Taskbar customization options for Windows 11.

Conclusion

Reinstalling Windows doesn’t have to be daunting. By backing up your data, using the right tools, and following a clear process, you can have your PC up and running with a fresh installation in no time. Whether it’s for maintenance, performance, or simply a fresh start, these steps ensure a smooth transition.


Frequently Asked Questions (FAQ)

Can I reinstall Windows without losing files?

Yes, you can choose to keep files during the Windows installation process. However, backing up is highly recommended.

What is the best tool for creating a bootable USB drive?

Ventoy is highly recommended for its simplicity and flexibility.

How do I check if drivers are missing after reinstalling Windows?

Open Device Manager to see if any devices are flagged with a yellow exclamation mark.

Should I disable other drives during installation?

It’s optional, but unplugging other drives reduces the risk of formatting the wrong drive.

How can I streamline software reinstallation?

Use tools like UniGetUI to create a software bundle for quick reinstallation.

2 Comments

  1. The win11 24-2 ISO woudn’t complete download @ 100% had to close all apps, reboot and eject USB’s???
    Tested first on Win10 Hyper-v, worked great. Had to answer 3 dumb questions for password recovery.
    Installed on an old Dell Precision Tower 5810 that I gather did not meet the Win11 requirements. Had to update drivers but Dell would not let me have what I needed for win11. The PCI/PCIe buses had issue’s had 70 other optional driver updates, but they all but 1 failed to install. All intel optional updates. Intel manager or some such thing, now no issues in Device Manager.
    An asside: OPNsense(FreeBSD) has real issues with Realtek network cards and DHCP. Netgate pfSense seems to have been updated and a little better. Kicking 2 realtek for 1 intel dual card tho.
    Worked great thanks, even a 66 year old pensioner can do it!

Leave a Reply

Your email address will not be published. Required fields are marked *