Study guide

2.6 Azure Virtual Networks (VNet)

Microsoft Azure Fundamentals AZ-900

Track your progress as you read

Finished sections get a check mark.

1 Introduction

About the Microsoft Azure Fundamentals (AZ-900) Exam Study Strategies and Exam Tips

2 Domain 1: Cloud Concepts (25-30%)

1.1 What Is Cloud Computing? 1.2 Cloud Service Models (IaaS, PaaS, SaaS) 1.3 Cloud Deployment Models (Public, Private, Hybrid) 1.4 The Consumption-Based Model

3 Domain 2A: Azure Architecture Components

2.1 Azure Regions and Availability Zones 2.2 Azure Resource Hierarchy (Management Groups, Subscriptions, Resource Groups) 2.3 Azure Resource Manager (ARM) Overview

4 Domain 2B: Azure Compute Services

2.3 Azure Virtual Machines 2.4 Azure App Service, Containers, and Serverless 2.5 Azure Virtual Desktop

5 Domain 2C: Azure Networking Services

2.6 Azure Virtual Networks (VNet) 2.7 Azure VPN Gateway and ExpressRoute 2.8 Azure Load Balancing and Content Delivery

6 Domain 2D: Azure Storage Services

2.9 Azure Storage Accounts and Services 2.10 Azure Database Services 2.11 Azure Data Services and Analytics

7 Domain 2E: Azure Identity, Access, and Security

2.11 Microsoft Entra ID (Azure Active Directory) 2.12 Azure RBAC, Zero Trust, and Defense in Depth 2.13 Azure Security Services

8 Domain 3A: Azure Cost Management

3.1 Factors That Affect Azure Costs 3.2 Azure Pricing Calculator and Cost Management 3.3 Using Tags for Cost Management and Organization

9 Domain 3B: Azure Governance and Compliance

3.3 Azure Policy 3.4 Resource Locks and Tags 3.5 Azure Blueprints, ARM Templates, and Bicep 3.6 Azure Governance Features: Putting It All Together

10 Domain 3C: Azure Monitoring and Management Tools

3.6 Azure Monitor and Service Health 3.7 Azure Compliance, Privacy, and Trust 3.8 Azure Activity Log, Diagnostics, and Resource Health

11 Additional Azure Services and Exam Review

Azure AI and Machine Learning Services Azure IoT and DevOps Services AZ-900 Exam Review: Key Concepts Summary Common AZ-900 Exam Scenarios and Practice

12 Advanced Azure Topics and Service Deep Dives

Azure Migration Services and Tools High Availability and Disaster Recovery in Azure Azure Networking: Private Link, Service Endpoints, and Bastion Azure Management Tools: Portal, CLI, PowerShell, and Cloud Shell Azure SLAs, Service Lifecycle, and Support Plans

2.6 Azure Virtual Networks (VNet)

Key Takeaways Explain This Topic AI

An Azure Virtual Network (VNet) is the fundamental building block for private networking; it is scoped to a single region and a single subscription.

A VNet is defined by one or more private CIDR address ranges (RFC 1918), and subnets must be non-overlapping subsets that fit inside that space.

Network Security Groups (NSGs) filter Layer 3/4 traffic with priority-ordered allow/deny rules (100-4096) and attach to subnets or NICs.

VNet peering connects two VNets over the Microsoft backbone using private IPs and is NOT transitive.

Service endpoints keep traffic to PaaS on the backbone; private endpoints give a PaaS service a private IP inside your VNet.

Last updated: October 2026

Quick Answer: An Azure Virtual Network (VNet) is a logically isolated, software-defined network scoped to one Azure region and one subscription. It lets your resources talk to each other, to the internet, and to on-premises networks using private IP addresses you control.

What a Virtual Network Is

A Virtual Network (VNet) is the data-center network you would have racked and cabled on-premises, delivered as software. On AZ-900 you must know its hard boundaries: a VNet lives in exactly one region and one subscription , and resources in different regions cannot share a VNet (you connect them with peering instead).

You define a VNet by assigning one or more address spaces in CIDR (Classless Inter-Domain Routing) notation, normally from the private RFC 1918 ranges: 10.0.0.0/8 , 172.16.0.0/12 , and 192.168.0.0/16 . A /16 such as 10.1.0.0/16 yields 65,536 addresses.

Subnets and Reserved Addresses

A VNet is carved into subnets , each a non-overlapping CIDR block inside the VNet's space. Azure reserves 5 IP addresses in every subnet , so a /24 (256 total) gives you only 251 usable addresses:

  • Address in a /24 Reserved use
  • x.x.x.0 Network address
  • x.x.x.1 Default gateway
  • x.x.x.2, x.x.x.3 Azure DNS mapping
  • x.x.x.255 Broadcast

A classic exam trap: a question asks how many usable IPs a /24 subnet provides — the answer is 251 , not 256, because of these five reservations. The smallest deployable subnet is a /29 (8 addresses, 3 usable).

Default Routing and Network Security Groups

Every subnet gets Azure-provided system routes automatically: resources can reach each other inside the VNet, reach peered VNets, and reach the internet for outbound traffic with no configuration . You override these with a route table (User-Defined Route, UDR) when you must force traffic through an appliance such as a firewall.

A Network Security Group (NSG) is the stateful, Layer-3/4 packet filter. It holds security rules evaluated by priority (100-4096, lowest number wins) , each specifying source, source port, destination, destination port, protocol (TCP/UDP/Any), and Allow or Deny . Because NSGs are stateful , an allowed inbound flow's return traffic is permitted automatically.

Key NSG facts for the exam:

An NSG attaches to a subnet , a network interface (NIC) , or both; when both apply, inbound traffic must pass the subnet NSG then the NIC NSG.

Every NSG has default rules you cannot delete: inbound AllowVNetInBound , AllowAzureLoadBalancerInBound , and DenyAllInBound ; outbound AllowVNetOutBound , AllowInternetOutBound , and DenyAllOutBound .

The implicit final rule is deny all — if no higher-priority rule allows a flow, it is dropped.

Worked example: To expose a web server on port 443 from the internet you add an inbound rule, e.g. priority 300 , source Internet , destination port 443 , protocol TCP , action Allow . Without it, the default DenyAllInBound rule (priority 65500) blocks the request. To allow only your office, set source to your public IP/CIDR instead of Internet .

Connecting VNets: Peering

VNet peering links two VNets so resources communicate using private IP addresses over the Microsoft backbone — never the public internet, giving low latency and high bandwidth. Two flavors exist:

  • Peering type Scope
  • Regional VNet peering VNets in the same Azure region
  • Global VNet peering VNets in different regions

The key rule: peering is not transitive. If A peers with B and B peers with C, A and C still cannot talk unless you peer A and C directly (or route through a hub VNet running a gateway/firewall). A common trap answer claims peering is automatically transitive — it is not.

Securing PaaS Access: Service Endpoints vs. Private Endpoints

By default, PaaS services like Azure Storage and Azure SQL Database are reached over public endpoints . Two features bring that traffic into your private network, and they are easy to confuse:

Feature What it does Result

Service endpoint Extends the VNet identity to the PaaS service so traffic stays on the Microsoft backbone Service keeps its public IP; you restrict it to specific subnets

Private endpoint Deploys a network interface with a private IP inside your subnet that maps to the PaaS resource Service is reachable by private IP; public access can be disabled

Use a private endpoint when the requirement is "the storage account must have a private IP" or "no public exposure at all." Use a service endpoint when you simply want to lock a PaaS resource to traffic originating from named subnets without paying for per-endpoint resources.

Name Resolution: Azure DNS

Azure DNS hosts your public DNS zones on Microsoft's global anycast name servers and carries a 100% availability SLA for DNS query responses — one of the few Azure services with a 100% SLA. For internal records, Azure Private DNS zones resolve names within and across linked VNets without a custom DNS server.

Common Traps to Memorize

A VNet cannot span regions — use global peering or a VPN/ExpressRoute connection instead.

A /24 subnet has 251 usable IPs, not 256.

Peering is non-transitive ; a hub-and-spoke design needs a gateway or firewall in the hub for spoke-to-spoke traffic.

NSGs filter at Layer 3/4 ; they do not inspect HTTP paths — that is Application Gateway's job (covered in 2.8).

A private endpoint gives the PaaS service a private IP ; a service endpoint does not .