Windows

Hyper-V Network Setup: Creating and Managing Virtual Switches

This guide explains how to set up network connections for virtual machines in Hyper-V, including creating virtual switches and configuring adapters.

Updated at February 16, 2026
10-15 min
Medium
FixPedia Team
Применимо к:Windows 10 Pro/EnterpriseWindows 11 Pro/EnterpriseWindows Server 2019Windows Server 2022

Introduction

Hyper-V is Microsoft's hypervisor for virtualization on Windows and Windows Server. Network configuration is a critical step that determines whether virtual machines (VMs) can access the internet, communicate with the host system, and interact with other VMs. This guide will detail how to create and configure Hyper-V virtual switches (external, internal, and private) and connect VMs to them. Upon completion, you will have a fully functional network infrastructure for your VMs.

Requirements / Preparation

Before you begin, ensure that:

  • You have Windows 10 Pro/Enterprise, Windows 11 Pro/Enterprise, or Windows Server 2019/2022 installed.
  • The Hyper-V role is enabled. To verify:
    • On client Windows: open Control PanelPrograms and FeaturesTurn Windows features on or off and confirm the Hyper-V checkbox is selected.
    • On Windows Server: in PowerShell, run Get-WindowsFeature -Name Hyper-V (it should be installed).
  • You have administrator privileges.
  • To create an external switch, a physical network adapter (e.g., Ethernet or Wi-Fi) that is not used by other virtual networking services (VPN, Docker, etc.) is required.
  • It is recommended to temporarily disable antivirus or firewall software that might block the creation of virtual adapters.

Step 1: Opening Hyper-V Manager

Hyper-V Manager is the graphical management console. Launch it:

  1. Click Start and type Hyper-V Manager, then select the application.
  2. Or press Win + R, type virtmgmt.msc, and press Enter.
  3. If Hyper-V is not installed, you will see an error. In this case, return to the Requirements section and install the role.

A Hyper-V Manager window will appear with a list of hosts (usually your local computer).

Step 2: Creating an External Virtual Switch

An external switch allows VMs to directly use a physical network adapter, gaining access to the local network and the internet.

  1. In the Actions menu (on the right), select Virtual Switch Manager.
  2. In the Virtual Switches section, click Create Virtual Switch.
  3. Select the External type and click Next (or Create in older versions).
  4. In the Name field, enter a descriptive name, e.g., ExternalSwitch.
  5. In the Connection to section, select a physical network adapter from the list (e.g., Ethernet or Wi-Fi).

    ⚠️ Important: If the adapter is already in use (e.g., for VPN or teamed connections), you may get an error. Select a free adapter or free up the current one.

  6. Leave the options:
    • Allow management operating system to share this network adapter (allows the host to use this switch).
    • Enable virtual LAN identification (recommended).
  7. Click OK. A warning about restarting the adapter will appear—agree.
  8. After successful creation, the new external switch will appear in the switch list. Close the manager.

In Windows Network Connections, a new adapter named vEthernet (ExternalSwitch) will appear.

Step 3: Creating an Internal or Private Switch

An internal switch provides communication between VMs and the host system. A private switch allows communication only between VMs (the host does not participate).

  1. Open Virtual Switch Manager again.
  2. Click Create Virtual Switch.
  3. For an internal switch, select the Internal type. For a private switch, select Private.
  4. Enter a name, e.g., InternalSwitch or PrivateSwitch.
  5. Click OK.
  6. For an internal switch: on the host, an adapter named vEthernet (InternalSwitch) will appear in Network Connections. It will need to be configured manually (e.g., assign IP 192.168.1.1) so the host and VMs can communicate.
  7. For a private switch, no adapter is created on the host—only VMs connected to it will see each other.

Step 4: Configuring Virtual Machine Network Adapters

Now connect your VMs to the created switches.

  1. In Hyper-V Manager, select a virtual machine from the list.
  2. Click Settings (or right-click → Settings).
  3. In the left pane, select Add Hardware.
  4. From the list, select Network Adapter and click Add.
  5. In the Network Adapter section:
    • In the Virtual Switch field, select the created switch from the list (e.g., ExternalSwitch for internet access).
    • You can enable Enable virtual LAN identification (usually on by default).
  6. Click OK.
  7. Repeat for other VMs, assigning the appropriate switches:
    • For internet access — external.
    • For communication with the host — internal.
    • For isolation between VMs — private.
  8. If multiple networks are needed (e.g., internet and an internal network), add multiple network adapters in the VM settings and select different switches for each.

Step 5: Verifying Network Connectivity

After configuration, verify that the network works.

  1. Start the virtual machine.
  2. Inside the VM, open Command Prompt or PowerShell.
  3. Check IP address acquisition:
    • Run ipconfig /all.
    • For an external switch, the IP should be from your local network (e.g., 192.168.1.100), with a gateway and DNS.
    • For internal/private switches, the IP will be from the range you configure (e.g., 192.168.2.10).
  4. Check internet access (for external switch):
    • Run ping 8.8.8.8 (Google DNS). If you get replies—internet works.
    • Try opening a website in the VM's browser.
  5. Check communication with the host (for internal switch):
    • On the host, find the IP address of the vEthernet (InternalSwitch) adapter via ipconfig (e.g., 192.168.1.1).
    • From the VM, ping that address: ping 192.168.1.1.
  6. Check communication between virtual machines (for internal/private switches):
    • Find the IP addresses of other VMs connected to the same switch.
    • Ping them from the current VM.

Result Verification

After all steps, the network should function correctly:

  • External switch: VMs have access to the internet and local network, receiving IPs via DHCP from your router.
  • Internal switch: The host system and all VMs connected to it can exchange packets (e.g., the host can ping VMs and vice versa). For internet access via the host, Internet Connection Sharing (ICS) or routing may need to be configured.
  • Private switch: Only VMs connected to the same private switch can see each other. The host does not participate.

If all ping tests pass and resources are accessible—configuration is successful.

Potential Issues

1. Error when creating external switch: "Failed to bind virtual switch to physical adapter"

  • Cause: The physical adapter is in use by other software (VPN, VMware, VirtualBox) or is part of a teamed connection.
  • Solution:
    • Disable conflicting programs (e.g., disconnect the VPN client).
    • Select a different free physical adapter.
    • Ensure the adapter is not disabled in "Network Connections".

2. Virtual machine does not receive an IP address (DHCP)

  • Cause:
    • For external switch: DHCP server on the physical network is unavailable or blocking requests.
    • For internal switch: No DHCP server or static IP configured on the host's virtual adapter.
  • Solution:
    • External: Check that the physical network has DHCP (usually the router). Restart the VM or run ipconfig /release followed by ipconfig /renew inside it.
    • Internal: On the host, configure a static IP on the vEthernet (InternalSwitch) adapter (e.g., 192.168.1.1/24). In the VM, configure a static IP in the same subnet (e.g., 192.168.1.2) and gateway 192.168.1.1 if internet access via the host is needed.

3. No internet access from VM, although IP is obtained

  • Cause: Incorrect gateway or DNS servers, or a firewall blocking traffic.
  • Solution:
    • Check IP settings in the VM (ipconfig /all): the gateway should match your router's address on the physical network (e.g., 192.168.1.1). DNS can be set to 8.8.8.8.
    • Temporarily disable the firewall on the host and in the VM for testing.
    • Ensure the physical adapter bound to the external switch has internet access.

4. IP address conflicts

  • Cause: Two devices on the same network (e.g., two VMs or a VM and the host) have the same IP.
  • Solution:
    • Check IP addresses of all devices on the network segment (via arp -a or viewing DHCP leases on the router).
    • Change duplicate addresses to unique ones. For static IPs, assign manually; for DHCP, ensure the range excludes static addresses.

5. Internal switch not working (host cannot see VM)

  • Cause: The vEthernet (InternalSwitch) adapter on the host is disabled or not configured.
  • Solution:
    • Open Network Connections on the host, locate vEthernet (InternalSwitch), right-click → Enable.
    • Configure the IP address: open the adapter's properties, select IPv4, set a static IP (e.g., 192.168.1.1) and subnet mask 255.255.255.0.
    • In the VM connected to the same internal switch, configure an IP in the same subnet (e.g., 192.168.1.2) and gateway 192.168.1.1 if internet access via the host is needed.

6. Poor network performance

  • Cause: Outdated drivers, missing Integration Services, or incorrect switch settings.
  • Solution:
    • Install the latest Windows updates and drivers for the physical network adapter.
    • Inside the VM, install Integration Services (in the VM's menu: ActionInsert Integration Services Setup Disk).
    • For the external switch, ensure the selected physical adapter is high-speed (Gigabit Ethernet) and that the cable/router are not bottlenecks.

F.A.Q.

Which type of virtual switch should I choose for internet access?
Why doesn't the virtual machine see the network after configuration?
Can I have multiple virtual switches simultaneously?
How to set a static IP for a virtual machine in Hyper-V?

Hints

Open Hyper-V Manager
Create an external virtual switch
Create an internal or private switch
Configure virtual machine network adapters
Verify network connectivity

Did this article help you solve the problem?

FixPedia

Free encyclopedia for fixing errors. Step-by-step guides for Windows, Linux, macOS and more.

© 2026 FixPedia. All materials are available for free.

Made with for the community