
close
close
If you want to spin up an isolated Windows 10 desktop quickly, without the knowledge required to work with virtual machines (VM) or the cloud, then Windows Sandbox is the answer.
Windows Sandbox is a feature in Windows 10 Pro, Enterprise, and Education SKUs, which provides users an easy way to quickly test apps in isolation. It uses a clean operating system image that is generated from your system’s current state, so there’s no need to download and install Windows.
advertisment
When you start Windows Sandbox, there’s a short delay while the image is provisioned in a VM. Because the VM is generated from your current Windows system, it is always up to date with the same version of Windows and patches as the host device.
When the VM is ready, you can install apps and change the OS configuration inside the VM. When Windows Sandbox is restarted, the image is regenerated, wiping any changes you made in the previous session.
Table of Contents
Before you can install Windows Sandbox, you should make sure that your device meets the following prerequisites:
You can check whether virtualization is enabled for your CPU using Task Manager.
advertisment
If you want to try out Windows Sandbox in a Hyper-V VM, make sure that nested virtualization is enabled for the VM.
Set-VMProcessor -VMName 'Windows 10' -ExposeVirtualizationExtensions $true
Get-VMProcessor -VMName 'Windows 10' | Select-Object ExposeVirtualizationExtensions
Once you are sure that you can run Windows Sandbox, the easiest way to get it installed is using PowerShell.
Enable-WindowsOptionalFeature -FeatureName "Containers-DisposableClientVM" -All -Online
Once the Windows Sandbox VM has started, you can use it like you would use the host device. There are a couple of caveats, however.
You can use configuration files to customize a limited set of Windows Sandbox options. Here is a list of the options that can be configured:
advertisment
Windows Sandbox configuration files are associated with the .wsb file extension. Any time you double click a file with the .wsb extension, Windows Sandbox will be started using the settings in the file.
Windows Sandbox configuration files follow a simple XML format. You can find full documentation on Microsoft’s website here. The following example maps a folder in the VM to a location on the host device. It then runs a script (VSCodeInstall.cmd) from the host, which installs Visual Studio Code in the Windows Sandbox VM.
<Configuration> <MappedFolders> <MappedFolder> <HostFolder>C:\SandboxScripts</HostFolder> <ReadOnly>true</ReadOnly> </MappedFolder> <MappedFolder> <HostFolder>C:\CodingProjects</HostFolder> <ReadOnly>false</ReadOnly> </MappedFolder> </MappedFolders> <LogonCommand> <Command>C:\Users\WDAGUtilityAccount\Desktop\SandboxScripts\VSCodeInstall.cmd</Command> </LogonCommand> </Configuration>
Windows Sandbox is a useful feature that lets users test software or experiment with configuration changes, without touching the host OS or configuring a VM manually. The only real disadvantage is that the Windows Sandbox VM never survives a reboot, which limits its application because some software cannot be installed without restarting Windows.
More in Windows 10
Microsoft to Start Notifying Windows 8.1 Users About Upcoming End of Support
Jun 24, 2022 | Rabia Noureen
Microsoft's Out-Of-Band Patch Fixes Microsoft 365 and Azure AD Sign-In Issues on ARM Devices
Jun 21, 2022 | Rabia Noureen
Microsoft is Investigating Sign-In Issues Affecting Microsoft 365 and Azure AD on ARM Devices
Jun 20, 2022 | Rabia Noureen
Microsoft to Fix Windows Bug Breaking Wi-Fi hotspots After Installing Latest Patch Tuesday Update
Jun 17, 2022 | Rabia Noureen
Microsoft's June 2022 Patch Tuesday Updates Fix Several Remote Code Execution Vulnerabilities
Jun 15, 2022 | Laurent Giret
Most popular on petri