How To Create And Mount A VHD In Windows 11 (2026)
A virtual hard disk (VHD) is a single file that Windows can show as if it were a separate drive.
Windows 11 lets you create one in Disk Management in under a minute, then attach it, use it and detach it when you are done.
The steps below follow Microsoft’s Disk Management and DiskPart pages.
Quick answer
| Task | Where to do it |
|---|---|
| Create a VHD | Disk Management > Action > Create VHD |
| Attach an existing VHD or VHDX | Disk Management > Action > Attach VHD |
| Detach it | Right-click the VHD in Disk Management > Detach VHD |
| Use the command line | DiskPart: create vdisk, select vdisk, attach vdisk |
Before you start
Microsoft says you must be a member of the Backup Operators or Administrators group to create a VHD.
Open Disk Management with administrator permissions by searching for Disk Management from the Start menu.
A VHD is only a file, so pick a folder on a drive with enough free space for the size you plan to choose.
Create a VHD in Disk Management
- Search for Disk Management in the Start menu and open it with administrator permissions.
- Select the Action menu, then select Create VHD.
- In the Create and Attach Virtual Hard Disk window, select Browse next to Location and choose a folder.
- Type a file name and select Save, then select OK to close the file picker.
- Enter the Virtual hard disk size.
- Choose the Virtual hard disk type, either Dynamically expanding or Fixed size.
- Select OK.
Microsoft says the location must be a fully qualified path and must not be inside the Windows folder.
The smallest size Microsoft allows is 3 MB, and a large fixed-size VHD can take extra time to create.
Microsoft says a VHD is created and initialized at the same time, and that a VHD can only be a basic disk.
Dynamically expanding or fixed size
| Type | What it does |
|---|---|
| Dynamically expanding | Grows to hold your data, up to the maximum you set |
| Fixed size | Allocated size never changes, and creation takes longer because the whole file is set aside up front |
Microsoft’s DiskPart page gives an example of the difference: a 24 GB dynamically expanding VHD starts at about 80 MB on the host drive, while a 24 GB fixed VHD takes about 24 GB.
That page is archived documentation for Windows 7, so the numbers are an illustration rather than a Windows 11 guarantee.
Start using the new disk
Once it is attached, the VHD shows up in Disk Management as a disk, and Microsoft says an attached VHD has a blue disk icon.
From there you can create a volume on it the same way you would on any new drive.
Our guide to setting up a new drive in Windows 11 covers the volume and drive letter steps, and changing a drive letter covers the letter.
Attach an existing VHD or VHDX
- Open Disk Management with administrator permissions.
- Select Action, then select Attach VHD.
- In the Attach Virtual Hard Disk window, select Browse.
- Choose the .vhd or .vhdx file and select OK.
- Select OK again to finish.
Microsoft’s page says the same Disk Management steps work on Windows 10 and Windows 11.
Detach a VHD
- Open Disk Management with administrator permissions.
- Find the VHD in the disk list.
- Right-click the VHD and select Detach VHD.
- Select OK.
Microsoft warns that detaching makes the disk unavailable but does not delete the VHD file or its data.
A detached VHD appears with a gray icon, and you can attach it again later with Action > Attach VHD.
Use DiskPart instead
DiskPart does the same job from a Command Prompt that you opened as administrator.
| Command | What Microsoft says it does |
|---|---|
| create vdisk file=”c:\test\test.vhd” maximum=2000 type=expandable | Creates a 2 GB dynamically expanding VHD |
| create vdisk file=”c:\test\test.vhd” maximum=1000 | Creates a 1 GB fixed VHD, because fixed is the default |
| select vdisk file=”c:\test\test.vhd” | Selects the VHD so later commands apply to it |
| attach vdisk | Attaches the selected VHD so it appears as a local hard disk drive |
| attach vdisk readonly | Attaches it read-only, so any write returns an error |
The maximum value is in megabytes, and Microsoft says DiskPart requires your account to be in the local Administrators group or a similar group.
Microsoft says you must select a VHD with select vdisk before attach vdisk works, and that a volume already on the VHD gets a drive letter when it attaches.
Attach with PowerShell
Microsoft’s Mount-DiskImage page says the cmdlet mounts a virtual hard disk or an ISO file so it appears as a normal disk.
It needs the full path to the file, and mounting a VHD requires administrator privileges.
A VHD mounts read-write unless you add the Access parameter, and Microsoft lists ReadOnly as one value.
For ISO files, see our guide to mounting an ISO file in Windows 11.
If something goes wrong
| Problem | What to check |
|---|---|
| Create VHD is unavailable or fails | Open Disk Management as administrator and confirm you are in the Administrators or Backup Operators group |
| The save location is rejected | Use a full path that is not inside the Windows folder |
| Mount says the file is in use | Microsoft says the file may already be mounted, because it fails with “being used by another process” in that case |
| You need a bigger or smaller drive | Create a new VHD with the size you want |