Datadog & AWS Cost Explorer: Observability & FinOps Guide
Combining Datadog telemetry (metrics, logs, APM traces, events) with AWS Cost Explorer and AWS Cost and Usage Reports (CUR 2.0) lets infrastructure teams see performance and spend side by side—catching outages faster and stopping silent cloud bill spikes before month-end.
1. Datadog + AWS Integration Architecture
AWS Account(s)
├── CloudWatch Metric Streams (low-latency Firehose) ──▶ Datadog Metrics
├── CloudTrail / VPC Flow Logs / RDS / Lambda Logs ──▶ Datadog Logs (Forwarder / Firehose)
├── AWS Resource Collection (EC2, RDS, S3, EKS, SG) ──▶ Datadog Infrastructure & Recommendations
└── AWS Management Account (CUR 2.0 in S3) ──▶ Datadog Cloud Cost Management (CCM)
Integration Best Practices
- Use IAM Role Delegation (External ID): Connect Datadog to AWS via a least-privilege IAM role rather than static IAM keys.
- Prefer CloudWatch Metric Streams over API Polling: Metric Streams deliver AWS telemetry to Datadog in near real time (~2–3 minutes latency vs. 10–15 minutes for polling) and scale cleanly across large accounts.
- Enable Resource Collection: Turn on Resource Collection on the Datadog AWS integration tile so Datadog can map live infrastructure configurations (idle EC2s, outdated
gp2volumes, unattached EBS disks, oversized RDS instances) directly to dollar savings. - Limit Namespace Collection: Only ingest CloudWatch namespaces you actively monitor or alert on so you don't pay for unused metric ingestion.
2. Unifying Datadog Cloud Cost Management (CCM) & AWS Cost Explorer
While AWS Cost Explorer is great for quick native billing breakdowns, Savings Plans/RI utilization, and AWS Budgets, integrating CUR 2.0 into Datadog Cloud Cost Management bridges the gap between finance data and live engineering telemetry.
Required CUR Setup Checklist
- Configure CUR / CUR 2.0 from the AWS Management (Payer) Account: Never configure from a member account; the management account captures organization-wide volume discounts, consolidated billing, and Savings Plans amortization.
- Enable Critical Billing Preferences: Ensure Linked Account Access, Linked Account Refunds and Credits, and Linked Account Discounts are enabled so Datadog cost figures reconcile cleanly with AWS Cost Explorer.
- Activate AWS Cost Allocation Tags: Enable your standard IaC tags (
Environment,Team,Service,Owner) in the AWS Billing console so both Cost Explorer and Datadog CCM can break down spend by team and product. - Enforce Tagging with Datadog Scorecards: Create Scorecard rules that flag untagged or improperly tagged services and assign accountability back to service owners.
High-Value Unified Dashboards
Pair infrastructure health and daily spend on the same screen:
- Compute & EKS: Daily EC2/EKS cost broken down by namespace/deployment/pod next to CPU/memory utilization P95 (exposes over-provisioned pods immediately).
- Databases (RDS): Instance + storage + IOPS spend next to
DatabaseConnections,CPUUtilization,ReadLatency/WriteLatency, andFreeStorageSpace. - Networking: NAT Gateway & cross-AZ transfer spend next to bytes processed (a top hidden AWS cost driver when S3/ECR VPC Gateway Endpoints are missing).
- Serverless (Lambda): Invocation cost & duration next to
Errors,Throttles, andConcurrentExecutions.
3. Incident Alerting & Cost Anomaly Monitors
Infrastructure & Performance Monitors
- Alert on symptoms and saturation, not noise: Focus pager alerts on user-impacting SLO burn (5xx spikes, latency P99 breaches, RDS storage < 15%, replication lag, Lambda throttles, unhealthy ALB targets).
- Attach runbook links to every monitor: Include the exact Datadog dashboard URL, affected AWS account/region tags, and the matching Troubleshooting Runbook inside every alert payload.
- Use Composite Monitors: Combine signals (e.g., high CPU and elevated latency) to cut false-positive alert fatigue.
Proactive Cost Anomaly Detection
- Configure AWS Cost Anomaly Detection (via Cost Explorer) and Datadog Cost Anomaly Monitors to alert Slack/PagerDuty when daily spend deviates from historical baselines—catching runaway autoscaling loops, forgotten GPU test instances, or NAT Gateway spikes within 24 hours instead of 30 days.
- Route Datadog Cloud Cost Recommendations (rightsizing idle instances,
gp2→gp3upgrades, unused EIPs/EBS volumes) directly into team backlog tickets.
4. Controlling Datadog’s Own Observability Spend
Monitoring AWS spend shouldn't cause your Datadog bill to balloon:
- Prevent High-Cardinality Tags: Never attach unbounded values (
user_id,request_id, raw URLs with query strings, pod UUIDs where unnecessary) to custom metrics. - Use Log Exclusion Filters & S3 Archiving: Index only actionable logs (
ERROR,WARN, security/audit events, sampledINFO). Route noisy debug logs and raw VPC Flow/ELB access logs to cheap S3 archives and rehydrate only during incident investigations. - Review Metrics Without Limits™: Drop unused tag combinations on expensive custom metrics while retaining the dimensions your dashboards and alerts actually query.