Azure Virtual Network

Also known as: VNet

On this page 7

Azure Virtual Network, usually shortened to VNet, is the fundamental private network construct in Microsoft Azure: a logically isolated address space in which virtual machines, containers, databases and other resources communicate securely with each other, with the internet and with on-premises networks. In cloud networking, a VNet plays the same role as a VPC in other providers, and it is the boundary within which routing, filtering and private connectivity are defined.

A VNet is scoped to one Azure region and one subscription, carries one or more IPv4 address ranges in CIDR notation and can optionally add IPv6. It costs nothing by itself; charges arise from peering traffic, gateways, NAT, firewalls and other attached services.

How an Azure Virtual Network is structured

Every VNet starts with an address space, typically a private range from RFC 1918 such as 10.20.0.0/16, which is divided into subnets. Resources attach to subnets through network interfaces, and each subnet can carry its own network security group and route table. Azure reserves five IP addresses in every subnet: the network address, the broadcast address and three addresses used for the default gateway and Azure DNS.

By default, Azure adds system routes that let all subnets in a VNet reach each other and reach the internet through outbound connectivity. Engineers override that behavior with user-defined routes, for example sending all traffic through a firewall appliance. Some services, such as Azure Bastion or a VPN gateway, require dedicated subnets with fixed names like AzureBastionSubnet and GatewaySubnet.

The table summarizes the building blocks that appear in almost every VNet design.

ElementPurposeKey detail
Address spaceDefines the private IP rangesMust not overlap with connected networks
SubnetSegments the VNet into zonesFive addresses reserved per subnet
Network security groupFilters traffic at layer 4Stateful allow and deny rules
Route tableOverrides default system routesNext hop such as a virtual appliance
Service endpointOptimized path to Azure servicesTraffic stays on the Azure backbone
Private endpointPrivate IP for a platform serviceEnables private-only access
NAT gatewayStable outbound public IP addressesAvoids SNAT port exhaustion
Building blocks of an Azure Virtual Network

Connectivity options for a VNet

A VNet becomes useful when it connects to other networks, and Azure offers several mechanisms that differ in latency, bandwidth, cost and transitivity. VNet peering links two VNets over the Microsoft backbone with low latency; global peering does the same across regions. Peering is not transitive, so if VNet A peers with B and B with C, A cannot reach C without extra routing.

Hybrid connections use a VPN gateway for encrypted IPsec tunnels over the internet or ExpressRoute for private circuits through a connectivity provider. The following comparison helps match each option with its typical use.

OptionPathTypical bandwidthBest use
VNet peeringMicrosoft backboneLimited by VM sizeLinking VNets in a region
Global VNet peeringBackbone across regionsLimited by VM sizeMulti-region applications
Site-to-site VPNIPsec over internetUp to about 10 Gbps per gatewayBranch offices, quick hybrid setup
ExpressRoutePrivate provider circuit50 Mbps to 100 GbpsPredictable enterprise hybrid traffic
Virtual WANManaged hub serviceScales with hub unitsMany sites and VNets globally
Ways to connect an Azure Virtual Network

Azure Virtual Network compared with AWS and Google Cloud

Azure Virtual Network corresponds to the Amazon VPC and the Google Cloud VPC, but the scope and filtering models differ in ways that matter during migrations. The most visible difference is that a Google Cloud VPC is global, while an Azure VNet and an AWS VPC are regional.

ConceptAzureAWSGoogle Cloud
Network scopeRegional VNetRegional VPCGlobal VPC
Subnet scopeRegionAvailability zoneRegion
Instance filteringNetwork security groupSecurity groupFirewall rules
Private service accessPrivate endpointAWS PrivateLinkPrivate Service Connect
Hub routingVirtual WAN or hub VNetTransit gatewayNetwork Connectivity Center
Equivalent concepts across major cloud providers

A subtle difference concerns subnets: Azure subnets span all availability zones of a region, so zone redundancy is set on resources rather than by creating one subnet per zone as in AWS. Teams moving from AWS often create unnecessary subnets for this reason.

Designing VNets for production

Most enterprises adopt a hub-and-spoke topology: a central hub VNet hosts shared services such as Azure Firewall, gateways and DNS resolvers, while each workload lives in a spoke VNet peered to the hub. Spokes route outbound and cross-spoke traffic through the hub firewall using user-defined routes, which gives central inspection and logging.

  • Plan addresses early: overlapping ranges block peering and hybrid links, and resizing a VNet in use is disruptive.
  • Size subnets generously: services such as Azure Kubernetes Service can consume hundreds of addresses per node pool.
  • Prefer private endpoints for storage and databases so data never needs a public endpoint.
  • Enable flow logs through Network Watcher to audit and troubleshoot traffic.

Common mistakes and their consequences

Many outages and security gaps in Azure trace back to a small set of network design errors. The table connects each symptom with its cause and a reliable correction.

SymptomCauseRemedy
Peering cannot be createdOverlapping address spacesRe-plan CIDR ranges before deployment
Spoke cannot reach another spokePeering is not transitiveRoute through a hub firewall or Virtual WAN
Intermittent outbound failuresSNAT port exhaustionAttach a NAT gateway
Private endpoint name resolves publiclyMissing private DNS zone linkLink the zone to the VNet
Unexpected open portsOverly broad security rulesRestrict sources, review rule priority
Typical VNet problems and remedies

A further misconception is that a VNet alone provides complete isolation. Resources with public IP addresses remain reachable from the internet unless security rules block them, so isolation depends on deliberate filtering, not on the VNet boundary itself.

Explained without jargon

An Azure Virtual Network is like a private office building inside a huge shared business park. Each company gets its own building with locked doors, internal corridors and rooms. Computers inside can talk to each other freely, while visitors from outside only get in through doors the company chooses to open.

The rooms are subnets, the door guards are security rules, and private tunnels can connect the building to the company headquarters. In short, a VNet keeps a company’s cloud resources private while still letting them connect where needed.

A typical use case

A regional insurance company moves its claims system to Azure. The network team creates a hub VNet with the range 10.0.0.0/16 in West Europe, containing Azure Firewall, a VPN gateway and Azure Bastion, plus three spoke VNets for production, testing and data services, each peered to the hub. An ExpressRoute circuit of 1 Gbps links the hub to the head office data center, with the VPN as a backup path.

The claims database is reachable only through a private endpoint, and user-defined routes force all spoke traffic through the firewall. After cutover, auditors could confirm from flow logs that no database traffic crossed the public internet, and the company passed its regulatory review without additional network findings.