Set Up Hyper-V Virtual Machines in Windows 11

This guide walks you through enabling and configuring Microsoft Hyper-V to run virtual machines on Windows 11 Pro and Enterprise editions. You will learn how to verify your hardware virtualization settings, enable the Hyper-V feature, configure virtual networking, and create your first virtual machine from an operating system installation image.

Step 1: Verify Hardware Virtualization

Before enabling Hyper-V, ensure your system hardware supports virtualization and that the feature is enabled in your BIOS/UEFI firmware.

  1. Press Ctrl + Shift + Esc to open Task Manager.
  2. Select the Performance tab and click on CPU.
  3. Look at the bottom-right details for Virtualization. Ensure it says Enabled.
  4. If it is disabled, restart your PC, enter your BIOS/UEFI settings, and enable Intel VT-x or AMD-V.

Step 2: Enable Hyper-V in Windows 11

Hyper-V is a built-in feature in Windows 11 Pro, Enterprise, and Education editions, but it is turned off by default.

Option A: Using Windows Features

  1. Press the Windows Key + R, type optionalfeatures.exe, and press Enter.
  2. In the Windows Features window, locate Hyper-V.
  3. Check the box next to Hyper-V (ensure both Hyper-V Management Tools and Hyper-V Platform are selected).
  4. Click OK, wait for the installation to finish, and click Restart Now.

Option B: Using PowerShell

  1. Right-click the Start button and select Terminal (Admin) or PowerShell (Admin).

  2. Run the following command:

    Enable-WindowsOptionalFeature -Online -FeatureName Microsoft-Hyper-V -All
  3. Type Y to reboot your system when prompted.

Step 3: Configure a Virtual Switch

To give your virtual machines access to your local network and the internet, configure a virtual switch.

  1. Open the Start menu, search for Hyper-V Manager, and open it.
  2. Select your host computer name in the left sidebar.
  3. In the right-hand Actions pane, click Virtual Switch Manager.
  4. Under Virtual Switches, select New virtual network switch.
  5. Choose External (connects VM to the physical network/internet) and click Create Virtual Switch.
  6. Name your switch (e.g., “External Switch”), select your active network adapter, and click OK.

Step 4: Create a New Virtual Machine

  1. In Hyper-V Manager, go to the Actions pane and click New > Virtual Machine.
  2. In the wizard, configure the following:
    • Name and Location: Enter a name for the VM.
    • Specify Generation: Choose Generation 2 for modern 64-bit operating systems supporting UEFI and Secure Boot (use Generation 1 for legacy 32-bit OS).
    • Assign Memory: Allocate RAM (e.g., 4096 MB for 4 GB). Check Use Dynamic Memory if desired.
    • Configure Networking: Select the Virtual Switch created in Step 3.
    • Connect Virtual Hard Disk: Specify the virtual hard disk name, location, and maximum size.
    • Installation Options: Select Install an operating system from a bootable image file and browse to your downloaded .iso file.
  3. Click Finish to build the virtual machine.

Step 5: Start the Virtual Machine and Install the OS

  1. In the central pane of Hyper-V Manager, right-click your newly created virtual machine and select Connect.
  2. Click the green Start button in the Virtual Machine Connection window.
  3. Press any key if prompted to boot from the CD/DVD ISO.
  4. Follow the standard on-screen installation prompts to set up your guest operating system.