How to Delete Hyper-V Virtual Machine in Windows 10


Hyper-V enables running virtualized computer systems on top of a physical host. These virtualized systems (aka: guests) can be used and managed just as if they were physical computer systems, however they exist in a virtualized and isolated environment.

If you like, you can delete a Hyper-V virtual machine to remove it from the Hyper-V Manager.

When you delete a Hyper-V virtual machine, it deletes the virtual machine's configuration file, but does not delete any virtual hard drives (.vhdx). If the virtual machine has any checkpoints (aka: snapshots), these are deleted and merged into the virtual hard disk files after the virtual machine is deleted.

This tutorial will show you how to delete a Hyper-V virtual machine on your Windows 10 PC.


 CONTENTS:

  • Option One: Delete Hyper-V Virtual Machine in Hyper-V Manager
  • Option Two: Delete Hyper-V Virtual Machine in PowerShell





Delete Hyper-V Virtual Machine in Windows 10 OPTION ONE Delete Hyper-V Virtual Machine in Windows 10
Delete Hyper-V Virtual Machine in Hyper-V Manager

1. Open Hyper-V Manager (virtmgmt.msc).

2. Select the Hyper-V virtual machine (ex: "Windows 7 Ultimate") you want to delete, and perform one of the following actions: (see screenshot below)
  • Press the Del key.
  • Click/tap on Delete in the Actions pane on the far right.
  • Right click or press and hold on the virtual machine, and click/tap on Delete.

Name:  Delete_Hyper-V_virtual_machine-1.jpg
Views: 100
Size:  46.6 KB

3. When prompted, click/tap on Delete to confirm. (see screenshot below)

Name:  Delete_Hyper-V_virtual_machine-2.png
Views: 97
Size:  6.8 KB

4. When finished, you can close the Hyper-V Manager if you like.






Delete Hyper-V Virtual Machine in Windows 10 OPTION TWO Delete Hyper-V Virtual Machine in Windows 10
Delete Hyper-V Virtual Machine in PowerShell

To see more usage options for the Remove-VM command, see: Remove-VM

1. Open an elevated PowerShell.

2. Type Get-VM into the elevated command prompt, and press Enter. Make note of the Hyper-V virtual machine name (ex: "Windows 7 Ultimate") you want to delete. (see screenshot below)

Name:  Get-VM.png
Views: 106
Size:  8.9 KB

3. Type the command below into the elevated PowerShell, and press Enter. (see screenshot below)

Remove-VM "<VM name>" -Force"

Substitute <VM name> in the command above with the actual virtual machine name (ex: "Windows 7 Ultimate") from step 2 you want to delete.

For example: Remove-VM "Windows 7 Ultimate" -Force"


Name:  Delete_Hyper-V_virtual_machine_PowerShell.png
Views: 98
Size:  5.6 KB

4. When finished, you can close the elevated PowerShell if you like.


That's it,
Shawn