Sub topic 1
How Cloud Pricing Works
Prerequisites
Assume you know the basics of compute, storage, and networking services, can run terminal commands, and can read JSON.
How cloud pricing works
Cloud services usually use usage-based pricing: you pay for the resources consumed, such as instance-hours, stored gigabytes, or transferred bytes. Other models include:
- Provisioned pricing, where you pay for allocated capacity whether or not you use it.
- Tiered pricing, where the price changes after usage crosses a threshold.
- Commitment discounts, which reduce the rate when you commit to a level of usage.
- Spot pricing, which offers spare capacity at a lower price but can interrupt workloads.
Your bill is usually the sum of service usage, discounts, taxes, and data-transfer charges.
Where the money goes: compute, storage and data transfer
Compute charges come from running virtual machines, containers, serverless functions, and databases. The main factors are runtime, instance size, request count, and provisioned capacity.
Storage charges depend on stored data, storage class, requests, and backups. An unattached disk can continue charging even when no application uses it.
Data transfer often costs more when data crosses regions, availability zones, or the public internet. Keeping related services in the same region and reducing unnecessary replication can lower these charges.
| Cost area | Common billing unit | Typical control |
|---|---|---|
| Compute | Instance-hours or requests | Resize or schedule resources |
| Storage | GB-month and requests | Delete unused data and use lifecycle rules |
| Transfer | GB transferred | Keep traffic local and reduce egress |
Seeing your spend with billing and cost-analysis tools
Use AWS Cost Explorer to group costs by service, account, region, or activated cost-allocation tag:
aws ce get-cost-and-usage \
--time-period Start=2026-10-01,End=2026-11-01 \
--granularity MONTHLY \
--metrics UnblendedCost \
--group-by Type=DIMENSION,Key=SERVICEStart with service totals, then filter by account, region, or tag to explain changes.
Tagging and allocating costs to owners
A tag is a key-value label attached to a resource, such as Team=Payments or Environment=Production. Define required keys, allowed values, and an owner for each application. Activate the relevant user-defined cost allocation tags in AWS Billing, then group reports by those tags.
Tags only help when coverage is consistent. Track untagged spend separately and assign ownership for fixing it.
Exercise
A team sees high storage costs but cannot identify the responsible application. What should it do first?
Show answer
Group costs by service and activated cost-allocation tags, then investigate untagged resources and unused storage.