Anomaly Detection
This is an optional add-on to the manual AWS Console setup — complete that guide first. It provisions an AWS-managed Cost Anomaly Detection monitor on the management account, so Infracost can surface AWS-detected cost anomalies alongside your cost data.
Check for an existing monitor first
AWS allows only one managed SERVICE-dimension, DIMENSIONAL-type Cost Anomaly Detection monitor per account — many accounts already have one (for example, a Default-Services-Monitor created via the Cost Explorer console).
- Open Billing and Cost Management > Cost Anomaly Detection.
- On the Cost monitors tab, look for a monitor with Monitor type: Dimensional and Monitor dimension: Service.
If one already exists, leave it in place — do not create a second one, it will fail. No further action is needed: Infracost discovers and reads it automatically via the ce:Describe*/ce:Get*/ce:List* permissions already granted in the core setup guide.
If you are managing a custom cross-account role instead of following the core setup guide exactly, ensure it has the ce:GetAnomalyMonitors and ce:GetAnomalies permissions.
Step 1: Create the monitor
If no such monitor exists yet:
- Open Billing and Cost Management > Cost Anomaly Detection, go to the Cost monitors tab, and click Create monitor.
- Monitor name:
InfracostServicesMonitor. - Monitor method: Managed by AWS.
- Dimension: AWS services.
- Click Next.
- AWS requires at least one alert subscription to finish creating the monitor — it isn't skippable. Infracost doesn't use it (it reads anomalies directly via the cross-account role), so keep this minimal:
- Alert subscription: Create a new subscription.
- Subscription name: anything, for example
infracost-unused. - Alerting frequency: Weekly summaries.
- Alert recipients: your own email address.
- Threshold: set a high value so it rarely fires.
- Click Create monitor.
Removing
Delete the monitor from Billing and Cost Management > Cost Anomaly Detection, on the Cost monitors tab — only do this if you created it for Infracost and nothing else in your account depends on it. If you used a pre-existing monitor, leave it in place.
Troubleshooting
Creating the monitor fails with "a monitor of this type already exists"
See Check for an existing monitor first above — leave the existing monitor in place instead of creating a new one.