Cost Explorer and Cost Anomaly Detection
AWS Cost Explorer for visualizing, forecasting and optimizing costs, Savings Plans and rightsizing recommendations, and AWS Cost Anomaly Detection for catching unusual spend with machine learning.
AWS Cost Explorer
AWS Cost Explorer helps visualize, understand and manage AWS costs and usage over time.
- Create custom reports that analyze cost and usage data.
- Analyze the data at a high level: total costs and usage across all accounts.
- Or at a monthly, hourly or resource level granularity.
- Group and filter by service, linked account, Region, instance type, usage type, tag…
- Choose an optimal Savings Plan (to lower prices on the bill): Cost Explorer recommends a commitment from past usage, an alternative to Reserved Instances.
- Forecast usage up to 18 months based on previous usage (with an 80% prediction interval).
- Shows up to 13 months of history; rightsizing recommendations for EC2.
- The console is free; the Cost Explorer API costs $0.01 per request.
For example, the monthly cost by service view might show that EC2 t2.micro instances cost $480 a month and c4.2xlarge $296, and the Savings Plans page might recommend a $2.40/hour Compute Savings Plan saving about 40%.
AWS Cost Anomaly Detection
- continuously monitors cost and usage using ML to detect unusual spends;
- learns the account's unique, historic spend patterns to detect one-time cost spikes and/or continuous cost increases (no thresholds need to be defined);
- monitors AWS services, member accounts, cost allocation tags or cost categories (AWS managed monitors automatically include new accounts and tags);
- sends the anomaly detection report with root-cause analysis;
- notifies with individual alerts or a daily/weekly summary (using SNS or email).
Real-world examples
- A developer leaves a fleet of GPU instances running after a test. Cost Anomaly Detection alerts the next morning with "EC2, us-west-2, account dev-ml" as the root cause, before the month's bill arrives.
- A finance team uses Cost Explorer's forecast to plan next year's budget, and buys the Savings Plan it recommends.
Exam tips
- "Visualize costs, group by service or tag, forecast" → Cost Explorer.
- "Recommend a Savings Plan or Reserved Instances" → Cost Explorer recommendations.
- "Detect unusual spending automatically, no thresholds" → Cost Anomaly Detection.
Common traps
- "Cost Explorer sends alerts at a threshold." That's AWS Budgets.
- "Anomaly Detection needs a budget amount." It learns the pattern itself.
Hands-on lab: look at your costs
Goal: explore your own costs and set up anomaly detection.
Costs money
The Cost Explorer console and Cost Anomaly Detection are free. Don't use the Cost Explorer API in a loop: each call costs $0.01. Use the management account (or an account with billing access).
Explore
Billing and Cost Management → Cost Explorer. Group by Service for the last 6 months, then switch to Daily and group by Region.
Create a monitor
Cost Anomaly Detection → Create monitor: AWS services, alert subscription with your email, daily summary.
Expected result: a chart of your spend by service, and a monitor that will email you if spend looks unusual.
Clean up: delete the monitor if you don't want the emails (it's free to keep).
AWS documentation
Cost Management
How AWS billing works, the cost management tools by job (organize, analyze, control, save), and which tool answers which exam question.
Budgets, Cost and Usage Report and cost allocation tags
AWS Budgets for cost and usage alerts and budget actions, the Cost and Usage Report and Data Exports for detailed billing data, and cost allocation tags and cost categories for tracking spend by team.