
You can delegate subnets in Azure to other users or groups, giving them the ability to manage and configure the subnet, but not the ability to delete it. This is a key feature of Azure subnet delegation.
Delegating a subnet allows you to grant permissions to other users or groups without having to give them access to the entire virtual network. This can be especially useful when working with large teams or when you need to give someone temporary access to a subnet.
Azure Subnet Delegation is a feature that allows you to delegate subnets to other users or groups, but it's not the same as granting them access to the entire virtual network. This is a deliberate design choice to provide more granular control over access and permissions.
Curious to learn more? Check out: How to Change Virtual Network/subnet in Azure Vm
What Is Azure Subnet Delegation?
Azure Subnet Delegation allows you to delegate the management of a subnet to a virtual network (VNet) service endpoint.
By delegating a subnet, you can grant access to a service to manage the subnet's network security groups (NSGs) and route tables.
This delegation is useful for scenarios where a service needs to manage the subnet's network configuration.
Subnet delegation is a feature that's been available in Azure since 2019.
It's a powerful tool that can simplify network management and reduce the complexity of managing multiple subnets.
Recommended read: Azure Kubernetes Service vs Azure Container Apps
Advantages and Benefits
Delegating a subnet to specific services provides several advantages. It helps to designate a subnet for one or more Azure services and manage the instances in the subnet as per requirements.
The virtual network owner can define policies and options for a delegated subnet to better manage resources. For example, they can define policies to block any actions that can affect the functioning of the injected service at the PUT stage.
Delegating a subnet to specific services also helps injected services to better integrate with the virtual network. This is achieved by defining the preconditions of deployments in the form of Network Intent Policies.
Take a look at this: Azure Cloud Offerings
These policies ensure that any actions that can affect the functioning of the injected service can be blocked at PUT. This provides an added layer of security and control over the virtual network.
Here are the advantages of subnet delegation:
- Designate a subnet for one or more Azure services
- Manage instances in the subnet as per requirements
- Define policies to block actions that can affect the functioning of the injected service
- Ensure better integration of injected services with the virtual network
Effect on Your Network
Azure subnet delegation can have a significant impact on your network. It's essential to understand the effects of delegation on your subnet.
A delegated subnet can be shared with other Azure services or VMs in the same subnet, or it can be dedicated to only instances of the injected service.
You can associate a network security group (NSG) with a delegated subnet, and this NSG can also be associated with any other subnet. This flexibility can help you manage your network security more efficiently.
Route table association is also supported with a delegated subnet, and the route table associated with the delegated subnet can be associated with any other subnet as well.
Delegated subnets have strict IP address space requirements, with a minimum number of IP addresses and a private IP address space (10.0.0.0/8, 192.168.0.0/16, 172.16.0.0/12) being dictated by the injected service.
Custom DNS configuration is also affected, requiring an Azure DNS entry.
It's worth noting that delegation must be removed before you can delete a subnet or virtual network.
Here are the key effects of subnet delegation on your network:
- Shared or dedicated subnet with injected service
- NSG association with delegated subnet
- NSG association with other subnets
- Route table association with delegated subnet
- Route table association with other subnets
- Minimum IP address requirements
- Private IP address space requirements
- Azure DNS entry required for custom DNS configuration
- Delegation must be removed before subnet or virtual network deletion
- No private endpoint support if subnet is delegated
Who Can Delegate Subnets
Virtual network owners are responsible for delegating subnets to Azure Services.
They need to designate one of the subnets for a specific Azure Service to deploy instances into this subnet for customer workloads.
Only the virtual network owners have the authority to perform subnet delegation.
This exercise is essential for Azure Service to deploy instances into the designated subnet for consumption by customer workloads.
The subnet delegation process is a critical step in setting up Azure Services for customer workloads.
Planning and Configuration
Planning and configuration are crucial steps in Azure subnet delegation. You can configure subnet delegation during the creation of the subnet or after it has been created.
The Network Contributor role is the lowest-level role that has the necessary permissions to delegate the subnet to a service. This role allows administrators to make changes to the subnet configuration.
To delegate a subnet, you must assign a role to the user or group, or delegate permissions to the resource to another Azure service. This enables the integration of Azure services with a subnet.
Plan and Configure
To plan and configure your Azure resources, you need to consider role-based access control (RBAC). This is a crucial step in managing your virtual networks and other resources.
Azure resources are managed by using RBAC, which means you need to assign roles to users or groups to allow them to perform management actions on resources. As a resource owner, you must assign a role to the user or group if you need to allow them to perform management actions on the resource.
You can delegate subnet management to another Azure service, which allows the service to modify the subnet configuration to provide a managed and recommended configuration. Delegating a subnet is similar to assigning a user a role that has permissions to change the resource.
The Network Contributor role is the lowest-level role that has appropriate permissions to delegate the subnet to a service. This role is essential for configuring subnet delegation during the creation of the subnet or after it has been created.
Add Existing Bicep

Adding delegation to an existing subnet in Azure Bicep can be tricky.
You can't add delegation to a subnet that is already delegated, so you need to try a different approach.
Try adding delegation to an AKS network or Azure App Gateway network to create a private endpoint.
The Azure Bicep code will look something like this, but be aware of potential errors.
The error message might look something like this, with a "NotFound" code and a message about a missing HTTP resource.
Frequently Asked Questions
Can Azure subnets communicate with each other?
Yes, Azure subnets within the same virtual network can communicate with each other by default. This includes traffic between subnets, which is allowed without additional configuration.
Featured Images: pexels.com


