SkarpSkarp

Chapter 11 of 21

Azure Cost Management and Pricing Fundamentals

Follow the money in Azure by understanding what drives costs, how pricing calculators work, and which tools help you stay on budget.

27 min readen

Follow the Money: How Azure Billing Works at a High Level

From Security to Cost

Earlier, you learned how Microsoft Entra ID and RBAC control who can do what in Azure. Now we shift to how much those actions cost and how Azure bills you.

Subscriptions and Meters

Azure bills at the subscription level. Every billable resource exposes meters (like VM hours, GB stored, or transactions). Usage on each meter is multiplied by its unit price.

Consumption-Based Pricing

Most Azure services use consumption-based pricing: you pay for what you use. Some services add discounts when you commit to capacity or time, such as reserved instances or savings plans.

Why Tools Matter

Because prices vary by region, tier, and licensing model, Azure provides tools like the pricing calculator, TCO calculator, and Cost Management to estimate and monitor spend.

Module Goals

You will learn what drives Azure costs, how to estimate them, how Azure Cost Management works, and how tags and design choices affect cost in real and exam scenarios.

Key Factors That Influence Azure Costs

Service and Tier Choice

Different services and tiers have different prices. A VM-based web app often costs more to run and manage than an Azure App Service plan with similar capacity.

Region and Price

Azure prices vary by region. Choosing a cheaper region might save money but can affect latency, data residency, and compliance, which you must weigh carefully.

Size and Performance

Larger VM sizes or higher-performance database tiers cost more. Over-provisioning capacity is a common cause of unnecessary cloud spend.

Usage and Runtime

How long resources run matters. A VM running 24x7 all month costs far more than one that runs only during office hours or scales down when idle.

Data Transfer and Licensing

Inbound data is generally free, but outbound and cross-region traffic often costs money. Licensing options like Azure Hybrid Benefit can also lower costs.

Cost Drivers in a Simple Web App Scenario

Two Designs

Design A: two VMs with disks and a load balancer. Design B: an Azure App Service plan hosting the website with autoscaling enabled.

IaaS vs PaaS Costs

Design A (IaaS) charges for VM hours, OS licenses, disks, and networking. Design B (PaaS) charges mainly for App Service Plan capacity and outbound data.

Scaling and Waste

With VMs, you must manually or script scaling and shutdowns to save money. App Service autoscale can reduce cost by matching instances to demand.

Data and Management

Both designs pay similar outbound data charges. But VMs need more admin time for patching and monitoring, while App Service reduces that overhead.

Likely Cheaper Choice

For many small-to-medium sites, App Service is usually cheaper and simpler than VMs, which is a pattern you will often see in AZ-900 exam scenarios.

Consumption-Based Pricing, Reservations, and Savings Plans

Pay-as-You-Go

In pay-as-you-go, you pay only for what you use. It is flexible and ideal for unpredictable or short-lived workloads but may not be the cheapest long term.

Reserved Capacity

With reservations, you commit to a specific resource type for 1 or 3 years and receive a large discount, ideal for steady, always-on workloads.

Savings Plans for Compute

Savings plans let you commit to a certain hourly compute spend and get discounts across eligible compute services, offering more flexibility than classic reservations.

Spot VMs

Spot VMs offer very low prices for unused capacity but can be evicted at any time, so they are only appropriate for interruptible, non-critical tasks.

Exam Takeaways

Know that pay-as-you-go is flexible, reservations and savings plans lower costs for predictable usage, and Spot VMs trade reliability for the lowest price.

Azure Pricing Calculator: Estimating Solution Costs

What the Calculator Does

The Azure pricing calculator lets you build an estimate by adding services, setting region, size, and usage, and then showing an approximate monthly cost.

Configuring Services

You choose services like VMs or databases, then configure options such as region, tier, instance size, storage type, and quantity to see price changes.

Usage Inputs

You can enter hours per month, GB stored, or data egress amounts. The calculator multiplies these by current public prices in the selected region.

Sharing and Limits

Estimates can be saved or exported for budgeting. Remember: it is only an estimate and may not reflect discounts or hybrid benefits unless configured.

Exam Pattern

If you need to estimate costs before deployment, the correct answer is the Azure pricing calculator, not Cost Management or the TCO calculator.

Azure TCO Calculator: Comparing On-Premises vs Azure

Purpose of TCO Calculator

The Azure TCO calculator compares the cost of running workloads on-premises with running them in Azure over several years.

On-Premises Inputs

You enter details about your current environment: number of servers, storage, databases, networking, and assumptions like power and labor costs.

Mapping to Azure

The tool maps your on-premises workloads to Azure services and uses Azure pricing data to estimate equivalent cloud costs.

Multi-Year Comparison

Results show on-premises vs Azure total cost of ownership across a chosen period, helping with migration justification and planning.

Exam Distinction

Remember: pricing calculator estimates Azure solution cost; TCO calculator compares on-prem vs Azure; Cost Management monitors actual spend.

Azure Cost Management and Billing: Monitoring and Controlling Spend

What Cost Management Does

Azure Cost Management and Billing helps you track, analyze, and optimize your actual cloud spend after resources are deployed.

Cost Analysis Views

You can see costs by subscription, resource group, service, or tag, and filter by date range to understand where money is going.

Budgets and Alerts

Set budgets for subscriptions or resource groups and configure alerts when actual or forecasted costs cross thresholds such as 80% or 100%.

Recommendations and Access

Cost Management surfaces savings recommendations and obeys RBAC, so only users with proper roles can view or change cost settings.

Exam Clue

When the question is about monitoring or limiting ongoing spend with budgets and alerts, think Azure Cost Management and Billing.

Tagging Resources to Support Cost Allocation and Reporting

What Tags Are

Tags are name-value pairs (like Department=HR) that you attach to resources, groups, or subscriptions to organize and report on them.

Tags for Cost Allocation

In Cost Management, you can filter and group costs by tags, such as CostCenter or Project, to see who is responsible for which charges.

Chargeback and Showback

Finance teams can use tag-based reports to bill departments for their usage (chargeback) or simply show them their spending (showback).

Enforcing Tags with Policy

Azure Policy can require specific tags, audit missing ones, or even block deployments that do not include mandatory cost-related tags.

Exam Reminder

Tags are for organization and reporting, not performance. When you see questions about cost allocation or reporting by department, think tags.

Thought Exercise: Designing for Cost in a Simple Scenario

Imagine you are advising a startup that is moving a small internal line-of-business app to Azure. They have the following requirements:

  • Around 50 employees use the app during business hours only, Monday–Friday.
  • The app uses a web front end and a small SQL database.
  • The company wants to keep costs low but also avoid heavy admin overhead.
  • They need basic cost visibility by department: `Sales` and `Support`.

Think through these questions (you do not need to write full code; just reason conceptually):

  1. Service choice
  • Would you choose VMs or a PaaS service (like App Service and Azure SQL Database) for the web app and database? Why, from a cost and admin perspective?
  1. Runtime and scaling
  • How could you avoid paying for full 24x7 capacity when users only work business hours?
  • Would autoscaling or scheduling be helpful here?
  1. Tagging strategy
  • Which tags would you apply to the web app and database to help with cost allocation between Sales and Support?
  • Would you tag at the resource group level, resource level, or both?
  1. Tools to use
  • Which tool would you use before deployment to estimate the monthly cost of your design?
  • Which tool would you use after deployment to track actual spend and set alerts?

Pause for a minute and mentally design your solution. Then compare your thinking to the key ideas:

  • PaaS (App Service + Azure SQL Database) usually lowers admin overhead and can be cost-effective.
  • Autoscale or scheduled scaling can reduce runtime cost.
  • Tags like `Department`, `Environment`, and `Project` support cost reports.
  • Use the Azure pricing calculator for estimates and Azure Cost Management for ongoing monitoring.

Quick Check: Cost Tools and Concepts (1)

Answer this AZ-900-style question about Azure cost tools.

Your team is planning a new Azure solution and wants to estimate the monthly cost of running two web apps and a database in a specific region before deploying anything. Which Azure tool should you use?

  1. Azure Cost Management and Billing
  2. Azure pricing calculator
  3. Azure Total Cost of Ownership (TCO) calculator
  4. Azure Advisor
Show Answer

Answer: B) Azure pricing calculator

The Azure pricing calculator is used to estimate the cost of specific Azure services and configurations *before* deployment. Azure Cost Management and Billing analyzes actual spend after deployment. The TCO calculator compares on-premises vs Azure costs, and Azure Advisor provides optimization recommendations, not upfront pricing estimates.

Quick Check: Cost Drivers and Savings (2)

Test your understanding of cost drivers and pricing models.

A company runs a critical production web application that must be available 24x7 and has a very stable, predictable load. They want to reduce compute costs for the next three years without sacrificing reliability. Which option is MOST appropriate?

  1. Use Spot VMs for the web servers
  2. Rely only on pay-as-you-go pricing
  3. Purchase reserved instances or a savings plan for compute
  4. Move the app to a free tier in Azure App Service
Show Answer

Answer: C) Purchase reserved instances or a savings plan for compute

For stable, always-on workloads, purchasing reserved instances or an Azure savings plan for compute is the best way to reduce cost while maintaining reliability. Spot VMs are interruptible and not suitable for critical apps. Pay-as-you-go is flexible but not the cheapest for predictable usage. Free tiers are limited and typically not appropriate for production workloads.

Key Terms Review: Azure Cost and Pricing

Flip through these flashcards to reinforce the main cost and pricing concepts for AZ-900.

Consumption-based (pay-as-you-go) pricing
A pricing model where you pay only for the resources you actually use, such as VM hours, GB stored, or data transfer, with no long-term commitment.
Reserved capacity / reserved instances
An option where you commit to using specific Azure resources (such as a VM family in a region) for 1 or 3 years in exchange for a significant discount over pay-as-you-go.
Azure savings plan for compute
A flexible discount model where you commit to a certain hourly spend on compute for 1 or 3 years, and Azure automatically applies discounts to eligible compute services.
Azure pricing calculator
A web-based tool used to estimate the cost of Azure services and configurations before deployment by selecting services, regions, tiers, and usage assumptions.
Azure TCO calculator
A tool that compares the total cost of ownership of running workloads on-premises versus in Azure over a multi-year period.
Azure Cost Management and Billing
The built-in Azure service used to analyze, monitor, and optimize actual cloud spend, including cost analysis, budgets, and alerts.
Tags (for cost management)
Name-value pairs applied to resources, resource groups, or subscriptions (for example, Department=Finance) that allow you to group and filter costs for allocation, chargeback, and reporting.
Data egress cost
Charges that apply when data leaves Azure, such as outbound traffic to the internet or between regions; inbound data is generally free.
Cost allocation
The process of assigning cloud costs to specific departments, projects, or cost centers, often using tags and Cost Management reports.
Budgets in Azure Cost Management
Configured spending limits at subscription or resource group scope that trigger alerts when actual or forecasted costs exceed defined thresholds.

Key Terms

Tags
Name-value metadata pairs applied to Azure resources, resource groups, or subscriptions to support organization, governance, and cost reporting.
Budget
A configurable spending limit in Azure Cost Management that tracks actual and forecasted costs against a target amount and can trigger alerts.
Spot VMs
Deeply discounted virtual machines that use unused Azure capacity but can be evicted at any time, suitable only for interruptible workloads.
Cost allocation
The practice of assigning cloud spending to specific departments, projects, or cost centers, often using tags and Cost Management reports.
Azure pricing calculator
A web-based tool used to estimate the cost of Azure services and configurations before deployment by selecting services, regions, tiers, and usage assumptions.
Consumption-based pricing
A pay-as-you-go model where you are billed based on the actual usage of resources such as compute hours, storage, and data transfer.
Azure savings plan for compute
A flexible discount model where you commit to a certain hourly compute spend and receive discounts across eligible compute services.
Azure Cost Management and Billing
The built-in Azure service used to analyze, monitor, and optimize actual cloud spend, including cost analysis views, budgets, alerts, and savings recommendations.
Reserved capacity / reserved instances
A pricing option where you commit to specific Azure resources for 1 or 3 years in exchange for discounted rates compared to pay-as-you-go.
Azure Total Cost of Ownership (TCO) calculator
A planning tool that compares the total cost of running workloads on-premises versus in Azure over a multi-year period.

Finished reading?

Test your understanding with a custom practice exam on this chapter.

Test yourself