Skip to main content
An Azure NAT gateway is billed for every hour it exists, plus a charge per GB it processes. When the subnets it serves send no outbound traffic, you pay the hourly charge for nothing. nOps finds NAT gateways billed every day for two weeks with no data processed, and estimates the saving from deleting them.

Why it matters

NAT gateways often stay in place after the workloads in their subnets are moved or removed, and keep billing every hour.

How nOps finds it

nOps reads your Azure NAT Gateway billing. A NAT gateway is flagged when its hourly charge was billed on all of the last 14 days and it processed no data at all in that time. The saving is everything the NAT gateway cost in the last 7 days, net of discounts and scaled to a month, and must be at least $5 a month. Accounts where credits cover almost all of the cost are left out.

Before you start

Permission to change subnets and delete NAT gateways (for example Network Contributor).

How to implement

  1. In the Azure portal, open NAT gateways, select the gateway and check Subnets to see which subnets use it.
  2. Confirm no workload in those subnets needs outbound internet access, now or for planned jobs.
  3. Remove the NAT gateway from each subnet (Subnets → Disassociate).
  4. Delete the NAT gateway, or run az network nat gateway delete --resource-group MY_RG --name MY_NAT.
  5. Delete its public IP addresses or prefixes too if nothing else uses them.

Risks and considerations

  • Resources in the subnet lose the outbound path the NAT gateway gave them. Workloads that call the internet only now and then, such as monthly jobs or patching, may not show up in two weeks of data.
  • Partners that allowlist your NAT public IP will see a different address if you recreate the gateway with a new IP.
  • To roll back, create a new NAT gateway and associate it with the subnets again.