☁️ Azure Network Cheatsheet

All Azure networking requirements, best practices, limits and SKU comparisons in one place. Stop digging through hundreds of Microsoft docs pages.

Last updated: March 2026
GitHub · LinkedIn
🏗️

Hub & Spoke Layout — Best Practice

Hub for networking only, shared services in a dedicated Spoke
💡
The Hub VNet should contain only networking infrastructure (Gateway, Firewall, Bastion, Route Server). Shared services (jump boxes, monitoring, etc.) belong in a dedicated Spoke VNet. Private Endpoints should be deployed alongside their application in the same Spoke VNet — not centralized. For central services PEs (e.g. Key Vault, monitoring), place them in the Shared Services Spoke. Consider using one Spoke per service/usage to simplify filtering and segmentation.
📄 Docs: Hub-spoke topology · 📄 Docs: Plan IP addressing

Hub VNet (/21 recommended — networking only)

🔗 GatewaySubnet
/27
27 IPs — VPN + ExpressRoute GW
🔥 AzureFirewallSubnet
/26
59 IPs — Centralized firewall
🔥 AzureFWMgmtSubnet
/26
59 IPs — If forced tunneling
🖥️ AzureBastionSubnet
/26
59 IPs — Secure RDP/SSH access
🔄 RouteServerSubnet
/27
27 IPs — BGP route exchange

Dedicated Spoke VNets (peered to Hub)

🌐 Spoke: DNS Resolver
/26
2 subnets /28 (inbound + outbound). Delegation required on each
🛠️ Spoke: Shared Services
/24
Jump boxes, monitoring, DevOps runners + PEs for central services (Key Vault, monitoring…)
📦 Spoke: App A
/24
App VMs/containers + app-specific PEs (SQL, Storage…) colocated
📦 Spoke: App B
/24
Another workload — one Spoke per service/usage aids segmentation
💡
Private Endpoints placement: deploy PEs in the same Spoke as their application, not in a centralized PE VNet. This keeps traffic local, simplifies NSG rules, and improves segmentation. For shared/central PEs (Key Vault, monitoring), use the Shared Services Spoke. Using one Spoke per service/usage makes filtering and segmentation easier (optional but recommended).
⚠️
Private Endpoint network policies must be enabled on the PE subnet to allow NSG and UDR to apply to Private Endpoint traffic. Without this, NSG rules are bypassed. Set private_endpoint_network_policies = Enabled in Terraform or enable via Azure CLI:
az network vnet subnet update --disable-private-endpoint-network-policies false
📄 Docs: Manage network policies for Private Endpoints
🔀

Azure Virtual WAN

Microsoft-managed global network backbone

Components

🌐 Virtual WAN Resource

The top-level container that holds all virtual hubs. One vWAN resource per organization is typical, with multiple hubs deployed across regions for global connectivity.

📄 Docs: What is Azure Virtual WAN?

🏗️ Virtual Hub

A Microsoft-managed VNet in a region. Acts as the central routing engine. Contains gateways (S2S VPN, P2S, ExpressRoute) and connects VNets as spokes. Default throughput: 3 Gbps, scalable up to 50 Gbps.

📄 Docs: Virtual hub settings

🔗 Connections

VNets, VPN sites, ExpressRoute circuits, and P2S users connect to the hub via connections. VNet connections replace traditional peering — no manual peering needed.

📄 Docs: Configure site-to-site connection

🛣️ Hub Routing

Automated any-to-any transit between all connections (VNets, branches, users). Supports custom route tables for segmentation and isolation (e.g. isolating dev from prod).

📄 Docs: About virtual hub routing

Basic vs Standard Hub

Feature Basic Standard
Site-to-Site VPN
Point-to-Site VPN (User VPN)
ExpressRoute
Inter-hub transit (global any-to-any)
VNet-to-VNet transit
Azure Firewall / NVA
Custom route tables
Max hub throughputVPN onlyUp to 50 Gbps aggregate
Max VNet connectionsLimitedUp to 1,000
Max S2S VPN connectionsLimitedUp to 1,000
UpgradeBasic → Standard (one-way, cannot downgrade)
Use CaseSimple S2S VPN onlyEnterprise, multi-region, hybrid
📄 Docs: Upgrade Basic to Standard · 📄 Docs: Gateway settings
💡
Virtual WAN vs Hub-and-Spoke: vWAN is Microsoft-managed and provides automatic transit routing, global hub-to-hub connectivity, and integrated gateways. A custom hub-and-spoke gives you full control over the Hub VNet (NVAs, custom routing, third-party firewalls). Choose vWAN for large scale, multi-region, many branches. Choose custom hub-and-spoke for full control and customization.
📄 Docs: Virtual WAN transit connectivity · 📄 Docs: Choose your networking architecture
⚠️
When deploying Azure Firewall in a vWAN hub, allocate at least a /22 address space for the hub to allow the firewall to scale to maximum throughput.
📄 Docs: Virtual WAN FAQ

Routing Intent — Strongly Recommended

💡
Routing Intent is the recommended way to configure routing in Virtual WAN. While not mandatory, it provides a simple, effective, and extensible model that eliminates the need for manual route table management. Enable it on every secured hub.

🎯 What is Routing Intent?

A declarative way to tell the vWAN hub: "send all Internet traffic and/or all private traffic through my security solution". No manual route tables, no UDRs — the hub automatically programs the correct routes for all connections (VNets, branches, users).

📄 Docs: Configure routing policies

📋 Two Routing Policies

Internet Traffic Policy — Hub advertises 0.0.0.0/0 to all connections. All internet-bound traffic flows through Azure Firewall / NVA / SaaS security in the hub before reaching the internet.

Private Traffic Policy — All east-west traffic (VNet-to-VNet, branch-to-VNet, inter-hub) flows through the security solution. Full inspection of private traffic across the entire topology.

📄 Docs: About routing intent

✅ Why use it?

Simple — No manual route tables or propagation config. Declare your intent, the hub handles the rest
Effective — Guarantees all traffic is inspected. No risk of misconfigured routes creating bypass paths
Extensible — Works with Azure Firewall, third-party NVAs, and SaaS security solutions. Add hubs or connections without reconfiguring routing
Multi-hub — Policies apply per hub but work across inter-hub links for global security enforcement

📄 Docs: Virtual hub routing
Routing Policy What it does Route advertised Security solution
Internet Traffic All internet egress from VNets, branches, and users goes through the hub's security solution 0.0.0.0/0 Azure Firewall, NVA, or SaaS
Private Traffic All east-west traffic (VNet↔VNet, branch↔VNet, hub↔hub) goes through the hub's security solution RFC1918 + all VNet/branch prefixes Azure Firewall, NVA, or SaaS
⚠️
Limitations: One Internet policy and one Private policy per hub. Routing intent applies to all prefixes in a category — no per-prefix granularity. Enabling routing intent replaces any existing custom route tables on the hub. Plan your migration carefully if already using custom routing.
📄 Docs: Routing intent known limitations
🧭

When to Choose Hub & Spoke vs Virtual WAN

Decision matrix for architecture selection
Decision Area Prefer Hub & Spoke Prefer Virtual WAN (Standard)
Scale Single region or limited number of VNets/branches. Many VNets, many branches/users.
Multi-Region Requires manual peering, transit VNets, or VPN mesh between regional hubs — complex to build and maintain. Native global hub-to-hub transit with automatic any-to-any routing. Strongly recommended for multi-region deployments.
Network Control Maximum control over UDR, BGP propagation, peering flags, and custom NVA insertion. Prefer Microsoft-managed connectivity and routing abstractions.
Routing Model Need granular custom routes and per-subnet exceptions. Want a simplified model using hub route tables and Routing Intent.
Branch Connectivity Few branches or existing central gateway/NVA design. Large branch footprint (S2S/P2S/ER) with global transit requirements.
Operations Effort Team can operate custom hub networking at day-2 (routing, policy drift, troubleshooting). Team wants faster rollout and lower operational overhead.
Typical Fit Custom landing zones with strict bespoke design constraints. Enterprise scale, repeatable global architecture, standardized operations.
📄 Docs: Hub-spoke topology · 📄 Docs: Virtual WAN overview · 📄 Docs: Routing Intent
💡
Practical recommendation: For a single-region deployment with strong custom routing/security requirements, Hub & Spoke gives maximum control. For multi-region architectures, choose vWAN Standard + Routing Intent — it provides native global hub-to-hub transit, automatic any-to-any routing, and drastically reduces operational complexity compared to manually meshing regional hubs.
📄 Docs: Global transit network architecture
⚠️
Migration note: moving from custom hub-and-spoke to vWAN often requires route/security redesign and phased cutover by region. Validate asymmetric routing risks and inspect effective routes before each migration wave.
📄 Docs: Migrate from hub-and-spoke to Virtual WAN · 📄 Docs: Next Hop diagnostic
📐

Subnet Sizing by Service

Minimum subnet size required for each Azure service
⚠️
Azure reserves 5 IPs per subnet (first 4 addresses and last address of the range). A /28 = 16 IPs, only 11 usable. A /26 = 64 IPs → 59 usable. Always plan larger since subnets cannot be resized once resources are deployed.
📄 Docs: Reserved IPs
Service Subnet Name Min CIDR Usable IPs Recommended Notes Docs
Azure VMware Solution/221019/22For AVS clusters 📄
App Service Environment v3/24251/24Delegation required. Isolated PaaS hosting 📄
Azure Kubernetes Service (CNI)/24251/21 to /161 IP per pod + 1 IP per node. Plan for scaling 📄
Azure FirewallAzureFirewallSubnet/2659/26Name mandatory. One per VNet 📄
Azure Firewall ManagementAzureFirewallManagementSubnet/2659/26Required for forced tunneling 📄
Azure BastionAzureBastionSubnet/2659/26Name mandatory. Secure RDP/SSH access 📄
Azure Databrickspublic + private/26 × 259 × 2/26 × 2Two subnets required for VNet injection 📄
VPN GatewayGatewaySubnet/2727/27Name mandatory. No NSG. Shared with ExpressRoute GW 📄
ExpressRoute GatewayGatewaySubnet/2727/27Same subnet as VPN Gateway 📄
Azure Route ServerRouteServerSubnet/2727/27Name mandatory. BGP route exchange 📄
SQL Managed Instance/2727/26Delegation required. Dedicated subnet 📄
Azure Cache for Redis (Premium)/2727/272 IPs per shard + 1 LB 📄
API Management (VNet)/2727/27/29 possible for lightweight (stv2) 📄
Application Gateway/2811/27 or /26One AppGW per subnet. Plan for autoscaling 📄
Azure NetApp Files/2811/28Delegation required (Microsoft.NetApp/volumes) 📄
Azure Spring Apps/2811/26Two subnets: service runtime + apps 📄
Entra Domain Services/2811/28Managed AD in Azure 📄
Azure Dedicated HSM/2811/28Hardware Security Modules 📄
Private DNS Resolver (inbound)/2811/28Delegation required 📄
Private DNS Resolver (outbound)/2811/28Delegation required 📄
Azure Container Instances/293/27Delegation required for container groups 📄
NAT Gateway/293Attaches to an existing subnet, no dedicated subnet needed 📄
Private Endpoint/293/271 IP per Private Endpoint. Plan based on PE count 📄
📋

Subnet Delegation

Services that require a delegated subnet
⚠️
A delegated subnet is exclusive to its designated service — no other resources can be deployed in it.
List available delegations: az network vnet subnet list-available-delegations --location westeurope
📄 Docs: Subnet delegation overview
Service Delegation Name Shared Docs
App Service / Functions (VNet Integration)Microsoft.Web/serverFarmsNo 📄
App Service Environment v3Microsoft.Web/hostingEnvironmentsNo 📄
SQL Managed InstanceMicrosoft.Sql/managedInstancesNo 📄
Azure Container InstancesMicrosoft.ContainerInstance/containerGroupsNo 📄
Azure NetApp FilesMicrosoft.NetApp/volumesNo 📄
Azure DatabricksMicrosoft.Databricks/workspacesNo 📄
API ManagementMicrosoft.ApiManagement/serviceNo 📄
Azure Kubernetes ServiceMicrosoft.ContainerService/managedClustersNo 📄
Container Apps EnvironmentMicrosoft.App/environmentsNo 📄
Azure Cosmos DB (dedicated)Microsoft.AzureCosmosDB/clustersNo 📄
Azure BatchMicrosoft.Batch/batchAccountsNo 📄
Private DNS Resolver (inbound)Microsoft.Network/dnsResolversNo 📄
Private DNS Resolver (outbound)Microsoft.Network/dnsResolversNo 📄
Azure Machine LearningMicrosoft.MachineLearningServices/workspacesNo 📄
🛡️

NSG & UDR Compatibility by Service

Which services support NSGs and custom routes
Service / Subnet NSG UDR Notes Docs
GatewaySubnet✗ Forbidden⚠ LimitedNo NSG. UDR supported but 0.0.0.0/0 → NVA is not allowed 📄
AzureFirewallSubnet✗ ForbiddenUDR only for management (forced tunneling) 📄
AzureBastionSubnetNSG with specific rules required (see docs) 📄
RouteServerSubnet✗ Forbidden✗ ForbiddenNo customization allowed 📄
Application Gateway⚠ LimitedNSG: allow GatewayManager ports. No UDR to 0.0.0.0/0 📄
API ManagementNSG required with specific rules (ports 3443, etc.) 📄
AKS (Azure CNI)UDR to force egress traffic through a firewall 📄
SQL Managed InstanceNSG auto-managed by the service. Don't remove the rules 📄
Private EndpointsRequires network policies enabled on the subnet, otherwise NSG/UDR are bypassed 📄
App Service (VNet Integration)Outbound traffic from the app goes through the subnet 📄
Azure NetApp Files✗ Ignored✗ IgnoredNSG and UDR are applied but ignored by ANF 📄
🛣️

Routing in Hub & Spoke with NVA

UDR patterns, gateway route propagation, and exceptions

Standard Pattern — Force all traffic through the NVA

💡
In a hub-and-spoke with a centralized NVA (Azure Firewall or third-party), the goal is to ensure all Spoke traffic — both internet-bound and inter-Spoke — flows through the NVA for inspection and filtering.
📄 Docs: Hub-spoke routing · 📄 Docs: UDR overview
Route Table Applied to Routes GW Route Propagation Purpose
rt-spoke All Spoke subnets 0.0.0.0/0 → NVA private IP Disabled Forces all traffic (internet + private) through the NVA
rt-gateway GatewaySubnet (Hub) Spoke CIDRs → NVA private IP Enabled Return traffic from on-prem to Spokes goes through the NVA

🚫 Disable Gateway Route Propagation on Spokes

When a VPN/ExpressRoute gateway is in the Hub, it propagates BGP-learned on-premises routes to all peered VNets. If propagation is enabled on Spoke subnets, on-prem traffic bypasses the NVA because the BGP route is more specific than 0.0.0.0/0. Always set disable_bgp_route_propagation = true on Spoke route tables.

📄 Docs: BGP route propagation

🔥 NVA must have IP Forwarding enabled

The NVA's NIC(s) must have IP forwarding enabled in Azure (NIC setting) and in the OS (kernel). Without this, Azure drops packets not destined for the NVA's own IP. For Azure Firewall, this is handled automatically.

📄 Docs: IP forwarding

🔗 Peering: "Use Remote Gateway" on Spokes

On the Spoke-to-Hub peering, enable use_remote_gateways = true. On the Hub-to-Spoke peering, enable allow_gateway_transit = true. This lets Spokes use the Hub's VPN/ExpressRoute gateway without deploying their own.

📄 Docs: Gateway transit

Exception — Services requiring direct internet access

⚠️
Some Azure services need direct internet access for control-plane operations or public exposure (e.g. Application Gateway, API Management, AKS with public LB). Routing all their traffic through an NVA breaks health probes or management operations. For these subnets, use a split routing approach.
Route Table Applied to Routes GW Route Propagation Purpose
rt-spoke-internet Subnets needing direct internet (AppGW, APIM…) 0.0.0.0/0Internet
10.0.0.0/8 → NVA private IP
172.16.0.0/12 → NVA private IP
192.168.0.0/16 → NVA private IP
Disabled Internet traffic goes out directly; RFC1918 private traffic goes through the NVA for inspection

📋 Services that typically need this exception

Application Gateway — needs direct internet for health probes (GatewayManager) and public listeners
API Management — management plane requires internet access (port 3443)
AKS (public) — kube API server and image pulls from public registries
Azure Bastion — control plane needs internet for management
Any service with public IP exposure — inbound internet traffic cannot pass through the NVA

📄 Docs: AppGW supported UDRs · 📄 Docs: APIM force tunneling

🛣️ Why RFC1918 routes to NVA?

The 3 RFC1918 routes (10.0.0.0/8, 172.16.0.0/12, 192.168.0.0/16) cover all private address space — Azure VNets, on-premises networks, and other Spokes. This ensures that even without 0.0.0.0/0 pointing to the NVA, all east-west and hybrid traffic is still inspected. Only internet-bound traffic bypasses the NVA.

📄 Docs: Default routes
💡
Summary: Standard Spoke subnets get 0.0.0.0/0 → NVA + no BGP propagation. Subnets with services needing internet exposure get 0.0.0.0/0 → Internet + RFC1918 → NVA + no BGP propagation. The GatewaySubnet gets specific Spoke CIDRs → NVA with propagation enabled.
📄 Docs: Create a default route (Firewall tutorial)
🔗

VPN Gateway — SKU Comparison

Since Nov 2025, only AZ (zone-redundant) SKUs can be created
SKU Throughput S2S Tunnels P2S (IKEv2) BGP Zone-Redundant Use Case
VpnGw1AZ650 Mbps30250Small business, dev/test
VpnGw2AZ1.25 Gbps30500SMB, moderate workloads
VpnGw3AZ2.5 Gbps301,000Enterprise, multi-site
VpnGw4AZ5 Gbps1005,000Large scale, hybrid cloud
VpnGw5AZ10 Gbps10010,000Very large scale — otherwise use Virtual WAN
💡
Beyond 100 S2S tunnels, use Azure Virtual WAN instead. Throughput is aggregate across all connections — not guaranteed per tunnel.
📄 Docs: VPN Gateway SKUs · 📄 Docs: SKU consolidation (AZ migration)

ExpressRoute — Components & SKUs

Private connectivity from on-premises to Azure

The 3 Building Blocks

1️⃣ ExpressRoute Circuit

A logical connection between your on-premises network and Microsoft's edge, provisioned through a connectivity provider at a peering location. Defined by a bandwidth tier (50 Mbps to 100 Gbps with ExpressRoute Direct) and a SKU (Local, Standard, Premium).

Peering types:

  • Private Peering — access to Azure VNets (IaaS/PaaS via private IPs)
  • Microsoft Peering — access to Microsoft 365, Azure PaaS public endpoints
📄 Docs: Circuits and peering

2️⃣ ExpressRoute Gateway

A virtual network gateway deployed in the GatewaySubnet of your Hub VNet. It terminates the ExpressRoute connection on the Azure side. Can coexist with a VPN Gateway in the same GatewaySubnet for redundancy.

Gateway SKU determines throughput, number of circuits, and VM connections (see table below).

📄 Docs: ExpressRoute virtual network gateways

3️⃣ Connection

The link between the Gateway and the Circuit. A single circuit can be connected to gateways in multiple VNets (up to the SKU limit). A single gateway can connect to multiple circuits. Each connection represents one logical link.

In Terraform: azurerm_express_route_circuitazurerm_virtual_network_gateway_connectionazurerm_virtual_network_gateway

📄 Docs: Link a VNet to an ExpressRoute circuit

Circuit SKUs

Circuit SKU Region Scope Global Reach Data Plan Routes (Private Peering) VNet Links Use Case Docs
LocalSame metro onlyUnlimited (included)4,00010Single-region, data-heavy 📄
StandardSame geopolitical regionMetered or Unlimited4,00010Multi-region, same geography 📄
PremiumGlobal (all regions)Metered or Unlimited10,000100Global enterprise, cross-geo 📄

Gateway SKUs

Gateway SKU Max Throughput Max Circuits Max VMs FastPath Zone-Redundant Use Case Docs
ErGw1Az1 Gbps42,000Dev/test, small workloads 📄
ErGw2Az2 Gbps84,000Moderate workloads
ErGw3Az10 Gbps1610,000Production, enterprise
ErGwScale1–40 Gbps4–16Up to 50,000✓ (≥10 units)Large scale, auto-scaling
💡
FastPath bypasses the gateway for data-plane traffic, sending it directly to VMs for lower latency. Available on ErGw3Az and ErGwScale (≥10 scale units). ErGwScale supports auto-scaling from 1 to 40 Gbps in 1 Gbps increments — ideal for unpredictable or growing workloads.
📄 Docs: FastPath · 📄 Docs: Scalable Gateway
⚠️
Circuit bandwidth ≠ Gateway throughput. A 10 Gbps circuit connected through an ErGw1Az (1 Gbps) gateway will be bottlenecked at 1 Gbps. Always match your gateway SKU to your circuit bandwidth.
ExpressRoute circuits are billed independently from the gateway — you pay for both the circuit (provider + Microsoft port fee) and the gateway compute.
📄 Docs: Plan and manage ExpressRoute costs
🔥

Azure Firewall — SKU Comparison

Feature Basic Standard Premium
Throughput250 Mbps30 Gbps100 Gbps
Autoscaling
Threat IntelligenceAlertAlert/DenyAlert/Deny
FQDN Filtering (L7)
DNS Proxy
Web Categories
TLS/SSL Inspection
IDPS✓ (67k+ sigs)
URL Filtering (full path)
Availability Zones
Use CaseSMB, dev/testProduction, enterpriseCompliance (PCI, HIPAA)
⚠️
Enabling TLS Inspection + IDPS in "Deny" mode on Premium reduces effective throughput to ~10 Gbps per flow. The 100 Gbps figure is aggregate.
📄 Docs: Firewall performance · 📄 Docs: Choose the right SKU · 📄 Docs: Features by SKU
🔒

Private Endpoint vs Service Endpoint

When to use which
Criteria Service Endpoint Private Endpoint
IP TypePublic IP of the servicePrivate IP in your VNet
GranularitySubnet levelResource level (NIC)
IsolationPartial (need firewall rules too)Complete — no internet exposure
DNSPublic DNSPrivate DNS Zone required
On-Premises AccessNoYes (via VPN/ExpressRoute)
Cross-RegionNoYes
CostFree~$7.30/month + data
ComplexitySimpleMedium (DNS, NSG config)
RecommendationDev/Test, non-critical workloadsProduction, compliance, hybrid
📄 Private Endpoint overview · 📄 Service Endpoint overview

Per-Service Support

Azure Service Service Endpoint Private Endpoint Private DNS Zone Docs
Azure Storage (Blob/File/Queue/Table)privatelink.blob.core.windows.net 📄
Azure SQL Databaseprivatelink.database.windows.net 📄
Azure Cosmos DBprivatelink.documents.azure.com 📄
Azure Key Vaultprivatelink.vaultcore.azure.net 📄
Azure Container Registryprivatelink.azurecr.io 📄
Azure Event Hubsprivatelink.servicebus.windows.net 📄
Azure Service Busprivatelink.servicebus.windows.net 📄
Azure App Serviceprivatelink.azurewebsites.net 📄
Azure Database for PostgreSQLprivatelink.postgres.database.azure.com 📄
Azure Database for MySQLprivatelink.mysql.database.azure.com 📄
Azure Synapse Analyticsprivatelink.sql.azuresynapse.net 📄
Azure Monitor (Log Analytics)privatelink.monitor.azure.com 📄
Azure Machine Learningprivatelink.api.azureml.ms 📄
Azure Data Factoryprivatelink.datafactory.azure.net 📄
Azure OpenAI / Cognitive Servicesprivatelink.cognitiveservices.azure.com 📄
Azure Backupprivatelink.{region}.backup.windowsazure.com 📄
📄 Full list: Private Link availability by service
🌍

Outbound Internet — NAT Gateway & Options

How VMs and services reach the internet, and how to control it

Outbound Methods Comparison

Method Predictable IP Scale (SNAT ports) Cost Use Case
NAT Gateway up to 16 PIPs 64k per IP (up to 1M total) ~$32/month + data Recommended default for predictable, scalable egress
Azure Firewall (forced tunnel) Firewall PIP(s) ~2,496 per PIP Firewall cost (from ~$912/month) Centralized egress with L3-L7 filtering + FQDN rules
Load Balancer outbound rules LB frontend IPs Configurable per rule LB cost When LB is already deployed and simple egress is sufficient
Instance-level Public IP per VM 64k per VM PIP cost per VM Individual VMs needing a dedicated outbound identity
Default outbound access Random IP Limited Free Deprecation: March 31, 2026. Do not rely on it
📄 Docs: Default outbound access retirement · 📄 Docs: NAT Gateway overview

NAT Gateway — Key Facts

📐 Subnet-level association

NAT Gateway is assigned per subnet. All resources in that subnet use the NAT Gateway for outbound. It overrides LB outbound rules and default outbound access. However, instance-level public IPs take precedence over NAT Gateway — a VM with its own PIP will use that PIP for egress.

📄 Docs: NAT Gateway resource

🔢 Up to 16 Public IPs

Attach up to 16 public IPs or a public IP prefix for a maximum of ~1 million concurrent SNAT ports. Azure distributes flows across all IPs automatically.

📄 Docs: NAT Gateway scalability

⚡ No SNAT exhaustion

Unlike LB outbound rules, NAT Gateway dynamically allocates SNAT ports on demand (up to 64k per IP). Eliminates the classic SNAT port exhaustion problem that plagues Load Balancer-based egress.

📄 Docs: Troubleshoot SNAT exhaustion

🔒 Outbound-only

NAT Gateway provides outbound and return traffic only. It does not allow unsolicited inbound connections. For inbound, use Load Balancer, Application Gateway, or instance-level PIPs.

📄 Docs: NAT Gateway overview
💡
Recommended pattern in hub-and-spoke: In a forced-tunnel architecture (0.0.0.0/0 → NVA/Firewall), outbound internet goes through the Firewall which provides centralized filtering and logging. Use NAT Gateway in the Firewall subnet or attach PIPs to the Firewall itself for the actual egress IPs. For workloads with the internet exception pattern (0.0.0.0/0 → Internet), use NAT Gateway directly on the spoke subnet for predictable, scalable egress without going through the hub.
📄 Docs: NAT Gateway with Azure Firewall
⚠️
Default outbound access will be retired (March 31, 2026). VMs/VMSS created without an explicit outbound method have no internet access. Always deploy NAT Gateway, a Load Balancer with outbound rules, or instance-level PIPs explicitly.
📄 Docs: Default outbound access
⚖️

Application Gateway — Overview & SKUs

Layer 7 load balancer with optional WAF
⚠️
Application Gateway v1 SKUs retire April 2026. Only v2 SKUs (Standard_v2 and WAF_v2) should be used for new deployments.
📄 Docs: v1 retirement
Feature Standard_v2 WAF_v2
Layer 7 Load Balancing
URL/Path-based Routing
SSL/TLS Termination
Autoscaling (0–125 instances) (0–125 instances)
Zone Redundancy
Static VIP
Key Vault Integration
Header Rewrite
WebSocket / HTTP/2
Private-only (no public IP)
Web Application Firewall (OWASP CRS 3.x)
Bot Protection
Custom WAF Rules
Use CaseInternal apps, APIs, microservicesPublic-facing apps, compliance
📄 Docs: Application Gateway v2 overview · 📄 Docs: Features

Networking Requirements

Requirement Details Docs
Dedicated subnetOne Application Gateway per subnet. No other resources allowed. Min /28, recommended /27 or /26 for autoscaling 📄
NSGSupported but must allow GatewayManager service tag on ports 65200-65535 (v2) 📄
UDRDo not add a 0.0.0.0/0 route pointing to an NVA — it breaks health probes. Only specific destination routes allowed 📄
AutoscalingSet min instances ≥ 2 for production HA. Each instance ≈ 10 Capacity Units (2,500 persistent connections, ~2.2 Mbps) 📄
Private LinkSupported for private-only deployments (no public frontend IP required) 📄

Key Limits (v2 SKU)

Resource Limit Notes
Instances (autoscaling)125Min 0, max 125. Set min ≥ 2 for production HA
HTTP Listeners200100 active (routing traffic). WAF_v2: 40 active listeners
Routing Rules400Request routing rules per gateway
Backend Pools100Up to 1,200 backend targets per pool
Backend HTTP Settings100One per listener/rule combination
Frontend Ports100Per gateway
Frontend IP Configs41 public + 1 private (IPv4), 1 public + 1 private (IPv6)
SSL Certificates100One per HTTPS listener
Rewrite Rule Sets400Header and URL rewrite rule sets
URL Path Map rules100Path-based rules per URL map
Max request size (WAF)4 GBWith WAF_v2 and CRS 3.2 or DRS rule sets

Capacity per Instance (v2 SKU)

Metric Per Capacity Unit Per Instance (10 CU) Max (125 instances)
Persistent connections2,50025,000~3,125,000
Throughput2.22 Mbps~22 Mbps~2.75 Gbps
New connections/sec~500 (Std_v2) / ~100 (WAF_v2)~62,500 / ~12,500
📄 Docs: Application Gateway limits · 📄 Docs: High traffic support
💡
Application Gateway vs Azure Firewall: AppGW is a Layer 7 reverse proxy/load balancer (HTTP/HTTPS routing, WAF, SSL offload). Azure Firewall is a Layer 3-7 stateful firewall (egress filtering, DNAT, network rules). In a hub-spoke architecture, they are complementary: Firewall for egress control in the Hub, Application Gateway for ingress in each Spoke or in a shared DMZ Spoke.
📄 Docs: Firewall and Application Gateway for virtual networks
🛡️

Azure Front Door & DDoS Protection

Global edge services for performance and protection

Azure Front Door

Feature Standard Premium
Global HTTP/HTTPS Load Balancing
SSL Offload
Custom Domains
URL Redirect / Rewrite
Caching (CDN)
WAF (custom rules) (managed + custom + bot)
Private Link origins
Use CasePublic web apps, CDN, simple WAFEnterprise, Private Link backends, advanced WAF
💡
Front Door vs Application Gateway: Front Door operates at the global edge (anycast, multi-region routing, CDN). Application Gateway operates within a region (L7 LB, SSL, WAF for a single VNet). For global apps, use Front Door in front and Application Gateway (or backends) per region.
📄 Docs: Front Door overview · 📄 Docs: Global web app architecture

Azure DDoS Protection

Feature Basic (default) IP Protection Network Protection
Layer 3/4 protection (generic) (adaptive) (adaptive)
Adaptive tuning
Metrics & alerts
Mitigation flow logs
Attack analytics / reports
DDoS Rapid Response (DRR)
Cost protection (credit)
WAF discount
ScopeAll Azure public IPs (auto)Per public IPPer VNet (all IPs in the VNet)
CostFree~$199/IP/month~$2,944/month (100 IPs incl.)
Best forDev/test, default baselineFew public IPs (1–14)Enterprise, many IPs (15+)
💡
IP Protection vs Network Protection: IP Protection is billed per IP ($199/IP/month) — cost-effective for ≤14 IPs. Network Protection is billed flat ($2,944/month for up to 100 IPs, then $29.50/IP) — cost-effective at scale. Network Protection also adds DDoS Rapid Response (15-min SLA with Microsoft specialists), cost protection credits during attacks, and WAF discounts.
📄 Docs: Tier comparison · 📄 Docs: DDoS Protection overview · 📄 Docs: Pricing guide
🌐

DNS — Best Practices

🔗 Centralized Private DNS Zones

Create Private DNS Zones in the Hub/Connectivity subscription and link them to Spoke VNets. Never duplicate zones across subscriptions.

📄 Docs: Private Link and DNS integration at scale

🔄 Conditional Forwarders

Use Azure Private DNS Resolver to resolve Azure names from on-premises, and on-premises names from Azure. No more custom DNS VMs needed.

📄 Docs: Private DNS Resolver overview

🧩 DNS Private Resolver — Architecture

Deploy the Resolver in a dedicated Spoke VNet (or Shared Services Spoke). It requires two dedicated subnets: one for the inbound endpoint (on-prem → Azure resolution, min /28) and one for the outbound endpoint (Azure → on-prem forwarding, min /28). Link the Resolver's VNet to all Private DNS Zones so inbound queries can resolve Private Endpoint records.

📄 Docs: Private DNS Resolver overview

📨 Resolver — Forwarding Rulesets

Create DNS forwarding rulesets on the outbound endpoint to forward specific domains (e.g. corp.local) to on-premises DNS servers. Rulesets can be linked to multiple VNets — no need to configure DNS settings per VNet. Point Spoke VNets' DNS settings to the Resolver inbound endpoint IP.

📄 Docs: Endpoints and rulesets

🏷️ Naming Convention

Private DNS Zones for Private Endpoints follow the format privatelink.{service}.{domain}. Don't change the names — Azure expects them exactly.

📄 Docs: Private Endpoint DNS configuration

⚠️ Auto-registration

DNS auto-registration only works for VMs. A VNet can only have auto-registration enabled for one Private DNS Zone (but a zone supports up to 100 VNets with auto-registration). Use it in the Shared Services Spoke for shared VMs.

📄 Docs: Auto-registration feature

🌍 Split-Brain DNS

When you enable a Private Endpoint, public resolution still works for clients not connected to the VNet. The Private DNS Zone only overrides for clients within the linked VNet.

📄 Docs: DNS for on-premises workloads

📊 Key Zones to Know

privatelink.blob.core.windows.net
privatelink.database.windows.net
privatelink.vaultcore.azure.net
privatelink.azurewebsites.net
privatelink.azurecr.io

📄 Docs: Full DNS zone list
🛠️

Ops — Day-2 Network Operations

Monitoring, alerting, troubleshooting, and governance baseline

📡 Centralize diagnostics

Enable Diagnostic Settings on all critical network resources (Firewall, VPN/ER gateways, Application Gateway, Front Door, Bastion, DDoS) and send logs/metrics to Log Analytics.

📄 Docs: Diagnostic settings

🔍 Keep flow visibility

Use Virtual Network Flow Logs for traffic visibility and investigation. Build workbooks for top talkers, denied flows, and unexpected east-west traffic paths.

📄 Docs: Virtual Network Flow Logs

🚨 Build an alert baseline

Create alerts for tunnel down events, gateway connection failures, firewall health degradation, App Gateway unhealthy backends, and DDoS mitigation activation.

📄 Docs: Azure Monitor alerts

🧪 Use Network Watcher tools

Standardize troubleshooting with Effective Routes, Next Hop, IP Flow Verify, Connection Troubleshoot, and Packet Capture before escalating incidents.

📄 Docs: Network Watcher tools

🛡️ Govern with Azure Policy

Use policy to enforce baseline controls (for example: approved regions/SKUs, mandatory diagnostic settings, restricted public exposure). Track compliance drift continuously.

📄 Docs: Azure Policy overview

📘 Operate with runbooks

Maintain runbooks for recurring scenarios: route leaks/asymmetry, DNS resolution failures, Private Endpoint outages, VPN/ER failover, and emergency egress controls.

📄 Docs: Operational Excellence
💡
Minimum operating baseline: central logging, actionable alerts, monthly route/security review, and tested incident runbooks. Without these, even a good architecture becomes hard to operate at scale.
📄 Docs: Network Watcher monitoring overview · 📄 Docs: Observability recommendations
📊

Azure Network Limits & Quotas

The ceilings you need to know before hitting them in production
Resource Default Limit Max Limit Scope Docs
VNets per subscription1,0001,000Per region 📄
Subnets per VNet3,0003,000Per VNet 📄
Peerings per VNet5001,000 (with AVNM)Per VNet 📄
Private IPs per VNet65,53665,536Per VNet 📄
Public IPs (Standard) per sub1,000On requestPer region 📄
NSGs per subscription5,0005,000Per region 📄
Rules per NSG1,0001,000Inbound + outbound combined 📄
Routes per Route Table400400Per table 📄
Route Tables per subscription200200Per region 📄
BGP routes per gateway1,0001,000Per BGP peer 📄
Private Endpoints per subscription1,000On requestPer region 📄
Private DNS Zones per sub25,00025,000Per subscription 📄
VNet Links per Private DNS Zone1,0001,000Per zone 📄
DNS records per Private DNS Zone25,00025,000Per zone 📄
NICs per VMDepends on SKU8 (large VMs)Per VM 📄
NAT Gateway — concurrent flows50,00050,000Per public IP 📄
Load Balancer rules3001,000Per LB 📄
Application Security Groups3,0003,000Per subscription 📄
💡

Best Practices — Azure Network Architecture

🏗️ Hub-and-Spoke as Foundation

The Hub VNet should contain only networking infrastructure (Firewall, Gateway, Bastion). Shared services go in a dedicated Spoke. Consider one Spoke per service/usage to simplify filtering, NSG rules, and segmentation.

📄 Docs: Hub-spoke network topology

📐 Size Large from Day One

Use /21 for the Hub, /22 for Spokes. Subnets cannot be resized with resources deployed. Always plan 2x your initial need.

📄 Docs: Plan for IP addressing

🚫 No CIDR Overlap

Plan your address space before creating the first VNet. Consider on-premises and other clouds. Overlapping CIDRs block peering and routing.

📄 Docs: VNet FAQ (overlapping)

🔒 NSG on Every Subnet

Even with a firewall, apply NSGs to all subnets (except GatewaySubnet and FirewallSubnet). Defense in depth principle. Use Application Security Groups to simplify rules.

📄 Docs: NSG overview

📡 Accelerated Networking

Enable Accelerated Networking on all VMs that support it. It's free and reduces latency by 50%+. Nearly all SKUs with ≥ 2 vCPUs support it.

📄 Docs: Accelerated Networking

🔄 NAT Gateway for Egress

Prefer NAT Gateway over individual public IPs for outbound traffic. Provides a stable outbound IP, more SNAT ports, and avoids Load Balancer SNAT port exhaustion.

📄 Docs: NAT Gateway overview

📊 Enable Network Watcher

Enable Network Watcher in every used region. Configure VNet Flow Logs (successor to NSG Flow Logs) to a Storage Account + Log Analytics for auditing and troubleshooting.

📄 Docs: Network Watcher overview

🏷️ Naming Convention

Follow the CAF: vnet-{workload}-{region}-{env}, snet-{purpose}, nsg-{subnet}, rt-{subnet}. Consistent naming prevents production mistakes.

📄 Docs: Naming conventions

🔐 MTU & Fragmentation

Azure MTU is 1,500 bytes for inter-VNet/peering traffic. Don't rely on jumbo frames cross-VNet. Ensure firewalls don't block ICMP "Fragmentation Needed" messages.

📄 Docs: VM MTU configuration

🔁 Availability Zones for networking

Deploy zone-redundant resources wherever possible: VPN Gateway (AZ SKUs), Azure Firewall, Application Gateway, Load Balancer. Zone-redundant deployment survives a full AZ outage with no downtime.

📄 Docs: Availability Zones overview

🔍 Use Azure Firewall Manager

For multi-hub or multi-region deployments, centralize firewall policy management with Azure Firewall Manager. One policy, multiple firewalls. Works with both custom hubs and Virtual WAN secured hubs.

📄 Docs: Firewall Manager overview

📋 Document your IP plan

Maintain a living IP address plan that covers all VNets, subnets, on-premises ranges, and reserved ranges. Review it before every new VNet or peering. Use a spreadsheet, IPAM tool, or Azure IPAM.

📄 Docs: Plan for IP addressing