How to create a Windows 10 with S mode installation media

Originally, Windows 10 S was a separate edition streamlined for performance, security, and limited to the apps available in the Microsoft Store, which required its own installation media.

However, starting with Windows 10 version 1803 (April 2018 Update), Microsoft is removing the "S" edition in favor of "S mode," which offers the same locked down experience, but it's now a feature that can be enabled on Windows 10 Home, Windows 10 Pro and Enterprise.

If you want to run Windows 10 in S mode, you can create your very own USB bootable media that includes the required settings to activate S mode during the installation.

In this Windows 10 guide, we'll walk you through the steps to enable S mode in a new installation.

How to enable S mode on Windows 10

If you want to run Windows 10 in S mode, you'll need to create an unattend.xml file that must be applied to an image, which you can then use to do a clean installation of Windows 10.

How to import the installation files to your device

In order to create an installation media with Windows 10 S mode enabled, you need to open and modify an image of Windows 10, and to do that you must first import the installation files onto your device. The steps below will show you how:

  1. Open File Explorer.
  2. Navigate to the folder where you saved the Windows 10 ISO file.
  3. Right-click the ISO file, select Open with, and click File Explorer to mount it. (Alternatively, you can also connect the USB flash drive with the installation files.)
  4. Open the drive with the Windows 10 files.
  5. Select all the files using the Ctrl + A keyboard shortcut.
  6. Right-click the selection, and select Copy.

  1. Navigate to the folder that you want to use to store this project files.
  2. Right-click inside the folder and select Paste.

In order to open and modify the image, you need an install.wim file. If you have an ISO that you created using the Media Creation Tool, you're likely to have an install.esd file, which you won't be able to open.

Creating an install.wim file

If you don't have an install.wim file, you can use the DISM command tool to export the image files and create a .wim image from a .esd file using these steps:

  1. Open Start.
  2. Search for PowerShell, right-click the top result, select Run as administrator.
  3. Type the following command to identify the index number of the edition you want to use and press Enter:dism /Get-WimInfo /WimFile:C:\path\to\folder\sources\install.esdIn the command make sure to change the path to the sources folder with the install.esd file on your device.
  4. Identify the index number for the edition you want. For example, we're extracting Windows 10 Pro, which in this case has an index number of 6.
  5. Type the following command to create an install.wim file and press Enter:dism /Export-Image /SourceImageFile:C:\path\to\folder\sources\install.esd /SourceIndex:6 /DestinationImageFile:C:\path\to\folder\sources\install.wim /Compress:Max /CheckIntegrityIn the command make sure to change the path to the sources folder with the install.esd file on your device. The destination path should be the same as the source.

How to create an unattend.xml file to enable S mode on Windows 10

In order to create an answer file to enable S mode, you'll need to use the Windows System Image Manager (SIM) feature from the Windows Assessment and Deployment Kit (ADK).

Installing Windows System Image Manager

You can follow these steps to install Windows SIM on your computer:

  1. Download the Windows ADK installer for Windows 10 version 1803.
  2. Double-click the adksetup.exe file to begin the installation.
  3. Select the Install the Windows Assessment and Deployment Kit - Windows 10 to this computer option.

  1. Click the Next button.
  2. Select your privacy option.
  3. Click the Next button.
  4. Click the Accept button to agree to the license agreement.
  5. Clear all preselected items.
  6. Check the Deployment Tools package, which contains the Windows System Image Manager component.

  1. Click the Install button.
  2. Click the Close button.

Once you've completed the installation, you can continue setting up the environment to create an unattend.xml file using the Windows System Image Manager tool.

Setting up an answer file environment

In order to prepare the environment to create a new answer file project, do the following:

  1. Open Start.
  2. Search for Windows System Image Manager, click the top result to open the experience.
  3. Click the File menu, and select the Select Windows Image option.

  1. Navigate to the folder you exported the Windows 10 files.
  2. In the "sources" folder, select the install.wim image file, and click the Open button.
  3. Select an edition of Windows 10 you want to use. (It's always recommended to select the edition that you're planning to install.)
  4. Click the OK button.

  1. If you get a message, click the Yes button to create a new catalog file. (This process will take some time, but it's a one-time process. The .clg file will be saved in the same location where the install.wim is stored, and you can reuse it later on other projects.)

  1. Click the File menu, and select the Select Distribution Share option.

  1. Navigate to the folder that you're using to store the project folders and files.
  2. On "Folder name," type a name (such as Distribution) to create a folder to store additional project files.
  3. Click the Open button.
  4. Click the File menu, and select the New Answer File option.

After completing the steps, you will now have the required environment to create an answer file.

Creating a Windows 10 answer file to enable S mode

Using an answer file you can completely customize the installation of Windows 10. However, we're just configuring Windows 10 with S mode, as such will be setting up the offline servicing stage of the automation process.

In order to create the answer file to enable S mode, use these steps:

  1. Under "Windows Image," expand the Components folder.
  2. Right-click the amd64_Microsoft_Windows_CodeIntegrity component, and select the Add Setting to Pass 2 offlineServicing option.

  1. On the right side, under "Answer File," select the amd64_Microsoft_Windows_CodeIntegrity component.
  2. On the right side, under "Settings," change the SkuPolicyRequired value to 1.

  1. Click the Tools menu, and select the Validate Answer File option.
  2. If there are no errors, click the File menu, and select the Save Answer File As option.

  1. Navigate to the folder you want to save the file.
  2. Under "File name," use the unattend.xml file name.
  3. Click the Save button.

Once you've completed the steps, the unattend.xml file will be created, which you can now use to integrate into the Windows 10 image to enable S mode.

Inside the unattend.xml file the settings portion for offlineServicing should look like in the example below:

<settings pass="offlineServicing"><component name="Microsoft-Windows-CodeIntegrity" processorarchitecture="amd64" publickeytoken="31bf3856ad364e35" language="neutral" versionscope="nonSxS" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"><skupolicyrequired>1</skupolicyrequired></component></settings>

How to modify image to enable S mode on Windows 10

In this part of the process, you'll be using the DISM command line tool in PowerShell to open and apply the unattend.xml file to an install.wim image, which will enable S mode during a normal installation of Windows 10.

To modify a Windows 10 image, use these steps:

  1. Open Start.
  2. Search for Windows PowerShell, right-click the top result, and select Run as administrator.
  3. Type the following command to create a mounting point in the root of the drive and press Enter:md c:\mount\windows
  4. Type the following command to mount the install.wim image file and press Enter:dism /Mount-Wim /WimFile:c:\path\to\sources\install.wim /index:1 /MountDir:C:\mount\windowsIn the command make sure to change the path to the sources folder with the install.wim file on your PC.

  1. Type the following command to create a folder called "Panther" inside the mounted image and press Enter:md c:\mount\windows\Windows\Panther

  1. Type the following command to import the unattend.xml file to the Panther folder and press Enter:copy c:\path\to\folder\unattend.xml c:\mount\windows\Windows\Panther\unattend.xmlIn the command make sure to change the location of the unattend.xml file you want to copy to the Panther's folder.

  1. Type the following command to apply the unattend.xml file to the mounted image and press Enter:dism /Image=c:\mount\windows /Apply-Unattend=c:\mount\windows\Windows\Panther\unattend.xml

  1. Close any application that may be accessing files in the mounted image. Otherwise, you'll get errors.
  2. Type the following command to save the changes and unmount the Windows 10 image and press Enter:dism /Unmount-Image /MountDir:"c:\mount\windows" /commit

If you get an error indicating that the image couldn't be unmounted, use the

dism /cleanup-wim

command to resolve the issue.

Quick Tip: Although Windows 10 in S mode will detect and install device drivers, sometimes, you may want to add drivers to the offline image manually if you have a particular piece of hardware as you won't be able to install it after the installation.

How to create a bootable media of Windows 10 with S mode

In order to complete the installation media you must replace the install.wim or install.esd file with the modified install.wim image on the USB bootable media using these steps:

  1. Open File Explorer (Windows key + E).
  2. Navigate to the USB location with the Windows 10 installation files.
  3. Double-click the sources folder.
  4. Right-click the install.wim file, and select the Delete option.

  1. Open File Explorer again (Windows key + E).
  2. Navigate to the modified Windows 10 image (install.wim) location.
  3. Right-click the install.wim file, and select the Copy option.

  1. Right-click and select Paste in the sources folder in the USB flash drive with the installation files.

Using Media Creation Tool to create an install media

Alternatively, if you don't have a USB bootable media already created, you can use the Media Creation Tool to create one with the steps below. You'll only need to connect a USB flash drive of at least 8GB of space to your computer.

  1. Download the Windows 10 Media Creation Tool from this Microsoft Support website.
  2. Double-click the file to launch the tool.
  3. Click the Create installation media for another PC option.

  1. Click the Next button.
  2. Select the language, architecture, and edition as required. (When selecting the architecture it's recommended to use Both.)
  3. Click the Next button.
  4. Select the USB flash drive option.

  1. Select the flash drive you want to use making sure that you understand that everything will be deleted on that drive.

  1. Click the Next button.
  2. Click the Finish button.

After the installation media is created, remember to use the above steps to replace the install.esd (or install.wim) with the modified install.wim image in the USB bootable media

How to install Windows 10 with S mode enabled

Once you have the installation media created with the modified image, you can proceed to install Windows 10 as you would typically do, but the installation will now be configured with S mode enabled.

If you need assistance to perform a clean installation of Windows 10, we got you covered with this guide.

This guide outlines the steps to create a bootable media that enables S mode during the installation of Windows 10 Pro 64-bit, but the instructions should also work for Windows 10 Home and the Enterprise edition.

More Windows 10 resources

For more helpful articles, coverage, and answers to common questions about Windows 10, visit the following resources:

Mauro Huculak

Mauro Huculak is technical writer for WindowsCentral.com. His primary focus is to write comprehensive how-tos to help users get the most out of Windows 10 and its many related technologies. He has an IT background with professional certifications from Microsoft, Cisco, and CompTIA, and he's a recognized member of the Microsoft MVP community.