1. Packages
  2. Packages
  3. Azure Classic
  4. API Docs
  5. network
  6. NatGateway

We recommend using Azure Native.

Viewing docs for Azure v4.42.0 (Older version)
published on Monday, Mar 9, 2026 by Pulumi
azure logo

We recommend using Azure Native.

Viewing docs for Azure v4.42.0 (Older version)
published on Monday, Mar 9, 2026 by Pulumi

    Manages a Azure NAT Gateway.

    Example Usage

    using Pulumi;
    using Azure = Pulumi.Azure;
    
    class MyStack : Stack
    {
        public MyStack()
        {
            var exampleResourceGroup = new Azure.Core.ResourceGroup("exampleResourceGroup", new Azure.Core.ResourceGroupArgs
            {
                Location = "West Europe",
            });
            var examplePublicIp = new Azure.Network.PublicIp("examplePublicIp", new Azure.Network.PublicIpArgs
            {
                Location = exampleResourceGroup.Location,
                ResourceGroupName = exampleResourceGroup.Name,
                AllocationMethod = "Static",
                Sku = "Standard",
                Zones = 
                {
                    "1",
                },
            });
            var examplePublicIpPrefix = new Azure.Network.PublicIpPrefix("examplePublicIpPrefix", new Azure.Network.PublicIpPrefixArgs
            {
                Location = exampleResourceGroup.Location,
                ResourceGroupName = exampleResourceGroup.Name,
                PrefixLength = 30,
                Zones = 
                {
                    "1",
                },
            });
            var exampleNatGateway = new Azure.Network.NatGateway("exampleNatGateway", new Azure.Network.NatGatewayArgs
            {
                Location = exampleResourceGroup.Location,
                ResourceGroupName = exampleResourceGroup.Name,
                PublicIpAddressIds = 
                {
                    examplePublicIp.Id,
                },
                PublicIpPrefixIds = 
                {
                    examplePublicIpPrefix.Id,
                },
                SkuName = "Standard",
                IdleTimeoutInMinutes = 10,
                Zones = 
                {
                    "1",
                },
            });
        }
    
    }
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-azure/sdk/v4/go/azure/core"
    	"github.com/pulumi/pulumi-azure/sdk/v4/go/azure/network"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		exampleResourceGroup, err := core.NewResourceGroup(ctx, "exampleResourceGroup", &core.ResourceGroupArgs{
    			Location: pulumi.String("West Europe"),
    		})
    		if err != nil {
    			return err
    		}
    		examplePublicIp, err := network.NewPublicIp(ctx, "examplePublicIp", &network.PublicIpArgs{
    			Location:          exampleResourceGroup.Location,
    			ResourceGroupName: exampleResourceGroup.Name,
    			AllocationMethod:  pulumi.String("Static"),
    			Sku:               pulumi.String("Standard"),
    			Zones: pulumi.String{
    				"1",
    			},
    		})
    		if err != nil {
    			return err
    		}
    		examplePublicIpPrefix, err := network.NewPublicIpPrefix(ctx, "examplePublicIpPrefix", &network.PublicIpPrefixArgs{
    			Location:          exampleResourceGroup.Location,
    			ResourceGroupName: exampleResourceGroup.Name,
    			PrefixLength:      pulumi.Int(30),
    			Zones: pulumi.String{
    				"1",
    			},
    		})
    		if err != nil {
    			return err
    		}
    		_, err = network.NewNatGateway(ctx, "exampleNatGateway", &network.NatGatewayArgs{
    			Location:          exampleResourceGroup.Location,
    			ResourceGroupName: exampleResourceGroup.Name,
    			PublicIpAddressIds: pulumi.StringArray{
    				examplePublicIp.ID(),
    			},
    			PublicIpPrefixIds: pulumi.StringArray{
    				examplePublicIpPrefix.ID(),
    			},
    			SkuName:              pulumi.String("Standard"),
    			IdleTimeoutInMinutes: pulumi.Int(10),
    			Zones: pulumi.StringArray{
    				pulumi.String("1"),
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    

    Example coming soon!

    import * as pulumi from "@pulumi/pulumi";
    import * as azure from "@pulumi/azure";
    
    const exampleResourceGroup = new azure.core.ResourceGroup("exampleResourceGroup", {location: "West Europe"});
    const examplePublicIp = new azure.network.PublicIp("examplePublicIp", {
        location: exampleResourceGroup.location,
        resourceGroupName: exampleResourceGroup.name,
        allocationMethod: "Static",
        sku: "Standard",
        zones: ["1"],
    });
    const examplePublicIpPrefix = new azure.network.PublicIpPrefix("examplePublicIpPrefix", {
        location: exampleResourceGroup.location,
        resourceGroupName: exampleResourceGroup.name,
        prefixLength: 30,
        zones: ["1"],
    });
    const exampleNatGateway = new azure.network.NatGateway("exampleNatGateway", {
        location: exampleResourceGroup.location,
        resourceGroupName: exampleResourceGroup.name,
        publicIpAddressIds: [examplePublicIp.id],
        publicIpPrefixIds: [examplePublicIpPrefix.id],
        skuName: "Standard",
        idleTimeoutInMinutes: 10,
        zones: ["1"],
    });
    
    import pulumi
    import pulumi_azure as azure
    
    example_resource_group = azure.core.ResourceGroup("exampleResourceGroup", location="West Europe")
    example_public_ip = azure.network.PublicIp("examplePublicIp",
        location=example_resource_group.location,
        resource_group_name=example_resource_group.name,
        allocation_method="Static",
        sku="Standard",
        zones=["1"])
    example_public_ip_prefix = azure.network.PublicIpPrefix("examplePublicIpPrefix",
        location=example_resource_group.location,
        resource_group_name=example_resource_group.name,
        prefix_length=30,
        zones=["1"])
    example_nat_gateway = azure.network.NatGateway("exampleNatGateway",
        location=example_resource_group.location,
        resource_group_name=example_resource_group.name,
        public_ip_address_ids=[example_public_ip.id],
        public_ip_prefix_ids=[example_public_ip_prefix.id],
        sku_name="Standard",
        idle_timeout_in_minutes=10,
        zones=["1"])
    

    Example coming soon!

    Create NatGateway Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new NatGateway(name: string, args: NatGatewayArgs, opts?: CustomResourceOptions);
    @overload
    def NatGateway(resource_name: str,
                   args: NatGatewayArgs,
                   opts: Optional[ResourceOptions] = None)
    
    @overload
    def NatGateway(resource_name: str,
                   opts: Optional[ResourceOptions] = None,
                   resource_group_name: Optional[str] = None,
                   idle_timeout_in_minutes: Optional[int] = None,
                   location: Optional[str] = None,
                   name: Optional[str] = None,
                   public_ip_address_ids: Optional[Sequence[str]] = None,
                   public_ip_prefix_ids: Optional[Sequence[str]] = None,
                   sku_name: Optional[str] = None,
                   tags: Optional[Mapping[str, str]] = None,
                   zones: Optional[Sequence[str]] = None)
    func NewNatGateway(ctx *Context, name string, args NatGatewayArgs, opts ...ResourceOption) (*NatGateway, error)
    public NatGateway(string name, NatGatewayArgs args, CustomResourceOptions? opts = null)
    public NatGateway(String name, NatGatewayArgs args)
    public NatGateway(String name, NatGatewayArgs args, CustomResourceOptions options)
    
    type: azure:network:NatGateway
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args NatGatewayArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args NatGatewayArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args NatGatewayArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args NatGatewayArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args NatGatewayArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var natGatewayResource = new Azure.Network.NatGateway("natGatewayResource", new()
    {
        ResourceGroupName = "string",
        IdleTimeoutInMinutes = 0,
        Location = "string",
        Name = "string",
        SkuName = "string",
        Tags = 
        {
            { "string", "string" },
        },
        Zones = new[]
        {
            "string",
        },
    });
    
    example, err := network.NewNatGateway(ctx, "natGatewayResource", &network.NatGatewayArgs{
    	ResourceGroupName:    pulumi.String("string"),
    	IdleTimeoutInMinutes: pulumi.Int(0),
    	Location:             pulumi.String("string"),
    	Name:                 pulumi.String("string"),
    	SkuName:              pulumi.String("string"),
    	Tags: pulumi.StringMap{
    		"string": pulumi.String("string"),
    	},
    	Zones: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    })
    
    var natGatewayResource = new NatGateway("natGatewayResource", NatGatewayArgs.builder()
        .resourceGroupName("string")
        .idleTimeoutInMinutes(0)
        .location("string")
        .name("string")
        .skuName("string")
        .tags(Map.of("string", "string"))
        .zones("string")
        .build());
    
    nat_gateway_resource = azure.network.NatGateway("natGatewayResource",
        resource_group_name="string",
        idle_timeout_in_minutes=0,
        location="string",
        name="string",
        sku_name="string",
        tags={
            "string": "string",
        },
        zones=["string"])
    
    const natGatewayResource = new azure.network.NatGateway("natGatewayResource", {
        resourceGroupName: "string",
        idleTimeoutInMinutes: 0,
        location: "string",
        name: "string",
        skuName: "string",
        tags: {
            string: "string",
        },
        zones: ["string"],
    });
    
    type: azure:network:NatGateway
    properties:
        idleTimeoutInMinutes: 0
        location: string
        name: string
        resourceGroupName: string
        skuName: string
        tags:
            string: string
        zones:
            - string
    

    NatGateway Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

    The NatGateway resource accepts the following input properties:

    ResourceGroupName string
    Specifies the name of the Resource Group in which the NAT Gateway should exist. Changing this forces a new resource to be created.
    IdleTimeoutInMinutes int
    The idle timeout which should be used in minutes. Defaults to 4.
    Location string
    Specifies the supported Azure location where the NAT Gateway should exist. Changing this forces a new resource to be created.
    Name string
    Specifies the name of the NAT Gateway. Changing this forces a new resource to be created.
    PublicIpAddressIds List<string>
    A list of Public IP Address ID's which should be associated with the NAT Gateway resource.

    Deprecated: Inline Public IP Address ID Associations have been deprecated in favour of the azurerm_nat_gateway_public_ip_association resource. This field will be removed in the next major version of the Azure Provider.

    PublicIpPrefixIds List<string>
    / Deprecated in favour of azure.network.NatGatewayPublicIpPrefixAssociation) A list of Public IP Prefix ID's which should be associated with the NAT Gateway resource.

    Deprecated: Inline Public IP Prefix ID Associations have been deprecated in favour of the azurerm_nat_gateway_public_ip_prefix_association resource. This field will be removed in the next major version of the Azure Provider.

    SkuName string
    The SKU which should be used. At this time the only supported value is Standard. Defaults to Standard.
    Tags Dictionary<string, string>
    A mapping of tags to assign to the resource. Changing this forces a new resource to be created.
    Zones List<string>
    A list of availability zones where the NAT Gateway should be provisioned. Changing this forces a new resource to be created.
    ResourceGroupName string
    Specifies the name of the Resource Group in which the NAT Gateway should exist. Changing this forces a new resource to be created.
    IdleTimeoutInMinutes int
    The idle timeout which should be used in minutes. Defaults to 4.
    Location string
    Specifies the supported Azure location where the NAT Gateway should exist. Changing this forces a new resource to be created.
    Name string
    Specifies the name of the NAT Gateway. Changing this forces a new resource to be created.
    PublicIpAddressIds []string
    A list of Public IP Address ID's which should be associated with the NAT Gateway resource.

    Deprecated: Inline Public IP Address ID Associations have been deprecated in favour of the azurerm_nat_gateway_public_ip_association resource. This field will be removed in the next major version of the Azure Provider.

    PublicIpPrefixIds []string
    / Deprecated in favour of azure.network.NatGatewayPublicIpPrefixAssociation) A list of Public IP Prefix ID's which should be associated with the NAT Gateway resource.

    Deprecated: Inline Public IP Prefix ID Associations have been deprecated in favour of the azurerm_nat_gateway_public_ip_prefix_association resource. This field will be removed in the next major version of the Azure Provider.

    SkuName string
    The SKU which should be used. At this time the only supported value is Standard. Defaults to Standard.
    Tags map[string]string
    A mapping of tags to assign to the resource. Changing this forces a new resource to be created.
    Zones []string
    A list of availability zones where the NAT Gateway should be provisioned. Changing this forces a new resource to be created.
    resourceGroupName String
    Specifies the name of the Resource Group in which the NAT Gateway should exist. Changing this forces a new resource to be created.
    idleTimeoutInMinutes Integer
    The idle timeout which should be used in minutes. Defaults to 4.
    location String
    Specifies the supported Azure location where the NAT Gateway should exist. Changing this forces a new resource to be created.
    name String
    Specifies the name of the NAT Gateway. Changing this forces a new resource to be created.
    publicIpAddressIds List<String>
    A list of Public IP Address ID's which should be associated with the NAT Gateway resource.

    Deprecated: Inline Public IP Address ID Associations have been deprecated in favour of the azurerm_nat_gateway_public_ip_association resource. This field will be removed in the next major version of the Azure Provider.

    publicIpPrefixIds List<String>
    / Deprecated in favour of azure.network.NatGatewayPublicIpPrefixAssociation) A list of Public IP Prefix ID's which should be associated with the NAT Gateway resource.

    Deprecated: Inline Public IP Prefix ID Associations have been deprecated in favour of the azurerm_nat_gateway_public_ip_prefix_association resource. This field will be removed in the next major version of the Azure Provider.

    skuName String
    The SKU which should be used. At this time the only supported value is Standard. Defaults to Standard.
    tags Map<String,String>
    A mapping of tags to assign to the resource. Changing this forces a new resource to be created.
    zones List<String>
    A list of availability zones where the NAT Gateway should be provisioned. Changing this forces a new resource to be created.
    resourceGroupName string
    Specifies the name of the Resource Group in which the NAT Gateway should exist. Changing this forces a new resource to be created.
    idleTimeoutInMinutes number
    The idle timeout which should be used in minutes. Defaults to 4.
    location string
    Specifies the supported Azure location where the NAT Gateway should exist. Changing this forces a new resource to be created.
    name string
    Specifies the name of the NAT Gateway. Changing this forces a new resource to be created.
    publicIpAddressIds string[]
    A list of Public IP Address ID's which should be associated with the NAT Gateway resource.

    Deprecated: Inline Public IP Address ID Associations have been deprecated in favour of the azurerm_nat_gateway_public_ip_association resource. This field will be removed in the next major version of the Azure Provider.

    publicIpPrefixIds string[]
    / Deprecated in favour of azure.network.NatGatewayPublicIpPrefixAssociation) A list of Public IP Prefix ID's which should be associated with the NAT Gateway resource.

    Deprecated: Inline Public IP Prefix ID Associations have been deprecated in favour of the azurerm_nat_gateway_public_ip_prefix_association resource. This field will be removed in the next major version of the Azure Provider.

    skuName string
    The SKU which should be used. At this time the only supported value is Standard. Defaults to Standard.
    tags {[key: string]: string}
    A mapping of tags to assign to the resource. Changing this forces a new resource to be created.
    zones string[]
    A list of availability zones where the NAT Gateway should be provisioned. Changing this forces a new resource to be created.
    resource_group_name str
    Specifies the name of the Resource Group in which the NAT Gateway should exist. Changing this forces a new resource to be created.
    idle_timeout_in_minutes int
    The idle timeout which should be used in minutes. Defaults to 4.
    location str
    Specifies the supported Azure location where the NAT Gateway should exist. Changing this forces a new resource to be created.
    name str
    Specifies the name of the NAT Gateway. Changing this forces a new resource to be created.
    public_ip_address_ids Sequence[str]
    A list of Public IP Address ID's which should be associated with the NAT Gateway resource.

    Deprecated: Inline Public IP Address ID Associations have been deprecated in favour of the azurerm_nat_gateway_public_ip_association resource. This field will be removed in the next major version of the Azure Provider.

    public_ip_prefix_ids Sequence[str]
    / Deprecated in favour of azure.network.NatGatewayPublicIpPrefixAssociation) A list of Public IP Prefix ID's which should be associated with the NAT Gateway resource.

    Deprecated: Inline Public IP Prefix ID Associations have been deprecated in favour of the azurerm_nat_gateway_public_ip_prefix_association resource. This field will be removed in the next major version of the Azure Provider.

    sku_name str
    The SKU which should be used. At this time the only supported value is Standard. Defaults to Standard.
    tags Mapping[str, str]
    A mapping of tags to assign to the resource. Changing this forces a new resource to be created.
    zones Sequence[str]
    A list of availability zones where the NAT Gateway should be provisioned. Changing this forces a new resource to be created.
    resourceGroupName String
    Specifies the name of the Resource Group in which the NAT Gateway should exist. Changing this forces a new resource to be created.
    idleTimeoutInMinutes Number
    The idle timeout which should be used in minutes. Defaults to 4.
    location String
    Specifies the supported Azure location where the NAT Gateway should exist. Changing this forces a new resource to be created.
    name String
    Specifies the name of the NAT Gateway. Changing this forces a new resource to be created.
    publicIpAddressIds List<String>
    A list of Public IP Address ID's which should be associated with the NAT Gateway resource.

    Deprecated: Inline Public IP Address ID Associations have been deprecated in favour of the azurerm_nat_gateway_public_ip_association resource. This field will be removed in the next major version of the Azure Provider.

    publicIpPrefixIds List<String>
    / Deprecated in favour of azure.network.NatGatewayPublicIpPrefixAssociation) A list of Public IP Prefix ID's which should be associated with the NAT Gateway resource.

    Deprecated: Inline Public IP Prefix ID Associations have been deprecated in favour of the azurerm_nat_gateway_public_ip_prefix_association resource. This field will be removed in the next major version of the Azure Provider.

    skuName String
    The SKU which should be used. At this time the only supported value is Standard. Defaults to Standard.
    tags Map<String>
    A mapping of tags to assign to the resource. Changing this forces a new resource to be created.
    zones List<String>
    A list of availability zones where the NAT Gateway should be provisioned. Changing this forces a new resource to be created.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the NatGateway resource produces the following output properties:

    Id string
    The provider-assigned unique ID for this managed resource.
    ResourceGuid string
    The resource GUID property of the NAT Gateway.
    Id string
    The provider-assigned unique ID for this managed resource.
    ResourceGuid string
    The resource GUID property of the NAT Gateway.
    id String
    The provider-assigned unique ID for this managed resource.
    resourceGuid String
    The resource GUID property of the NAT Gateway.
    id string
    The provider-assigned unique ID for this managed resource.
    resourceGuid string
    The resource GUID property of the NAT Gateway.
    id str
    The provider-assigned unique ID for this managed resource.
    resource_guid str
    The resource GUID property of the NAT Gateway.
    id String
    The provider-assigned unique ID for this managed resource.
    resourceGuid String
    The resource GUID property of the NAT Gateway.

    Look up Existing NatGateway Resource

    Get an existing NatGateway resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: NatGatewayState, opts?: CustomResourceOptions): NatGateway
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            idle_timeout_in_minutes: Optional[int] = None,
            location: Optional[str] = None,
            name: Optional[str] = None,
            public_ip_address_ids: Optional[Sequence[str]] = None,
            public_ip_prefix_ids: Optional[Sequence[str]] = None,
            resource_group_name: Optional[str] = None,
            resource_guid: Optional[str] = None,
            sku_name: Optional[str] = None,
            tags: Optional[Mapping[str, str]] = None,
            zones: Optional[Sequence[str]] = None) -> NatGateway
    func GetNatGateway(ctx *Context, name string, id IDInput, state *NatGatewayState, opts ...ResourceOption) (*NatGateway, error)
    public static NatGateway Get(string name, Input<string> id, NatGatewayState? state, CustomResourceOptions? opts = null)
    public static NatGateway get(String name, Output<String> id, NatGatewayState state, CustomResourceOptions options)
    resources:  _:    type: azure:network:NatGateway    get:      id: ${id}
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    IdleTimeoutInMinutes int
    The idle timeout which should be used in minutes. Defaults to 4.
    Location string
    Specifies the supported Azure location where the NAT Gateway should exist. Changing this forces a new resource to be created.
    Name string
    Specifies the name of the NAT Gateway. Changing this forces a new resource to be created.
    PublicIpAddressIds List<string>
    A list of Public IP Address ID's which should be associated with the NAT Gateway resource.

    Deprecated: Inline Public IP Address ID Associations have been deprecated in favour of the azurerm_nat_gateway_public_ip_association resource. This field will be removed in the next major version of the Azure Provider.

    PublicIpPrefixIds List<string>
    / Deprecated in favour of azure.network.NatGatewayPublicIpPrefixAssociation) A list of Public IP Prefix ID's which should be associated with the NAT Gateway resource.

    Deprecated: Inline Public IP Prefix ID Associations have been deprecated in favour of the azurerm_nat_gateway_public_ip_prefix_association resource. This field will be removed in the next major version of the Azure Provider.

    ResourceGroupName string
    Specifies the name of the Resource Group in which the NAT Gateway should exist. Changing this forces a new resource to be created.
    ResourceGuid string
    The resource GUID property of the NAT Gateway.
    SkuName string
    The SKU which should be used. At this time the only supported value is Standard. Defaults to Standard.
    Tags Dictionary<string, string>
    A mapping of tags to assign to the resource. Changing this forces a new resource to be created.
    Zones List<string>
    A list of availability zones where the NAT Gateway should be provisioned. Changing this forces a new resource to be created.
    IdleTimeoutInMinutes int
    The idle timeout which should be used in minutes. Defaults to 4.
    Location string
    Specifies the supported Azure location where the NAT Gateway should exist. Changing this forces a new resource to be created.
    Name string
    Specifies the name of the NAT Gateway. Changing this forces a new resource to be created.
    PublicIpAddressIds []string
    A list of Public IP Address ID's which should be associated with the NAT Gateway resource.

    Deprecated: Inline Public IP Address ID Associations have been deprecated in favour of the azurerm_nat_gateway_public_ip_association resource. This field will be removed in the next major version of the Azure Provider.

    PublicIpPrefixIds []string
    / Deprecated in favour of azure.network.NatGatewayPublicIpPrefixAssociation) A list of Public IP Prefix ID's which should be associated with the NAT Gateway resource.

    Deprecated: Inline Public IP Prefix ID Associations have been deprecated in favour of the azurerm_nat_gateway_public_ip_prefix_association resource. This field will be removed in the next major version of the Azure Provider.

    ResourceGroupName string
    Specifies the name of the Resource Group in which the NAT Gateway should exist. Changing this forces a new resource to be created.
    ResourceGuid string
    The resource GUID property of the NAT Gateway.
    SkuName string
    The SKU which should be used. At this time the only supported value is Standard. Defaults to Standard.
    Tags map[string]string
    A mapping of tags to assign to the resource. Changing this forces a new resource to be created.
    Zones []string
    A list of availability zones where the NAT Gateway should be provisioned. Changing this forces a new resource to be created.
    idleTimeoutInMinutes Integer
    The idle timeout which should be used in minutes. Defaults to 4.
    location String
    Specifies the supported Azure location where the NAT Gateway should exist. Changing this forces a new resource to be created.
    name String
    Specifies the name of the NAT Gateway. Changing this forces a new resource to be created.
    publicIpAddressIds List<String>
    A list of Public IP Address ID's which should be associated with the NAT Gateway resource.

    Deprecated: Inline Public IP Address ID Associations have been deprecated in favour of the azurerm_nat_gateway_public_ip_association resource. This field will be removed in the next major version of the Azure Provider.

    publicIpPrefixIds List<String>
    / Deprecated in favour of azure.network.NatGatewayPublicIpPrefixAssociation) A list of Public IP Prefix ID's which should be associated with the NAT Gateway resource.

    Deprecated: Inline Public IP Prefix ID Associations have been deprecated in favour of the azurerm_nat_gateway_public_ip_prefix_association resource. This field will be removed in the next major version of the Azure Provider.

    resourceGroupName String
    Specifies the name of the Resource Group in which the NAT Gateway should exist. Changing this forces a new resource to be created.
    resourceGuid String
    The resource GUID property of the NAT Gateway.
    skuName String
    The SKU which should be used. At this time the only supported value is Standard. Defaults to Standard.
    tags Map<String,String>
    A mapping of tags to assign to the resource. Changing this forces a new resource to be created.
    zones List<String>
    A list of availability zones where the NAT Gateway should be provisioned. Changing this forces a new resource to be created.
    idleTimeoutInMinutes number
    The idle timeout which should be used in minutes. Defaults to 4.
    location string
    Specifies the supported Azure location where the NAT Gateway should exist. Changing this forces a new resource to be created.
    name string
    Specifies the name of the NAT Gateway. Changing this forces a new resource to be created.
    publicIpAddressIds string[]
    A list of Public IP Address ID's which should be associated with the NAT Gateway resource.

    Deprecated: Inline Public IP Address ID Associations have been deprecated in favour of the azurerm_nat_gateway_public_ip_association resource. This field will be removed in the next major version of the Azure Provider.

    publicIpPrefixIds string[]
    / Deprecated in favour of azure.network.NatGatewayPublicIpPrefixAssociation) A list of Public IP Prefix ID's which should be associated with the NAT Gateway resource.

    Deprecated: Inline Public IP Prefix ID Associations have been deprecated in favour of the azurerm_nat_gateway_public_ip_prefix_association resource. This field will be removed in the next major version of the Azure Provider.

    resourceGroupName string
    Specifies the name of the Resource Group in which the NAT Gateway should exist. Changing this forces a new resource to be created.
    resourceGuid string
    The resource GUID property of the NAT Gateway.
    skuName string
    The SKU which should be used. At this time the only supported value is Standard. Defaults to Standard.
    tags {[key: string]: string}
    A mapping of tags to assign to the resource. Changing this forces a new resource to be created.
    zones string[]
    A list of availability zones where the NAT Gateway should be provisioned. Changing this forces a new resource to be created.
    idle_timeout_in_minutes int
    The idle timeout which should be used in minutes. Defaults to 4.
    location str
    Specifies the supported Azure location where the NAT Gateway should exist. Changing this forces a new resource to be created.
    name str
    Specifies the name of the NAT Gateway. Changing this forces a new resource to be created.
    public_ip_address_ids Sequence[str]
    A list of Public IP Address ID's which should be associated with the NAT Gateway resource.

    Deprecated: Inline Public IP Address ID Associations have been deprecated in favour of the azurerm_nat_gateway_public_ip_association resource. This field will be removed in the next major version of the Azure Provider.

    public_ip_prefix_ids Sequence[str]
    / Deprecated in favour of azure.network.NatGatewayPublicIpPrefixAssociation) A list of Public IP Prefix ID's which should be associated with the NAT Gateway resource.

    Deprecated: Inline Public IP Prefix ID Associations have been deprecated in favour of the azurerm_nat_gateway_public_ip_prefix_association resource. This field will be removed in the next major version of the Azure Provider.

    resource_group_name str
    Specifies the name of the Resource Group in which the NAT Gateway should exist. Changing this forces a new resource to be created.
    resource_guid str
    The resource GUID property of the NAT Gateway.
    sku_name str
    The SKU which should be used. At this time the only supported value is Standard. Defaults to Standard.
    tags Mapping[str, str]
    A mapping of tags to assign to the resource. Changing this forces a new resource to be created.
    zones Sequence[str]
    A list of availability zones where the NAT Gateway should be provisioned. Changing this forces a new resource to be created.
    idleTimeoutInMinutes Number
    The idle timeout which should be used in minutes. Defaults to 4.
    location String
    Specifies the supported Azure location where the NAT Gateway should exist. Changing this forces a new resource to be created.
    name String
    Specifies the name of the NAT Gateway. Changing this forces a new resource to be created.
    publicIpAddressIds List<String>
    A list of Public IP Address ID's which should be associated with the NAT Gateway resource.

    Deprecated: Inline Public IP Address ID Associations have been deprecated in favour of the azurerm_nat_gateway_public_ip_association resource. This field will be removed in the next major version of the Azure Provider.

    publicIpPrefixIds List<String>
    / Deprecated in favour of azure.network.NatGatewayPublicIpPrefixAssociation) A list of Public IP Prefix ID's which should be associated with the NAT Gateway resource.

    Deprecated: Inline Public IP Prefix ID Associations have been deprecated in favour of the azurerm_nat_gateway_public_ip_prefix_association resource. This field will be removed in the next major version of the Azure Provider.

    resourceGroupName String
    Specifies the name of the Resource Group in which the NAT Gateway should exist. Changing this forces a new resource to be created.
    resourceGuid String
    The resource GUID property of the NAT Gateway.
    skuName String
    The SKU which should be used. At this time the only supported value is Standard. Defaults to Standard.
    tags Map<String>
    A mapping of tags to assign to the resource. Changing this forces a new resource to be created.
    zones List<String>
    A list of availability zones where the NAT Gateway should be provisioned. Changing this forces a new resource to be created.

    Import

    NAT Gateway can be imported using the resource id, e.g.

     $ pulumi import azure:network/natGateway:NatGateway test /subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/group1/providers/Microsoft.Network/natGateways/gateway1
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    Azure Classic pulumi/pulumi-azure
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the azurerm Terraform Provider.
    azure logo

    We recommend using Azure Native.

    Viewing docs for Azure v4.42.0 (Older version)
    published on Monday, Mar 9, 2026 by Pulumi

      Try Pulumi Cloud free.
      Your team will thank you.

      Start free trial