AWS · Management and Governance
Amazon CloudWatch
Monitoring and observability for AWS and your applications: metrics, logs, alarms, dashboards, traces and automated responses.
On the SAA-C03 exam listMonitoring and observabilityAutomation
What it is and what problem it solves
Amazon CloudWatch collects metrics (numbers over time, such as CPU, latency and queue depth) from AWS services automatically and from your applications as custom metrics; logs in log groups; and traces through application monitoring features. Alarms watch metrics and trigger actions (SNS notifications, Auto Scaling, EC2 actions, Systems Manager). Dashboards visualise them, Logs Insights queries logs, and anomaly detection learns normal patterns.
Metrics are kept at decreasing resolution over time, up to 15 months.
When to use it
- Monitoring every AWS workload and alerting on problems.
- Central application logs with retention policies and queries.
- Scaling resources on metrics, and reacting automatically to thresholds.
When to avoid it
- Recording API activity for audits: CloudTrail.
- Resource configuration compliance: Config.
- Long-term analytics on huge log volumes: export to S3 and query with Athena, or use OpenSearch.
Scaling model and bottlenecks
CloudWatch scales with your usage; cost, not capacity, is the usual constraint for high-cardinality custom metrics and verbose logs.
Limits and quotas
| Item | Value | Context | Source |
|---|---|---|---|
| Metric retention | 1-minute data points for 15 days; 5-minute for 63 days; 1-hour for 455 days (15 months) | High-resolution (sub-minute) points are kept for 3 hours. | Source checked |
Quotas and limits change. Check the linked source before designing around a number.
Cost model
What you pay for
Custom metrics per metric per month, API requests, alarms per alarm-metric, dashboards, logs ingested per GB and stored per GB-month, Logs Insights queries per GB scanned, and features such as synthetic canaries. Basic monitoring metrics for AWS services are free.
Where it is cost-efficient
Default service metrics, sensible log retention, and alarms on a few meaningful signals.
Where costs grow
Verbose application logging, logs kept forever (the default retention), high-cardinality custom metrics (each dimension combination is a metric), and detailed monitoring everywhere.
Cost controls and common surprises
Set log retention on every log group, sample or reduce log levels, use embedded metric format carefully, and archive logs to S3.
Prices differ by Region and change over time; see the pricing page linked under Sources.
Security
Controls the service provides
IAM access control, log group encryption with KMS, cross-account observability, and data protection policies that mask sensitive data in logs.
What you configure
Encrypt sensitive log groups, restrict who can read logs, avoid logging secrets, and centralise logs in a monitoring account.
Logging and monitoring
CloudTrail records CloudWatch API calls.
Related security services
CloudTrail, SNS, EventBridge, X-Ray, Systems Manager.
Shared responsibility
AWS stores metrics and logs. You choose what to collect, retain and alert on.
Availability, backup and failure behavior
Alarms on health signals drive recovery: EC2 auto-recovery, Auto Scaling replacement, and Route 53 health checks using CloudWatch alarms.
Common service combinations
CloudWatch agent on EC2 for memory and disk metrics and logs, SNS for notifications, Auto Scaling policies, EventBridge, Logs subscriptions to Firehose or Lambda.
Business application examples
- An alarm on ALB 5xx errors pages the on-call engineer through SNS.
- Memory and disk metrics collected from EC2 by the CloudWatch agent.
Exam cues and common confusions
- Memory or disk usage on EC2: install the CloudWatch agent (not collected by default).
- Alarm action: SNS, Auto Scaling, EC2 stop/terminate/reboot/recover.
- 1-minute metrics for EC2: detailed monitoring.
- Audit API calls: CloudTrail, not CloudWatch.
Related
Courses and lessons
- Monitoring and limits: CloudWatch, X-Ray, Health, service quotas and throttling · AWS Solutions Architect – Associate (SAA-C03) · Members
Services, comparisons and patterns
- AWS CloudTrail · Service
- AWS X-Ray · Service
- Amazon SNS · Service
- Amazon EC2 Auto Scaling · Service
- Amazon Managed Grafana · Service
- CloudTrail vs Config vs CloudWatch · Comparison
Sources
Independent study material, not affiliated with or endorsed by Amazon Web Services. AWS and service names are trademarks of Amazon.com, Inc. or its affiliates.