Anomaly detection helps you manage unexpected costs across your billing account's projects. These anomalies are spikes or deviations in usage costs that differ from your expected spend, when compared to historical spending patterns. Usage costs are calculated using the on-demand rates that are applicable to your billing account. On-demand rates include publicly available list prices and any contracted, negotiated, or discounted pricing that's available for your Cloud Billing account. Usage cost totals are gross costs that include spend-based CUD discounts, but exclude legacy spend-based CUD credits, resource-based CUD credits and other savings, such as promotional credits, and sustained use discounts.
The Anomalies dashboard displays all cost anomalies associated with your projects, within the linked billing account. You can use the Anomalies dashboard to do the following:
- Investigate the root causes of anomalies.
- Customize your view by setting thresholds for cost impact amount and percent of deviation.
- Manage automated alerts and notifications for detected anomalies.
- Provide feedback on detected anomalies to improve the tool's accuracy.
For reseller accounts and subaccounts, this feature is only available if you enable project-based cost visibility. Resellers can only view anomalies for their projects. To view anomalies for a subaccount, you must switch to the subaccount. To enable project-based cost visibility, contact Cloud Billing Support.
Permissions required for this task
You can view and manage anomalies for all projects on a Cloud Billing account or for individual projects. To manage anomalies for all projects on a Cloud Billing account, you need permissions on the billing account. To view anomalies for a specific project, you need billing-specific permissions on the project.
| Users with Cloud Billing account permissions | Users with project-level permissions only |
|---|---|
|
To gain the necessary permissions using a predefined role, ask your administrator to grant you one of the following predefined Cloud Billing IAM roles on your Cloud Billing account: To set up Pub/Sub notifications for anomalies, you need additional permissions. To gain the necessary permissions using a predefined role, ask your administrator to grant you the following role on the target project that contains the Pub/Sub topics: |
To gain the necessary permissions using predefined roles, ask your administrator to grant you one of the following predefined Cloud Billing IAM roles on the project: |
Access the Anomalies dashboard
To access the Anomalies dashboard, complete the following steps for your access level:
| Users with Cloud Billing account permissions | Users with project-level permissions only |
|---|---|
|
|
Analyze root causes of anomalies
Each anomaly includes a granular Root cause analysis panel that helps pinpoint the source of the cost spike. To open the panel and view the details of an anomaly, click the anomaly date.
The Root cause analysis panel shows the top services, regions, and SKUs that contributed to the spike in spend. If the anomaly is equally spread across services, regions, or SKUs, you won't see any top contributors in the Root cause analysis panel.
Click any of the links in the Root cause analysis panel to open a Billing Report that's filtered by the project you're viewing, and also by service, region, or SKU, depending on the link you select.
In the Root cause analysis panel, you can also share feedback about the anomaly to help optimize anomaly detection.
Manage anomalies
Billing Account Administrators can set threshold and notification preferences for all anomalies. On the Anomalies page, click Manage anomalies to customize thresholds and notifications.
Manage anomaly thresholds
A cost impact and deviation percentage threshold will automatically be set based on your usage patterns.
To focus on cost anomalies that are significant to you, you can configure a different cost impact and deviation percentage anomaly threshold. The threshold amount filters your view to show only anomalies exceeding a certain cost deviation (for example, $200) and deviation percentage (for example, 20%). If you set up notifications, you will also receive alerts when a cost anomaly crosses the defined threshold values.
The cost impact threshold value is in your billing account's local currency and can only contain positive numeric values, including up to two decimal places. You can't use negative or non-numeric values.
For users with billing-account-level access, the threshold amount automatically
sets a Cost impact and Deviation percentage filter on the
anomalies list, showing only anomalies that cross these thresholds. You
can remove both filters to see all anomalies, but the filter is
reapplied the next time you visit the page.
Users with project-level access can view these detected anomalies set by the Billing Account Administrator for their project. However, only users with the Billing Account Administrator (roles/billing.admin) role can update the notification thresholds.
Manage notifications
On the Manage anomalies page, you can set how you want to be notified about anomalies that go above your cost impact and percent of deviation threshold. You can configure email or Pub/Sub notifications.
By default, Cloud Billing admins will be notified by email for every individual anomaly. This can be changed in the Notifications section on the Manage Anomalies page.
You can change your notification settings at any time. Notification configurations apply to all projects on your billing account. You can't set up notifications for a subset of projects.
Set up email notifications
To set up email notifications, complete the following steps:
- From the Anomalies dashboard, click Manage anomalies.
- If you haven't already, enter an Anomaly threshold value for Cost impact and Deviation %. This amount is the threshold value that triggers notifications.
In the Email notifications section, set the email recipients (Billing admins, Essential contacts, or Project owners) and the frequency of emails for each recipient (every Individual anomaly or a Daily summary).
- For Essential contacts, selecting Individual anomaly sends notifications to the designated Essential Contacts, in the Billing category, for the project.
- For Essential contacts, selecting Daily summary sends notifications to the designated Essential Contacts, in the Billing category, for the organization.
- Project owners can receive notifications only for individual anomalies on projects that they own.
Click Save.
Set up Pub/Sub notifications
To set up Pub/Sub notifications for anomalies, complete the steps in Set up programmatic notifications.
For details about the JSON schema of Pub/Sub notifications for anomalies, see Notification format.
Optimize anomaly detection
The AI-powered anomaly detection algorithm constantly learns and improves, but your feedback helps it adapt faster to your business needs. To provide feedback, complete the following steps:
- In the list of anomalies, click the date of an anomaly to open its Root cause analysis panel.
- For Is this an anomaly?, select one of the following options:
- Yes, it's an unexpected cost increase: Select this option if the anomaly is unexpected and an unintended cost increase.
- Yes, but it's an expected cost increase: Select this option if the anomaly is an expected cost increase to meet your business needs. To help Google's anomaly detection models adapt, you can provide more context around the specific business reason for the anomaly (for example, if you have active migrations underway, are using new Google Cloud resources, or if the cost increase is temporary).
- No, the cost impact is insignificant: Select this option if the anomaly has a cost impact that you don't consider to be significant.
Click Submit feedback.
After you submit your feedback, it's recorded with a timestamp.
To change previously submitted feedback, complete the following steps:
- Open the Root cause analysis panel.
- Change your selection using the provided options.
- Click Submit feedback.
Related topics
- Set up programmatic notifications
- Analyze billing data and cost trends with Reports
- Create, edit, or delete budgets and budget alerts