AWS · Comparison
CloudTrail vs Config vs CloudWatch
Which service answers my monitoring or audit question: CloudTrail, AWS Config or CloudWatch?
Decision summary
Ask what you want to know:
- "Who did what, and when?" (API calls, sign-ins): CloudTrail.
- "What did this resource look like, did it change, is it compliant?": AWS Config.
- "How is it performing, and alert me when something is wrong" (metrics, logs, alarms): CloudWatch.
They work together: Config links each change to the CloudTrail event that caused it, and CloudTrail can send events to CloudWatch Logs for alarms.
Best fit for each option
CloudTrail
Auditing API activity, security investigations, compliance evidence of who changed what.
AWS Config
Configuration history, compliance rules and automatic remediation of misconfigurations.
CloudWatch
Metrics, logs, dashboards and alarms for operations and performance.
Side by side
| CloudTrail | AWS Config | CloudWatch | |
|---|---|---|---|
| Best for | Who called which API, when, from where | Resource configuration and compliance over time | Performance metrics, logs and alarms |
| Security | Audit evidence; integrity validation | Compliance rules and remediation | Alarms on suspicious patterns from logs |
| Limits | 90 days of event history without a trail | Rules and conformance pack quotas per account | Metric resolution decreases over 15 months |
| Cost | First management-event trail free; data events and Lake charged | Per configuration item and rule evaluation | Custom metrics, logs, alarms and queries |
Scaling and topology
Limits and constraints
| Item | Value | Context | Source |
|---|---|---|---|
| CloudTrail event history | 90 days of management events | Source checked |
|
| CloudWatch 1-hour metric retention | 455 days (15 months) | Source checked |
Quotas and limits change. Check the linked source before designing around a number.
When to avoid each option
CloudTrail
- Performance monitoring or configuration compliance.
AWS Config
- Finding who made a change (use the linked CloudTrail event).
CloudWatch
- Audit trails of API calls.
Example scenarios
| Situation | Choose | Why |
|---|---|---|
| Find who terminated a production instance. | CloudTrail | The TerminateInstances call is in CloudTrail. |
| Prove all S3 buckets stayed encrypted all year. | AWS Config | Configuration history and compliance rules. |
| Get paged when API latency rises. | CloudWatch | A CloudWatch alarm on the latency metric. |
Exam cues
- Who: CloudTrail. What changed / compliant: Config. How it performs / alert: CloudWatch.
Service pages
- AWS CloudTrail · Records the API calls made in your AWS accounts, who made them and from where, for auditing, security investigations and compliance.
- AWS Config · Records how your AWS resources are configured over time and evaluates them against rules, for compliance and change tracking.
- Amazon CloudWatch · Monitoring and observability for AWS and your applications: metrics, logs, alarms, dashboards, traces and automated responses.
Related
Courses and lessons
- Auditing and compliance: CloudTrail, AWS Config and Artifact · AWS Solutions Architect – Associate (SAA-C03) · Members
- 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 Config · Service
- Amazon CloudWatch · Service
- AWS Security Hub · Service
Sources
Independent study material, not affiliated with or endorsed by Amazon Web Services.