Manage Costs with Budgets, Alerts and Azure Advisor
30-second answer
In Microsoft Cost Management a budget sets a spending limit for a scope (management group, subscription, resource group, optionally filtered by tag) over a reset period (monthly, quarterly or annually). Its alert conditions fire on Actual or Forecasted cost at a percentage you choose, emailing recipients and optionally calling an action group. A budget doesn't stop resources by itself; automation behind the action group can. Cost alerts collect budget, credit and anomaly alerts. Azure Advisor gives free cost recommendations, such as right-sizing or shutting down idle VMs and buying reservations. Cost data refreshes a few times a day, so alerts aren't instant.
Simulate it » No Azure account neededExam objective: 1.3.6 Manage costs by using alerts, budgets, and Azure Advisor recommendations. (Skills measured as of April 17, 2026)
Simulations
Feel it before you read it. No account needed, nothing leaves this page.
Search for <strong>Cost Management</strong>, then pick the subscription scope.
👆 Click the glowing item in the portal to continue
Read the steps as text
- Search for Cost Management, then pick the subscription scope.
- Type cost management in the search bar and pick Cost Management under Services.
- Under Monitoring → Budgets, select + Add.
- A filter on tag costcenter = FIN-042 makes this the finance team's budget. Reset period decides when the count starts again.
- Actual alerts fire on what you've spent; Forecasted fires when Azure predicts you'll cross the line. An action group can email, text or run an automation.
- Spend data refreshes a few times a day, so alerts aren't instant. Here the 50% and 80% alerts have already fired, and Cost alerts lists them with any anomaly alerts.
- Now search for Advisor.
- Type advisor in the search bar and pick Advisor under Services.
- Azure Advisor recommends savings across Cost, Security, Reliability, Operational excellence and Performance. CLI: az advisor recommendation list --category Cost -o table.
🧪 Simulation for learning. Screens are simplified versions of the Azure portal; names, prices and IDs are examples. Nothing here touches real Azure.
🖱️ Drag to rotate · scroll or pinch to zoom
Budgets and Advisor
A budget watches spend for a scope and sends alerts at thresholds, on actual or forecasted cost, optionally to an action group. It doesn't stop anything by itself. Azure Advisor points at savings like idle VMs.
🤔 What happens if…
Read this tour as text
- Users and groups in your tenant. Your Microsoft Entra tenant holds users and groups. In an assigned group you add people yourself. In a dynamic group a rule such as
user.department -eq "Sales"adds and removes them as their properties change (Entra ID P1). - Licenses and guests. Group-based licensing gives every member of a group a license, and takes it back when they leave. A direct assignment needs the user's usage location first. A guest from a partner tenant signs in with their own account (B2B collaboration).
- Self-service password reset. SSPR lets users reset their own password at aka.ms/sspr. You choose who it's for (None, Selected group or All) and how many methods they must prove (1 or 2). Users must register methods before they can use them.
- The management ladder. Management groups sit above subscriptions, which hold resource groups, which hold resources. You can nest management groups six levels below the Tenant Root Group. Move a subscription and it takes on its new parent's policies and roles.
- Role assignments flow down. An Azure role assignment = who (user, group, service principal, managed identity) + role definition + scope. Assign it at a management group and it inherits to every subscription, resource group and resource below.
- Effective access. Roles add up. Owner does everything, Contributor everything except grant access, Reader only looks, and User Access Administrator only manages access. A deny assignment beats every role.
- Azure Policy: deny, audit, modify. Azure Policy checks what gets deployed. Deny refuses it, Audit lets it in but flags it non-compliant, Modify changes it (for example adds a tag) and needs a managed identity. A remediation task fixes resources that already exist.
- Locks and tags. A CanNotDelete lock lets people change a resource but not delete it. A ReadOnly lock blocks every write. Locks apply to everyone, Owners too. Tags on a resource group aren't inherited unless a policy copies them down.
- Budgets and Advisor. A budget watches spend for a scope and sends alerts at thresholds, on actual or forecasted cost, optionally to an action group. It doesn't stop anything by itself. Azure Advisor points at savings like idle VMs.
Finance wants every resource tagged with its cost center, nothing outside Europe, production frozen during the audit, and an alert before the month's spend runs away. Build all four guardrails and see each one bite.
🎓 Education-only simulation. Your lab is saved in this browser, so you can leave and continue later.
😟 THE PROBLEM
The finance team found out about a runaway bill when the invoice arrived.
😊 THE SOLUTION
Set budgets with actual and forecast alerts, and act on Advisor's cost tips.
- Surprise invoices✓ Budget alerts at 50, 80, 100%
- Overspend spotted too late✓ Forecasted alerts
- Idle VMs running✓ Advisor right-size tips
Start with a question
How do you stop your phone bill from shocking you at the end of the month?
Most phone apps let you set a data warning: a text at 50% of your allowance, another at 80%. Some even tell you “at this rate you’ll run out by the 20th”. The warning doesn’t cut you off, it just gives you time to switch to Wi-Fi. And now and then the app suggests a cheaper plan because you never use half of what you pay for.
In Azure the warnings are budget alerts (actual and forecasted), and the “cheaper plan” tip is Azure Advisor.
Explain it like I’m 10
The technical explanation
Budgets
Portal: Cost Management → Budgets → + Add (pick the scope first). Two tabs:
Create a budget
- Scope: management group, subscription, resource group (or a billing scope). Filters narrow it, for example Tag: costcenter = FIN-042 or one resource type.
- Budget details: name, reset period (Monthly, Quarterly, Annually, or billing month/quarter/year), creation date and expiration date.
- Budget amount, with a suggested figure based on past spend.
Set alerts
- Alert conditions: Type (Actual or Forecasted), % of budget, and an optional action group.
- Alert recipients (email) and language.
az consumption budget create --budget-name fin-monthly --amount 500 \
--category cost --time-grain monthly \
--start-date 2026-12-01 --end-date 2027-11-30 --resource-group rg-finance
az consumption budget list -o table
New-AzConsumptionBudget -Name fin-monthly -Amount 500 -Category Cost -TimeGrain Monthly `
-StartDate 2026-12-01 -EndDate 2027-11-30 -ContactEmail finance-ops@contoso.com -NotificationKey a80 -NotificationThreshold 80 -NotificationEnabled
Budgets don’t stop anything. To act, point an alert at an action group that runs an Automation runbook, Logic App, Azure Function or webhook, for example to deallocate dev VMs. Cost data is refreshed several times a day (up to about every 4 hours for most scopes), so alerts can lag real spending.
Cost alerts
Cost Management → Cost alerts lists budget alerts, credit alerts (for prepaid commitments) and department spending quota alerts for EA, plus anomaly alerts, which you subscribe to from Cost analysis’s smart views to get an email when daily spend jumps or drops unexpectedly.
Azure Advisor
Advisor is free and studies your usage. Its Cost recommendations include:
- Right-size or shut down underutilised VMs (based on CPU and network over a lookback period you can configure).
- Buy reservations or savings plans for steady workloads.
- Delete unattached public IP addresses and idle resources.
- Use lifecycle management or cheaper tiers for storage.
Each recommendation shows impact, affected resources and estimated savings, and you can postpone or dismiss it. Advisor also covers Security, Reliability, Operational excellence and Performance, and an Advisor score shows progress. You can set up Advisor alerts and weekly recommendation digests to an action group.
az advisor recommendation list --category Cost -o table
az advisor configuration update --low-cpu-threshold 10 # VM utilisation rule
-
1 Set
$500 monthly budget filtered to costcenter = FIN-042.
-
2 Day 14
Forecasted 100% alert: on track to spend $560. Finance gets an email.
-
3 Act
Advisor flags two idle VMs; the team deallocates them.
-
4 Day 30
Actual spend lands at $470: the 80% alert fired, 100% never did.
Architect level Budgets at scale
Budgets can be deployed with ARM, Bicep or the Consumption REST API, so a subscription-vending pipeline can create one for every new subscription. Management group budgets work for most offer types but not every billing setup; check the scope support for your agreement. For chargeback, combine tag policies (so the data is right), cost allocation rules (to split shared costs like a hub network) and scheduled exports to a storage account for Power BI.
Real-world business scenario
Wide World Importers (fictional)
- The problem
- A load test left 40 large VMs running over a long weekend, and the bill arrived three weeks later, triple the usual amount.
- What they used
- Monthly budgets on each subscription with Actual alerts at 50% and 80% and a Forecasted alert at 100%. The dev subscription's 90% alert calls an action group that runs an Automation runbook to deallocate VMs tagged env=dev. Anomaly alerts and Advisor's weekly digest go to the platform team.
- Why that choice
- Overspend shows up within hours instead of weeks, and dev environments switch themselves off before the budget is gone.
- The result
- Monthly spend became predictable, and acting on Advisor's right-size tips saved about 18% on compute.
When to use it and when not to
✓ Use it when…
- A budget on every subscription, with Actual and Forecasted alerts.
- Tag-filtered budgets when several departments share a subscription.
- Action groups with automation for non-production shutdowns.
✕ Think twice when…
- Treating a budget as a hard spending cap.
- Acting on Advisor right-size tips for workloads with rare but important peaks without checking first.
↔ Alternatives to consider
- Reservations and savings plans for steady workloads, which Advisor recommends.
- Auto-shutdown on dev VMs, which needs no budget at all.
Test yourself with exercises
5 original practice questions in the AZ-104 style. Pick your answers, then check them. You will see why each option is right or wrong. Score 75% or more and this topic is marked complete.
Interview preparation
Say your answer out loud first, then open the model answer. Interviewers care more about your reasoning than the exact words.
Beginner Does an Azure budget stop spending when you hit it?
Model answer
No. A budget only alerts. If you want something to happen, like shutting down dev VMs, you connect an action group that runs an automation runbook or a Logic App. Spending limits that actually stop services exist only on some credit-based offers.
Intermediate Actual or forecasted alerts?
Model answer
Both. Actual at 50 and 80 percent tells you where you are. Forecasted at 100 percent warns you mid-month that you're on track to overspend, which gives you time to act instead of finding out on the last day.
Experienced developer How would you give each department its own budget in one subscription?
Model answer
Tag resources with costcenter, enforce the tag with policy, then create a budget per department at the subscription scope with a filter on that tag value. Each budget's alerts go to that department's distribution list and action group.
Scenario Finance wants dev/test VMs shut down automatically if the dev subscription hits 90% of budget. How?
Model answer
A budget on the dev subscription with an Actual alert at 90% that calls an action group. The action group triggers an Automation runbook or Logic App with a managed identity that has Virtual Machine Contributor, which deallocates the tagged dev VMs.
Quick revision
Key points
- Budgets have a scope, amount, reset period, start and expiry dates, and optional filters such as tags.
- Alert conditions are Actual or Forecasted at a percentage, sent to emails and optionally an action group.
- Budgets don't stop resources. Use an action group with automation to act.
- Cost data refreshes a few times a day, so alerts lag spending.
- Advisor cost recommendations - right-size or shut down idle VMs, reservations, delete unused public IPs and disks.
Important terminology
- Budget
- A spending target for a scope and reset period, with alert conditions at percentages of the amount.
- Actual alert
- A budget alert that fires when accrued cost reaches the threshold.
- Forecasted alert
- A budget alert that fires when Azure predicts cost will reach the threshold by the end of the period.
- Action group
- An Azure Monitor list of notifications and actions (email, SMS, webhook, runbook, Logic App) that alerts can call.
- Anomaly alert
- A Cost Management alert when daily spend is unusually high or low compared with the usual pattern.
- Azure Advisor
- A free service that recommends improvements in cost, security, reliability, operational excellence and performance.
- Advisor score
- A percentage that shows how closely your resources follow Advisor's recommendations.
Common mistakes
- Expecting a budget to cap spending on a pay-as-you-go subscription.
- Relying only on Actual alerts and finding out about overspend at the end of the month.
Exam tips
- "Email the team when spend reaches 80%" = budget with an Actual 80% alert.
- "Shut down resources automatically when the budget is reached" = budget alert + action group + runbook or Logic App.
- "Identify underused VMs" = Azure Advisor cost recommendations.
Five quick revision questions
-
1.What are the two alert types on a budget?Show
Actual and Forecasted.
-
2.Does a budget stop resources when it's exceeded?Show
No. It sends alerts; automation must do the stopping.
-
3.Which service recommends right-sizing idle VMs?Show
Azure Advisor.
-
4.What can a budget alert call besides email?Show
An action group (SMS, webhook, runbook, Logic App and more).
-
5.Which CLI command lists Advisor cost recommendations?Show
az advisor recommendation list --category Cost
Official references
Finished this lesson? Tick it off. Your progress is saved in this browser.
Next up: Storage Firewalls and Virtual Network Rules
Lesson done? Make it stick with a quick gameSort It, Match the Pairs, Lightning Round and Who Am I? Earn XP and badges.