A virtual machine with no network is not much use. In Hyper-V, the component that connects VMs to each other and to the outside world is the virtual switch. Microsoft defines three types, and picking the right one up front saves you from redoing your network config later.
The three types
The external switch connects virtual machines to the physical network through a real network adapter (NIC) on the host. It’s what you need when a VM has to talk to other machines on the LAN, reach the internet, or be reachable from outside. When you create an external switch, Hyper-V warns that the change may briefly disrupt the host’s network connectivity, because the way that adapter is used gets reorganized.
The internal switch lets VMs talk to each other and to the host operating system, but it doesn’t touch the physical network. It fits lab setups where you want the host to reach its machines without exposing them to the corporate network.
The private switch only lets VMs communicate with each other. Neither the host nor the physical network joins the conversation. It works well to isolate a group of machines, such as a test scenario that must not leak traffic anywhere else.
How to create one
You have two routes. With the GUI, open Hyper-V Manager, go to the Actions pane, choose Virtual Switch Manager, pick the type, and select Create Virtual Switch. Give it a name and, if it’s external, choose the physical network adapter it will use.
With PowerShell the cmdlet is New-VMSwitch, always in an elevated session. List the available adapters first with Get-NetAdapter to know which one to use. For an external switch:
New-VMSwitch -Name <switch-name> -NetAdapterName <netadapter-name>
Using the -NetAdapterName parameter (or -NetAdapterInterfaceDescription) implicitly sets the type to external. For an internal or private switch, set the type yourself:
New-VMSwitch -Name <switch-name> -SwitchType <switch-type>
where <switch-type> is Internal or Private.
Sharing the NIC with the host and VLANs
On an external switch you can let the management operating system share the same adapter, by checking Allow management operating system to share this network adapter in Hyper-V Manager or running Set-VMSwitch -Name <vmswitch name> -AllowManagementOS $true.
For VLAN tagging, Hyper-V supports VLAN identification on external and internal switches. From PowerShell, Set-VMNetworkAdapterVlan covers both access mode with a specific VLAN ID and trunk mode with a native VLAN and a list of allowed VLANs (for example 200-210).
NAT on Windows
On Windows there’s also the option of NAT networking: it combines the host’s IP address with ports through an internal switch. That lets VMs reach the network using the host’s IP, conserves addresses, and lets several machines reuse the same internal ports by mapping them to different external ports. Microsoft keeps a separate guide for setting up the NAT network and connecting it to a VM.
Who it’s for
If you run Hyper-V for development or production, understanding these three types is basic before you move a single VM. The logic mirrors other hypervisors: coming from Proxmox or KVM, the external switch maps to a bridge on the physical network, the internal one to a host-only network with host access, and the private one to an isolated guest network. If you want to compare platforms, take a look at the XCP-ng 8.3 LTS update, another type 1 hypervisor with its own networking approach.