Calculate savings with Compute Engine flexible commitments

Stay organized with collections Save and categorize content based on your preferences.

Compute Engine flexible committed use discounts (flexible CUDs) are the discounts you receive when you purchase a spend-based commitment for Compute Engine and commit to a certain level of hourly spend for a 1-year or 3-year term. With flexible CUDs, you have the flexibility to use Compute Engine resources without being restricted to one machine type or region.

You can access the the dashboard or analysis report for a summary of your commitment spending. If you want to learn more about analyzing commitments for services other than Compute Engine, see Analyzing the effectiveness of spend-based commitments.

Refer to the guides on this page to learn about the following tasks:

Review Compute Engine flexible commitments in your analysis report

You can view a summary of all the committed use discounts you've purchased for your Cloud Billing account in the dashboard and analysis report. After you access your analysis report, you can review a detailed analysis of your committed use discounts. The analysis page shows the details of your Compute Engine flexible committed use discounts for the period specified in the filter, including summary cards, a stacked bar chart, and a summary table of the commitment's totals.

Example
of a committed use discount analysis report and bar chart that shows flexible
committments in the filter bar as well as the summary cards, stacked bar chart,
and summary table.

You can purchase commitments from the committed use discount analysis page. To purchase a new commitment while viewing the analysis page select Purchase.

You can view and purchase committed use discount recommendations for the commitment by selecting Recommendations.

If you have a non-USD account, you use the analysis report to view savings, analysis chart details, commitment covered costs, and eligible costs not covered in your local currency. Active commitment can be viewed in both USD and your local currency.

Summary cards

The summary cards for the analysis appear above the stacked bar chart and show the following details for the selected commitment.

  • Active commitment - The current quantity of commitments you have purchased for the selected resource.
  • Savings - The savings from the commitments you have purchased for the specified period.
  • Utilization - The percentage of the commitments you have purchased that were utilized during the specified period.
  • Coverage - The percentage of your eligible usage for the specified period that is covered by the commitments you have purchased.

Stacked bar chart

The stacked bar chart appears below the summary cards and above the summary table, and shows the following details for the selected commitment.

  • Recommended commitment - Estimated savings if you purchase the additional committed use discounts suggested by the commitment recommender.
  • Compute Engine flexible committed use discounts on-demand rates - Your pre-purchased commitment quantity (dashed line).
  • Compute Engine flexible committed use discounts covered costs - Average hourly cost of usage covered by committed use discount credits (middle part of the bar, green-colored).
  • Compute Engine resource-based commitments - Average hourly cost of usage covered by committed use discount credits (lower part of the bar, blue-colored).
  • Eligible cost not covered - Average hourly cost of usage charged at the standard, non-discounted, usage rate (top section of the bar, gray-colored).

To understand the monthly cost of your active commitment, see the Commitment cost on the Cost Breakdown report.

To view details for an individual day, hover your pointer over the bar for that day.

Summary table

The summary table appears below the stacked bar chart, at the bottom of the analysis page, displaying aggregate quantities and hourly averages for the time range being shown.

Understand your bill

Google Cloud uses a balance sheet format for your bill:

  1. You are billed a commitment fee, which is the discounted cost of your covered usage. You are billed this fee on a recurring basis, regardless of your usage.
  2. You are billed for the standard on-demand costs for resources that you consume.
  3. You receive committed use discount credits that appear in your bill as negative costs. These offset the portion of your eligible on-demand charges covered by the commitment.

The net impact of these three components is that you receive a discount on the usage covered by your commitment. The sum of your commitment fee (1) and committed use discount credits (3) equals the savings from your committed use discounts.

Example of usage equaling commitment

This example shows a Cloud Billing account where the spend-based committed use discount equals the usage for the one-hour period.

You purchase a one-year commitment for $50/hour of on-demand spend on Compute Engine flexible committed use discount eligible SKUs. This one-year commitment gives you a 28% discount on covered usage, resulting in your net cost being $36/hour.

  1. You are charged a $36 commitment fee.
  2. You are charged $50 of on-demand costs for the one hour.
  3. You receive $50 in credit that offsets your $50 of on-demand costs.

Total costs = $36 + $50 - $50 = $36

In this example, your Compute Engine flexible committed use discount covers all of your usage and there is no overage. Your final cost for the hour is $36 with the flexible committed use discount. Without the discount, the total cost for the hour would have been $50.

Example of using more than commitment

This example shows a Cloud Billing account where the actual usage is more than the spend-based committed use discounts purchased. This results in an overage, where you pay the on-demand rate for the amount beyond your commitment.

You purchase a one-year commitment for $40/hour of on-demand spend on Compute Engine flexible committed use discount eligible SKUs. This one-year commitment gives you a 28% discount on covered usage, resulting in your net cost being $28.80/hour.

  1. You are charged a $28.80 commitment fee.
  2. You are charged $50 of on-demand costs for the one hour.
  3. You receive $40 in credit that offsets your $40 of on-demand costs.

Total costs = $28.80 + $50 - $40 = $38.80

In this example, your flexible committed use discount covers some of your usage. You paid $10 in overage at the on-demand rates and received a 28% discount on the $40 of on-demand equivalent costs covered by your commitment. Your final cost for the hour is $38.80 with the committed use discount. Without the discount, the total cost for the hour would have been $50.

Example of using less than commitment

This example shows a Cloud Billing account where the actual usage is less than the spend-based committed use discounts purchased. This results in an unused portion of the commitment.

You purchase a one-year commitment for $60/hour of on-demand spend on Compute Engine flexible committed use discount eligible SKUs. This one-year commitment gives you a 28% discount on covered usage, resulting in your net cost being $43.20/hour.

  1. You are charged a $43.20 commitment fee.
  2. You are charged $50 of on-demand costs for the one hour.
  3. You receive $50 in credit that offsets your $50 of on-demand costs.

Total costs = $43.20 + $50 - $50 = $43.20

In this example, your committed use discount covers all of your usage and there was no overage. However, you committed to $60 of on-demand equivalent spend and only spent $50, failing to use the last $10 of credit paid for. Your final cost for the hour is $43.20 with the committed use discount. Without the discount, the total cost for the hour would have been $50.

Understand your invoice or statement

You can view all three components of the spend-based committed use discount on your invoice or statement.

  • Commitment fee - The SKU description begins with Commitment - dollar based. For example, the commitment fee for a Compute Engine flexible committed use discount for a 1-year term would appear as Commitment - dollar based v1: for 1 year. The commitment fee for a flexible committed use discount for a 3-year term would appear as Commitment - dollar based v1: for 3 years.
  • On-demand costs - Charges for your usage at the on-demand equivalent cost. For example, N1 CORE running in Americas.
  • Credits - These offset the portion of your on-demand equivalent costs that are covered by your committed use discount.

Use the cost table report to view and download the cost details of your invoice or statement.

Access the documents page to find a Cloud Billing document such as an invoice or statement.

Access the transactions page to view your transaction history.

Understand your Cloud Billing reports

Cloud Billing reports let you view your Google Cloud usage costs and credits to discover and analyze trends. The Cloud Billing reports provide a variety of user-configurable options to view the costs that are important to you, including options to view your credits.

To view the individual components that comprise your committed use discounts, group your costs by SKU. The default report view (not grouped by SKU) does not break out the CUD components but instead includes the net of the three components.

To view only your ongoing commitment fees, limit the report results to the relevant commitment fee SKUs using the SKUs filter. For example, select the SKUs filter and type Commitment [YOUR COMMITMENT TYPE].

To understand how your commitment fees and credits are applied to your Cloud Billing account and projects, see Attribution of committed use discount fees and credits.

View your flexible CUDs in your Cloud Billing BigQuery export

You can use Cloud Billing export to BigQuery to export detailed Google Cloud billing data.

Use the following query to view your Commitment fees in your BigQuery export.

Standard SQL

SELECT
    invoice.month AS invoice_month,
    SUM(cost) as commitment_fees
FROM PROJECT.DATASET.TABLE
WHERE sku.description LIKE "%GCE for 1 year%"
OR sku.description LIKE "%GCE for 3 year%"
GROUP BY 1
;

To view your committed use Credits, use the following sample query:

Standard SQL

SELECT
    invoice.month AS invoice_month,
    SUM(credits.amount) as CUD_credits,
FROM PROJECT.DATASET.TABLE
LEFT JOIN UNNEST(credits) AS credits
WHERE credits.full_name LIKE 'Committed use discount - dollar based: GCE Commitments%'

GROUP BY 1 ;

To view both your credits drawn down by all-usage SKUs and commitment fees, use the following sample query:

Standard SQL

SELECT * FROM project.dataset.gcp_billing_export_v1_XXXXXX_XXXXXX_XXXXXX
LEFT JOIN UNNEST(credits) AS credits
WHERE credits.full_name LIKE 'Committed use discount - dollar based: GCE Commitments%'
OR sku.description LIKE "%GCE for 1 year%"
OR sku.description LIKE "%GCE for 3 year%"`
;

Calculate your overall flexible CUDs savings

The total effective savings from flexible CUDs vary depending on the resources used in a given month and the on-demand pricing of those resources. Because flexible CUDs savings are dependent on underlying SKUs, you could see discount rates that differ from advertised list discounts. It's important to calculate your total effective flexible CUDs savings so you can understand the effectiveness of your overall discount.

To calculate your total effective flexible CUDs savings, you use the following components:

  • On-Demand Rate - The percentage rate you pay for on-demand VM usage. This is usually 1 (for 100%), but it could be lower if other on-demand VM savings are in effect in your account.
  • Flexible CUDs SKU Price - The customized price you pay for your flexible CUDs, available in the Pricing page in the Google Cloud console. The SKU description begins with Commitment - dollar based. A commitment fee for a 1-year commitment will appear as Commitment - dollar based v1:Compute Engine for 1 year. A commitment fee for a 3-year flexible commitment will appear as Commitment - dollar based v1: Compute Engine for 3 years.
  • Flexible CUDs Discount Percentage - The incremental savings that flexible CUDs provide over standard on-demand VM usage. This is usually 28% for 1-year commitments and 46% for 3-year commitments, but may vary based on other savings in effect on your account. Your Google Cloud account team might provide this to you, or you can use your customized flexible CUDs SKU Price to calculate it.
  • Total Effective Flexible CUDs Savings - Your effective savings with flexible CUDs with your On-Demand Rate.

If you know your incremental flexible CUDs discount, input that value into this equation:

Total Effective Flexible CUDs Savings = 1 - (On-Demand Rate - (On-Demand Rate * Flexible CUDs Discount Percentage))

The result varies between 1-year commitments and 3-year commitments, and may vary for different on-demand VMs based on your on-demand rate.

If you don't know this incremental flexible CUD percentage, you can calculate it by using the Flexible CUDs SKU Price in the Pricing page in the Google Cloud console:

Flexible CUDs Discount Percentage = 100 - (Flexible CUDs SKU Price * 100)

Note that your Flexible CUDs Discount Percentage might be lower than the standard 28% for 1-year commitments and 46% for 3-year commitments if you have other savings in effect for on-demand VMs.

For information about viewing and managing your purchased commitments, see: + View and download the cost details of your invoice or statement + Get a Cloud Billing document such as an invoice, statement, or receipt + View your cost and payment history

Example of calculating flexible CUDs total savings

This example shows how to calculate your total savings from a 3-year flexible commitment.

In this example, you have a Flexible CUDs SKU Price of $0.0054 and an On-Demand Rate of 100%. To understand the Total Effective Flexible CUDs Savings, multiply your Flexible CUDs SKU Price of $0.0054 by 100 for a product of 0.54. Then, subtract 0.54 from 1 to determine your Flexible CUDs Discount Percentage, which is 0.46 or 46% in this example. Finally, input your On-Demand Rate and Flex CUDs Discount Percentage into the Total Effective Flexible CUDs Savings formula:

Total Effective Flexible CUDs Savings = 1 - (On-Demand Rate - (On-Demand Rate* Flexible CUDs Discount Percentage))

The entire calculation for this example is:

  1. Multiply your Flexible CUDs SKU Price of $0.0054 by 100 for a product of 0.54.
  2. Subtract 0.54 from 1 to determine your Flexible CUDs Discount Percentage as 0.46 or 46%.
  3. Input your On-Demand Rate into the formula to calculate Total Effective Flexible CUDs Savings.

    **Total Effective Flexible CUDs Savings** = 1 - (1 - (1 * .46))

Your Total Effective Flexible CUDs Savings are .46 or 46%.

Calculate your potential discount based on your current usage

After you set up your Cloud Billing export, you can analyze your past usage and calculate how that usage would have been discounted by flexible CUDs. The calculation is determined by the following parameters:

Variable/Field name

Description

LOOK_BACK_WINDOW The retrospective window for the analysis (such as 30 days, 90 days).
credits_from_existing_cuds Hourly credits received from active commitments already purchased.
credits_from_existing_suds Hourly credits received automatically from SUDs.
cost_eligible_for_additional_flex_cuds_considering_cud_credits Hourly eligible undiscounted usage, excluding CUDs credits only.
cost_eligible_for_additional_flex_cuds_considering_cud_and_sud_credits Hourly eligible undiscounted usage, excluding CUDs and SUDs credits.
min_cost_eligible_for_additional_flex_cuds_considering_cud_credits Minimum undiscounted usage, excluding CUDs credits only.
min_cost_eligible_for_additional_flex_cuds_considering_cud_and_sud_credits Minimum undiscounted usage, excluding CUDs and SUDs credits; the most conservative estimate based on the look_back_window.

Use the following query to understand how an hourly undiscounted portion of your usage that would be affected by a committed use discount.

– IMPORTANT:
– YOU MUST REPLACE  `PROJECT.DATASET.TABLE` -- BILLING_BQ_EXPORT_TABLE_NAME
– WITH THE BILLING BigQuery TABLE NAME IN THE QUERIES BELOW.
DECLARE LOOK_BACK_WINDOW INT64 DEFAULT 30;

-- Hourly data for the window.
WITH
 base AS (
 SELECT
   *,
 IF
   (total_cost >= credits_from_existing_cuds,
     (total_cost - credits_from_existing_cuds),
     0) AS cost_eligible_for_additional_flex_cuds_considering_cud_credits,
 IF
   (total_cost >= (credits_from_existing_cuds + credits_from_existing_suds),
     (total_cost - (credits_from_existing_cuds + credits_from_existing_suds)),
     0) AS cost_eligible_for_additional_flex_cuds_considering_cud_and_sud_credits
 FROM (
   SELECT
     usage_start_time,
     SUM(cost) AS total_cost,
     (SUM((
         SELECT
           SUM(c.amount)
         FROM
           UNNEST(credits) AS c
         WHERE
           c.type IN ( "COMMITTED_USAGE_DISCOUNT",
             "COMMITTED_USAGE_DISCOUNT_DOLLAR_BASE" ))) * -1) AS credits_from_existing_cuds,
     (SUM((
         SELECT
           SUM(c.amount)
         FROM
           UNNEST(credits) AS c
         WHERE
           c.type IN ( "SUSTAINED_USAGE_DISCOUNT" ))) * -1) AS credits_from_existing_suds,
   FROM
     `PROJECT.DATASET.TABLE` -- BILLING_BQ_EXPORT_TABLE_NAME
   WHERE
     1 = 1
     AND DATE(_PARTITIONTIME) >= DATE_ADD(CURRENT_DATE(), INTERVAL -LOOK_BACK_WINDOW DAY)
     AND usage_start_time >= TIMESTAMP(DATE_ADD(CURRENT_DATE(), INTERVAL -LOOK_BACK_WINDOW DAY))
     AND usage_start_time < TIMESTAMP(CURRENT_DATE())
     AND service.description = "Compute Engine"
     AND ( 1 = 0
       OR sku.description LIKE 'C2D AMD Instance Core running in%'
       OR sku.description LIKE 'C2D AMD Instance Ram running in%'
       OR sku.description LIKE 'C2D AMD Sole Tenancy Instance Core running in%'
       OR sku.description LIKE 'C2D AMD Sole Tenancy Instance RAM running in%'
       OR sku.description LIKE 'C2D AMD Sole Tenancy Instance Ram running in%'
       OR sku.description LIKE 'Compute optimized Core running in%'
       OR sku.description LIKE 'Compute optimized Instance Core running in%'
       OR sku.description LIKE 'Compute optimized Instance Ram running in%'
       OR sku.description LIKE 'Compute optimized Ram running in%'
       OR sku.description LIKE 'Compute-optimized Sole Tenancy Instance Core running in%'
       OR sku.description LIKE 'Compute-optimized Sole Tenancy Instance RAM running in%'
       OR sku.description LIKE 'Compute-optimized Sole Tenancy Instance Ram running in%'
       OR sku.description LIKE 'Custom E2 Instance Core running in%'
       OR sku.description LIKE 'Custom E2 Instance Ram running in%'
       OR sku.description LIKE 'Custom Extended Instance Ram running in%'
       OR sku.description LIKE 'Custom Instance Core running in%'
       OR sku.description LIKE 'Custom Instance Ram running in%'
       OR sku.description LIKE 'E2 Instance Core running in%'
       OR sku.description LIKE 'E2 Instance Ram running in%'
       OR sku.description LIKE 'N1 Predefined Instance Core running in%'
       OR sku.description LIKE 'N1 Predefined Instance Ram running in%'
       OR sku.description LIKE 'N2 Custom Extended Instance Ram running in%'
       OR sku.description LIKE 'N2 Custom Instance Core running in%'
       OR sku.description LIKE 'N2 Custom Instance Ram running in%'
       OR sku.description LIKE 'N2 Instance Core running in%'
       OR sku.description LIKE 'N2 Instance Ram running in%'
       OR sku.description LIKE 'N2 Sole Tenancy Instance Core running in%'
       OR sku.description LIKE 'N2 Sole Tenancy Instance RAM running in%'
       OR sku.description LIKE 'N2 Sole Tenancy Instance Ram running in%'
       OR sku.description LIKE 'N2D AMD Custom Extended Instance Ram running in%'
       OR sku.description LIKE 'N2D AMD Custom Extended Ram running in%'
       OR sku.description LIKE 'N2D AMD Custom Instance Core running in%'
       OR sku.description LIKE 'N2D AMD Custom Instance Ram running in%'
       OR sku.description LIKE 'N2D AMD Instance Core running in%'
       OR sku.description LIKE 'N2D AMD Instance Ram running in%'
       OR sku.description LIKE 'N2D AMD Sole Tenancy Instance Core running in%'
       OR sku.description LIKE 'N2D AMD Sole Tenancy Instance RAM running in%'
       OR sku.description LIKE 'N2D AMD Sole Tenancy Instance Ram running in%'
       OR sku.description LIKE 'Sole Tenancy Instance Core running in%'
       OR sku.description LIKE 'Sole Tenancy Instance RAM running in%'
       OR sku.description LIKE 'Sole Tenancy Instance Ram running in%' )
   GROUP BY
     usage_start_time ))
SELECT
 *
FROM
 base
ORDER BY
 usage_start_time DESC;


 -- Minimum flex eligible on demand spend in the window.
WITH
 base AS (
 SELECT
   *,
 IF
   (total_cost >= credits_from_existing_cuds,
     (total_cost - credits_from_existing_cuds),
     0) AS cost_eligible_for_additional_flex_cuds_considering_cud_credits,
 IF
   (total_cost >= (credits_from_existing_cuds + credits_from_existing_suds),
     (total_cost - (credits_from_existing_cuds + credits_from_existing_suds)),
     0) AS cost_eligible_for_additional_flex_cuds_considering_cud_and_sud_credits
 FROM (
   SELECT
     usage_start_time,
     SUM(cost) AS total_cost,
     (SUM((
         SELECT
           SUM(c.amount)
         FROM
           UNNEST(credits) AS c
         WHERE
           c.type IN ( "COMMITTED_USAGE_DISCOUNT",
             "COMMITTED_USAGE_DISCOUNT_DOLLAR_BASE" ))) * -1) AS credits_from_existing_cuds,
     (SUM((
         SELECT
           SUM(c.amount)
         FROM
           UNNEST(credits) AS c
         WHERE
           c.type IN ( "SUSTAINED_USAGE_DISCOUNT" ))) * -1) AS credits_from_existing_suds,
   FROM
     `PROJECT.DATASET.TABLE` -- BILLING_BQ_EXPORT_TABLE_NAME
   WHERE
     1 = 1
     AND DATE(_PARTITIONTIME) >= DATE_ADD(CURRENT_DATE(), INTERVAL -LOOK_BACK_WINDOW DAY)
     AND usage_start_time >= TIMESTAMP(DATE_ADD(CURRENT_DATE(), INTERVAL -LOOK_BACK_WINDOW DAY))
     AND usage_start_time < TIMESTAMP(CURRENT_DATE())
     AND service.description = "Compute Engine"
     AND ( 1 = 0
       OR sku.description LIKE 'C2D AMD Instance Core running in%'
       OR sku.description LIKE 'C2D AMD Instance Ram running in%'
       OR sku.description LIKE 'C2D AMD Sole Tenancy Instance Core running in%'
       OR sku.description LIKE 'C2D AMD Sole Tenancy Instance RAM running in%'
       OR sku.description LIKE 'C2D AMD Sole Tenancy Instance Ram running in%'
       OR sku.description LIKE 'Compute optimized Core running in%'
       OR sku.description LIKE 'Compute optimized Instance Core running in%'
       OR sku.description LIKE 'Compute optimized Instance Ram running in%'
       OR sku.description LIKE 'Compute optimized Ram running in%'
       OR sku.description LIKE 'Compute-optimized Sole Tenancy Instance Core running in%'
       OR sku.description LIKE 'Compute-optimized Sole Tenancy Instance RAM running in%'
       OR sku.description LIKE 'Compute-optimized Sole Tenancy Instance Ram running in%'
       OR sku.description LIKE 'Custom E2 Instance Core running in%'
       OR sku.description LIKE 'Custom E2 Instance Ram running in%'
       OR sku.description LIKE 'Custom Extended Instance Ram running in%'
       OR sku.description LIKE 'Custom Instance Core running in%'
       OR sku.description LIKE 'Custom Instance Ram running in%'
       OR sku.description LIKE 'E2 Instance Core running in%'
       OR sku.description LIKE 'E2 Instance Ram running in%'
       OR sku.description LIKE 'N1 Predefined Instance Core running in%'
       OR sku.description LIKE 'N1 Predefined Instance Ram running in%'
       OR sku.description LIKE 'N2 Custom Extended Instance Ram running in%'
       OR sku.description LIKE 'N2 Custom Instance Core running in%'
       OR sku.description LIKE 'N2 Custom Instance Ram running in%'
       OR sku.description LIKE 'N2 Instance Core running in%'
       OR sku.description LIKE 'N2 Instance Ram running in%'
       OR sku.description LIKE 'N2 Sole Tenancy Instance Core running in%'
       OR sku.description LIKE 'N2 Sole Tenancy Instance RAM running in%'
       OR sku.description LIKE 'N2 Sole Tenancy Instance Ram running in%'
       OR sku.description LIKE 'N2D AMD Custom Extended Instance Ram running in%'
       OR sku.description LIKE 'N2D AMD Custom Extended Ram running in%'
       OR sku.description LIKE 'N2D AMD Custom Instance Core running in%'
       OR sku.description LIKE 'N2D AMD Custom Instance Ram running in%'
       OR sku.description LIKE 'N2D AMD Instance Core running in%'
       OR sku.description LIKE 'N2D AMD Instance Ram running in%'
       OR sku.description LIKE 'N2D AMD Sole Tenancy Instance Core running in%'
       OR sku.description LIKE 'N2D AMD Sole Tenancy Instance RAM running in%'
       OR sku.description LIKE 'N2D AMD Sole Tenancy Instance Ram running in%'
       OR sku.description LIKE 'Sole Tenancy Instance Core running in%'
       OR sku.description LIKE 'Sole Tenancy Instance RAM running in%'
       OR sku.description LIKE 'Sole Tenancy Instance Ram running in%' )
   GROUP BY
     usage_start_time ))
 SELECT
   MIN (cost_eligible_for_additional_flex_cuds_considering_cud_credits) AS
   min_cost_eligible_for_additional_flex_cuds_considering_cud_credits,
    MIN (cost_eligible_for_additional_flex_cuds_considering_cud_and_sud_credits) AS
    min_cost_eligible_for_additional_flex_cuds_considering_cud_and_sud_credits FROM
   base;

Support

If you have questions regarding committed use discounts on your bill, contact Cloud Billing Support for help.