CloudWatch or Prometheus on AWS: when do you use each?
IntermediateProductionObservability as Code, Security & Vendor Choices
Answer
Use CloudWatch for AWS-managed services (ALB, RDS, Lambda, SQS, DynamoDB): the metrics are already there, free at standard resolution, and some (Lambda throttles, SQS age of oldest message) exist nowhere else. Alarms can trigger Auto Scaling and SNS natively.
Use Prometheus for Kubernetes and application metrics: richer labels, PromQL, no per-metric charge, and a huge exporter ecosystem. CloudWatch custom metrics charge per unique metric/dimension combination, so high-cardinality app metrics are expensive there.
Most AWS shops run both and unify them in Grafana with the CloudWatch data source, or pull key AWS metrics into Prometheus with YACE.
More on Observability as Code, Security & Vendor Choices
What does "observability as code" cover, and why insist on it?BeginnerHow do you manage Grafana with Terraform?IntermediateHow do you validate Alertmanager configuration in CI?BeginnerWhat does a CI pipeline for Prometheus rules look like?IntermediateRaw dashboard JSON, Jsonnet/Grafonnet or the Grafana Foundation SDK: which do you pick?AdvancedWhat are monitoring mixins and how do you consume them?Advanced