Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
- Latest
- 2025-01-01
- 2024-10-01
- 2024-07-01
- 2024-05-01
- 2024-03-01
- 2024-01-01
- 2023-11-01
- 2023-09-01
- 2023-06-01
- 2023-05-01
- 2023-04-01
- 2023-02-01
- 2022-11-01
- 2022-09-01
- 2022-07-01
- 2022-05-01
- 2022-01-01
- 2021-08-01
- 2021-05-01
- 2021-03-01
- 2021-02-01
- 2020-11-01
- 2020-08-01
- 2020-07-01
- 2020-06-01
- 2020-05-01
- 2020-04-01
- 2020-03-01
- 2019-12-01
- 2019-11-01
- 2019-09-01
- 2019-08-01
- 2019-07-01
- 2019-06-01
- 2019-04-01
- 2019-02-01
Bicep resource definition
The natGateways resource type can be deployed with operations that target:
For a list of changed properties in each API version, see change log.
Resource format
To create a Microsoft.Network/natGateways resource, add the following Bicep to your template.
resource symbolicname 'Microsoft.Network/natGateways@2025-01-01' = {
scope: resourceSymbolicName or scope
location: 'string'
name: 'string'
properties: {
idleTimeoutInMinutes: int
publicIpAddresses: [
{
id: 'string'
}
]
publicIpAddressesV6: [
{
id: 'string'
}
]
publicIpPrefixes: [
{
id: 'string'
}
]
publicIpPrefixesV6: [
{
id: 'string'
}
]
sourceVirtualNetwork: {
id: 'string'
}
}
sku: {
name: 'string'
}
tags: {
{customized property}: 'string'
}
zones: [
'string'
]
}
Property Values
Microsoft.Network/natGateways
| Name | Description | Value |
|---|---|---|
| location | Resource location. | string |
| name | The resource name | string (required) |
| properties | Nat Gateway properties. | NatGatewayPropertiesFormat |
| scope | Use when creating a resource at a scope that is different than the deployment scope. | Set this property to the symbolic name of a resource to apply the extension resource. |
| sku | The nat gateway SKU. | NatGatewaySku |
| tags | Resource tags | Dictionary of tag names and values. See Tags in templates |
| zones | A list of availability zones denoting the zone in which Nat Gateway should be deployed. | string[] |
NatGatewayPropertiesFormat
| Name | Description | Value |
|---|---|---|
| idleTimeoutInMinutes | The idle timeout of the nat gateway. | int |
| publicIpAddresses | An array of public ip addresses V4 associated with the nat gateway resource. | SubResource[] |
| publicIpAddressesV6 | An array of public ip addresses V6 associated with the nat gateway resource. | SubResource[] |
| publicIpPrefixes | An array of public ip prefixes V4 associated with the nat gateway resource. | SubResource[] |
| publicIpPrefixesV6 | An array of public ip prefixes V6 associated with the nat gateway resource. | SubResource[] |
| sourceVirtualNetwork | A reference to the source virtual network using this nat gateway resource. | SubResource |
NatGatewaySku
| Name | Description | Value |
|---|---|---|
| name | Name of Nat Gateway SKU. | 'Standard' 'StandardV2' |
ResourceTags
| Name | Description | Value |
|---|
SubResource
| Name | Description | Value |
|---|---|---|
| id | Resource ID. | string |
Usage Examples
Azure Verified Modules
The following Azure Verified Modules can be used to deploy this resource type.
| Module | Description |
|---|---|
| NAT Gateway | AVM Resource Module for NAT Gateway |
Azure Quickstart Samples
The following Azure Quickstart templates contain Bicep samples for deploying this resource type.
| Bicep File | Description |
|---|---|
| AKS Cluster with a NAT Gateway and an Application Gateway | This sample shows how to a deploy an AKS cluster with NAT Gateway for outbound connections and an Application Gateway for inbound connections. |
| Azure Databricks All-in-one Templat VNetInjection-Pvtendpt | This template allows you to create a network security group, a virtual network and an Azure Databricks workspace with the virtual network, and Private Endpoint. |
| AzureDatabricks Template for Default Storage Firewall | This template allows you to create a network security group, a virtual network, private endpoint, and a default storage firewall enabled Azure Databricks workspace with the virtual network and the system-assigned access connector. |
| AzureDatabricks Template for VNet Injection with NAT Gateway | This template allows you to create a NAT gateway, network security group, a virtual network and an Azure Databricks workspace with the virtual network. |
| AzureDatabricks Virtual Network - VNet Injection NAT Gateway | This template allows you to create a Virtual Network for Azure Databricks VNet injection with natgateway. |
| Create a cross-region load balancer | This template creates a cross-region load balancer with a backend pool containing two regional load balancers. Cross-region load balancer is currently available in limited regions. The regional load balancers behind the cross-region load balancer can be in any region. |
| Create a standard internal load balancer | This template creates a standard internal Azure Load Balancer with a rule load-balancing port 80 |
| Create a standard load-balancer | This template creates an Internet-facing load-balancer, load balancing rules, and three VMs for the backend pool with each VM in a redundant zone. |
| Deploy Secure AI Foundry with a managed virtual network | This template creates a secure Azure AI Foundry environment with robust network and identity security restrictions. |
| Virtual Network NAT | Deploy a NAT gateway and virtual network |
| Virtual Network NAT with VM | Deploy a NAT gateway and virtual machine |
ARM template resource definition
The natGateways resource type can be deployed with operations that target:
For a list of changed properties in each API version, see change log.
Resource format
To create a Microsoft.Network/natGateways resource, add the following JSON to your template.
{
"type": "Microsoft.Network/natGateways",
"apiVersion": "2025-01-01",
"name": "string",
"location": "string",
"properties": {
"idleTimeoutInMinutes": "int",
"publicIpAddresses": [
{
"id": "string"
}
],
"publicIpAddressesV6": [
{
"id": "string"
}
],
"publicIpPrefixes": [
{
"id": "string"
}
],
"publicIpPrefixesV6": [
{
"id": "string"
}
],
"sourceVirtualNetwork": {
"id": "string"
}
},
"sku": {
"name": "string"
},
"tags": {
"{customized property}": "string"
},
"zones": [ "string" ]
}
Property Values
Microsoft.Network/natGateways
| Name | Description | Value |
|---|---|---|
| apiVersion | The api version | '2025-01-01' |
| location | Resource location. | string |
| name | The resource name | string (required) |
| properties | Nat Gateway properties. | NatGatewayPropertiesFormat |
| sku | The nat gateway SKU. | NatGatewaySku |
| tags | Resource tags | Dictionary of tag names and values. See Tags in templates |
| type | The resource type | 'Microsoft.Network/natGateways' |
| zones | A list of availability zones denoting the zone in which Nat Gateway should be deployed. | string[] |
NatGatewayPropertiesFormat
| Name | Description | Value |
|---|---|---|
| idleTimeoutInMinutes | The idle timeout of the nat gateway. | int |
| publicIpAddresses | An array of public ip addresses V4 associated with the nat gateway resource. | SubResource[] |
| publicIpAddressesV6 | An array of public ip addresses V6 associated with the nat gateway resource. | SubResource[] |
| publicIpPrefixes | An array of public ip prefixes V4 associated with the nat gateway resource. | SubResource[] |
| publicIpPrefixesV6 | An array of public ip prefixes V6 associated with the nat gateway resource. | SubResource[] |
| sourceVirtualNetwork | A reference to the source virtual network using this nat gateway resource. | SubResource |
NatGatewaySku
| Name | Description | Value |
|---|---|---|
| name | Name of Nat Gateway SKU. | 'Standard' 'StandardV2' |
ResourceTags
| Name | Description | Value |
|---|
SubResource
| Name | Description | Value |
|---|---|---|
| id | Resource ID. | string |
Usage Examples
Azure Quickstart Templates
The following Azure Quickstart templates deploy this resource type.
| Template | Description |
|---|---|
| AKS Cluster with a NAT Gateway and an Application Gateway |
This sample shows how to a deploy an AKS cluster with NAT Gateway for outbound connections and an Application Gateway for inbound connections. |
| Azure Databricks All-in-one Templat VNetInjection-Pvtendpt |
This template allows you to create a network security group, a virtual network and an Azure Databricks workspace with the virtual network, and Private Endpoint. |
| AzureDatabricks Template for Default Storage Firewall |
This template allows you to create a network security group, a virtual network, private endpoint, and a default storage firewall enabled Azure Databricks workspace with the virtual network and the system-assigned access connector. |
| AzureDatabricks Template for VNet Injection with NAT Gateway |
This template allows you to create a NAT gateway, network security group, a virtual network and an Azure Databricks workspace with the virtual network. |
| AzureDatabricks Template with Default Storage Firewall |
This template allows you to create an Default Storage Firewall enabled Azure Databricks workspace with Privateendpoint, all three forms of CMK, and User-Assigned Access Connector. |
| AzureDatabricks Virtual Network - VNet Injection NAT Gateway |
This template allows you to create a Virtual Network for Azure Databricks VNet injection with natgateway. |
| Create a cross-region load balancer |
This template creates a cross-region load balancer with a backend pool containing two regional load balancers. Cross-region load balancer is currently available in limited regions. The regional load balancers behind the cross-region load balancer can be in any region. |
| Create a standard internal load balancer |
This template creates a standard internal Azure Load Balancer with a rule load-balancing port 80 |
| Create a standard load-balancer |
This template creates an Internet-facing load-balancer, load balancing rules, and three VMs for the backend pool with each VM in a redundant zone. |
| Deploy an Azure Databricks Workspace with PE,CMK all forms |
This template allows you to create an Azure Databricks workspace with PrivateEndpoint and managed services and CMK with DBFS encryption. |
| Deploy Darktrace Autoscaling vSensors |
This template allows you to deploy an automatically autoscaling deployment of Darktrace vSensors |
| Deploy Secure AI Foundry with a managed virtual network |
This template creates a secure Azure AI Foundry environment with robust network and identity security restrictions. |
| Virtual Network NAT |
Deploy a NAT gateway and virtual network |
| Virtual Network NAT with VM |
Deploy a NAT gateway and virtual machine |
Terraform (AzAPI provider) resource definition
The natGateways resource type can be deployed with operations that target:
For a list of changed properties in each API version, see change log.
Resource format
To create a Microsoft.Network/natGateways resource, add the following Terraform to your template.
resource "azapi_resource" "symbolicname" {
type = "Microsoft.Network/natGateways@2025-01-01"
name = "string"
parent_id = "string"
location = "string"
tags = {
{customized property} = "string"
}
body = {
properties = {
idleTimeoutInMinutes = int
publicIpAddresses = [
{
id = "string"
}
]
publicIpAddressesV6 = [
{
id = "string"
}
]
publicIpPrefixes = [
{
id = "string"
}
]
publicIpPrefixesV6 = [
{
id = "string"
}
]
sourceVirtualNetwork = {
id = "string"
}
}
sku = {
name = "string"
}
zones = [
"string"
]
}
}
Property Values
Microsoft.Network/natGateways
| Name | Description | Value |
|---|---|---|
| location | Resource location. | string |
| name | The resource name | string (required) |
| parent_id | The ID of the resource to apply this extension resource to. | string (required) |
| properties | Nat Gateway properties. | NatGatewayPropertiesFormat |
| sku | The nat gateway SKU. | NatGatewaySku |
| tags | Resource tags | Dictionary of tag names and values. |
| type | The resource type | "Microsoft.Network/natGateways@2025-01-01" |
| zones | A list of availability zones denoting the zone in which Nat Gateway should be deployed. | string[] |
NatGatewayPropertiesFormat
| Name | Description | Value |
|---|---|---|
| idleTimeoutInMinutes | The idle timeout of the nat gateway. | int |
| publicIpAddresses | An array of public ip addresses V4 associated with the nat gateway resource. | SubResource[] |
| publicIpAddressesV6 | An array of public ip addresses V6 associated with the nat gateway resource. | SubResource[] |
| publicIpPrefixes | An array of public ip prefixes V4 associated with the nat gateway resource. | SubResource[] |
| publicIpPrefixesV6 | An array of public ip prefixes V6 associated with the nat gateway resource. | SubResource[] |
| sourceVirtualNetwork | A reference to the source virtual network using this nat gateway resource. | SubResource |
NatGatewaySku
| Name | Description | Value |
|---|---|---|
| name | Name of Nat Gateway SKU. | 'Standard' 'StandardV2' |
ResourceTags
| Name | Description | Value |
|---|
SubResource
| Name | Description | Value |
|---|---|---|
| id | Resource ID. | string |
Usage Examples
Terraform Samples
A basic example of deploying Azure NAT Gateway.
terraform {
required_providers {
azapi = {
source = "Azure/azapi"
}
}
}
provider "azapi" {
skip_provider_registration = false
}
variable "resource_name" {
type = string
default = "acctest0001"
}
variable "location" {
type = string
default = "westeurope"
}
resource "azapi_resource" "resourceGroup" {
type = "Microsoft.Resources/resourceGroups@2020-06-01"
name = var.resource_name
location = var.location
}
resource "azapi_resource" "natGateway" {
type = "Microsoft.Network/natGateways@2022-07-01"
parent_id = azapi_resource.resourceGroup.id
name = var.resource_name
location = var.location
body = {
properties = {
idleTimeoutInMinutes = 10
}
sku = {
name = "Standard"
}
}
schema_validation_enabled = false
response_export_values = ["*"]
}
Azure Verified Modules
The following Azure Verified Modules can be used to deploy this resource type.
| Module | Description |
|---|---|
| NAT Gateway | AVM Resource Module for NAT Gateway |