CloudWatch Logs Cost Advisor · guide

CloudWatch Logs cost: retention, ingestion and Infrequent Access

Short answer: the bill is mostly ingestion. Retention policies are worth setting everywhere, but they trim the small line; the large saving comes from logging less.

What it costs (us-east-1 list prices, illustrative)

Where the money is

Measure and fix

  1. List groups: aws logs describe-log-groups --query 'logGroups[].[logGroupName,storedBytes,retentionInDays,creationTime]' --output text. No retentionInDays means never expires.
  2. Ingested GB per group: the IncomingBytes metric (namespace AWS/Logs) summed over 30 days, divided by 1e9.
  3. Paste rows into the advisor or run node cli.mjs analyze groups.csv. It prints a put-retention-policy command per group worth changing.
  4. Export anything you must keep to S3 first. A retention policy deletes older events, and that cannot be undone.

Questions

Why is my CloudWatch Logs bill so high?

Usually ingestion. Standard class ingestion is $0.50 per GB, billed once when data arrives, while archived storage is $0.03 per GB-month. A group ingesting 2,400 GB a month costs about $1,200 in ingestion and under $30 a month to keep a month of it.

Does shortening retention cut the bill?

Only the storage line, which is small unless a group has never expired for years. Set a retention policy on every group, but the large saving is almost always logging less: lower log levels, no health-check lines, no request or response bodies.

What is the Infrequent Access log class?

A class priced at $0.25 per GB ingested, half of Standard. It lacks metric filters, subscription filters, Live Tail and export, and the class can only be chosen when the log group is created.