Azure Cost Traps: 5 Charges That Keep Billing After You Delete Everything
The short version: deleting things in Azure feels final. Often it is not. A machine you shut down can keep billing. A disk can outlive the computer it belonged to. An IP address can charge you every hour for years, attached to nothing at all. This post walks through five of these quiet charges — the five meters that never switch themselves off — and the documented switch that stops each one. Think of it as Azure cost management from the other side: not the resources you run, but the ones you forgot to switch off.
One honest note before the list: every trap here is proven from Microsoft's own documentation. The quotes below are Microsoft's words, with the source page linked for each trap, and every fix is the documented command or setting — nothing here depends on a screenshot you have to take on faith.
Trap 1 — The stopped VM that still bills
A virtual machine (VM) is a computer you rent inside Microsoft's data centre. Shut yours down from inside Windows or Linux on a Friday, and the screen goes dark — but the machine is only Stopped (Allocated). Azure keeps your place on its hardware, and the compute meter keeps spinning.
Microsoft's own states table says it in one word: Stopped — "Billed"; Deallocated — "Not billed". (States and billing status of Azure VMs.)
The stop: stop the machine through Azure — the portal Stop button, or the command az vm deallocate — and check that the state reads Stopped (deallocated). Only then does the compute meter stop. Disks and networking still bill after that, which is exactly where the next two traps live.
Trap 2 — Orphaned disks: delete the VM, keep paying for its drives
Deleting a VM does not delete its disks by default. That is a safety feature — Azure will not throw your data away just because the computer is gone. But the leftover disks sit unattached, and managed disks bill on their provisioned size: you pay for the whole drive, not the part you used.
Microsoft's words: "After a VM is deleted, you will continue to pay for unattached disks." (Identify unattached Azure disks.)
The stop: open the Disks list, filter to Unattached, confirm the data is truly not needed, and delete. On new VMs, set the disk's deleteOption to Delete so the next teardown cleans up after itself.
Warning: Azure Site Recovery replica disks also show as unattached — and those are your disaster-recovery copies. Never delete a disk whose name starts with ms-asr.
Trap 3 — The static public IP that bills forever
A static public IP address never changes — and Azure charges for it whether anything is using it or not: VM deleted, VM deallocated, address attached to nothing. Microsoft's pricing page says you are charged for a static public IP "irrespective of the associated resource", from the second hour after you create it until the day you delete it. (Azure IP address pricing.)
The rate is small and silent: $0.005 an hour — about $3.65 a month, per address. Leave five addresses behind from five deleted test machines and that is $18.25 leaving your account every month for addresses nobody uses.
The stop: inventory your public IPs and delete the unattached ones. Check first that nothing points at the address — a DNS record, a partner's firewall allow-list — because a deleted address can be handed to someone else.
Trap 4 — The empty App Service plan that still rents its machines
An App Service plan is the reserved server capacity your web apps run on — and you pay for the plan, not for the apps. Delete every app and the plan keeps reserving its configured VM instances, at its tier, times its instance count. Scaled out to three instances last spring? You are renting three empty machines.
Microsoft's words: "App Service plans that have no apps associated with them still incur charges because they continue to reserve the configured VM instances." (Manage an App Service plan; see also Plan and manage costs for App Service.) The trap hides best when the plan lives in a different resource group from the apps it used to run.
The stop: delete the empty plan — or, if you must keep its name, scale it down to the Free tier, which reserves nothing.
Trap 5 — Paying for the same Windows licence twice
Nothing here is broken; a switch was simply never flipped. The pay-as-you-go price of a Windows or SQL Server VM quietly includes the software licence. If your company already owns those licences, you pay for the same licence twice — once on-premises, once inside every Azure VM hour.
The switch is Azure Hybrid Benefit: tell Azure you already own the licence, and the licence charge comes out of the hourly price. Microsoft's headline says you can "save up to 85 percent compared to pay-as-you-go pricing" — read that as their best case, with reservations stacked on top, not a typical bill. (Azure Hybrid Benefit.)
The stop: set the Hybrid Benefit option on the VM — in the portal's Configuration, or licenseType = Windows_Server — but only with licences that genuinely qualify: active Software Assurance (Microsoft's licence-coverage programme) or a qualifying subscription. Microsoft can audit, and the saving is not worth a licence debt.
The checklist — five meters, five stops
- Deallocate, don't just stop —
az vm deallocate, and verify the state reads Stopped (deallocated). - Delete unattached disks — after checking the data, and never an
ms-asrreplica. - Delete unused static IPs — after checking DNS records and firewall lists.
- Delete empty App Service plans — or scale them to Free.
- Switch on Hybrid Benefit — for licences you already own and that genuinely qualify.
Your turn: a test machine was stopped on Friday, and the bill still grew over the weekend. Which of the five meters was still spinning — and what is the one command that stops it? Tell me in the comments, here or on the video.
Every tutorial on this blog is complete and free — full setup, full code, no paywall. If this checklist saved you a surprise bill, the video above walks through each trap with Microsoft's own pages on screen.
Comments
Post a Comment