Work with quotas

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

"Work with Google Cloud quota systems, Google Cloud"

Google Cloud uses quotas to restrict how much of a particular shared Google Cloud resource that you can use. Each quota represents a specific countable resource. For example: API calls to a particular service, the number of load balancers used concurrently by your project, or the number of projects that you can create.

This page describes how to work with quotas in your projects. This includes how to find and modify your existing quota limits, how to request higher quotas, and how to monitor quota usage.

Many services also have limits that are unrelated to the quota system. Limits are fixed constraints, such as maximum file sizes or database schema limitations, which cannot be increased or decreased. You can find out about limits on the relevant Quotas and limits page for your service (for example, Cloud Storage quotas and limits).

The following links provide additional information related to resource usage:

Try it for yourself

If you're new to Google Cloud, create an account to evaluate how our products perform in real-world scenarios. New customers also get $300 in free credits to run, test, and deploy workloads.

Get started for free

About quotas

Before learning about how to monitor and manage your quota, it's useful to understand the basics of how the Google Cloud quota system works. This section introduces you to some key quota concepts: quota types, quota limits, and quota increase requests.

Why do we enforce quotas?

Quotas are enforced for many reasons, including:

  • To protect the community of Google Cloud users by preventing unforeseen spikes in usage and overloaded services.
  • To help you manage resources. For example, you can set your own limits on service usage while developing and testing your applications to avoid unexpected bills from using expensive resources.

Types of quota

There are three categories of Google Cloud quotas:

  • Rate quotas are typically used for limiting the number of requests that you can make to an API or service. Rate quotas reset after a time interval that is specific to the service—for example, the number of API requests per day.
  • Allocation quotas are used to restrict the use of resources that don't have a rate of usage. For example, the number of VMs used by your project at a given time. Allocation quotas don't reset over time. Instead, they must be explicitly released when you no longer want to use them—for example, by deleting a GKE cluster.
  • Concurrent quotas are used to restrict the total number of concurrent operations in flight at any given time. These are usually long-running operations. For example, Compute Engine uses insert_operations that are expected to last as long as one hour.

Within these categories, some quotas are global and apply to your usage of the resource anywhere in Google Cloud. Others are regional or zonal and apply to your usage of the resource in a specific Google Cloud region (both quota types) or zone (allocation quotas only). For example, there are separate limits for how many Compute Engine VM instances that you can create in each Google Cloud region.

Quotas are enforced on a per-project basis. Except for the number of projects that you can create, which is enforced per user account and billing account.

View quota information

There are several ways to view and manage your Google Cloud quota:

You can see details of how to use these approaches in the rest of this document. Each product or service also has its own quotas and limits page with specific information about the quotas of that service. For example, the GKE Quotas and limits page.

Understand quota limits

The set of quota limits that apply to your applications are specific to you, your project, or your organization. For example, if you're using a free trial account, you might have very low quota for some resources compared to a billed account. Enabling billing for your project increases quotas for most services. Quotas can also increase as your use of Google Cloud expands over time.

If your project needs more of a particular resource than your quotas allow, you can request more quota for a specific service. You can find out more about how quota increase requests work in About quota increase requests. If you want to impose spending limits, you can add your own limits for certain quotas. Use this tool when developing or testing applications that use expensive resources.

Some quotas are unlimited for particular users. In this case, you can use as much of that resource as you want.

Finally, a few quotas cannot be increased from their default values. For example, where higher usage is counterproductive or where resources are very limited. These limitations are typically documented in the relevant Quotas and limits page for that service, as in this example from Cloud Functions.

When you run out of quota

Usually, if you run out of quota the task that you're trying to perform fails and you get a quota error. Tasks that throw this error might include deploying an application, creating a new project, or calling an API. Subsequently, the task continues to fail until you free up resources (for allocation quota), the time period resets (for rate quota), or you're granted a quota increase.

How the quota error appears depends on the tool or client that you use to interact with Google Cloud. You can see details of quota errors in Quota errors.

You can avoid getting quota errors by setting up monitoring to alert you when you are nearing quota limits. You can find out more about monitoring your quotas in Monitoring and alerting on quota metrics, later in this document.

About quota increase requests

Most quota increase requests are evaluated by automated systems. Their decision is based on strict criteria, including the availability of resources, the length of time you've used Google Cloud, and other factors. Requests that don't meet specific criteria are denied. Evaluation criteria for automated reviews is not disclosed to ensure fairness for all customers and prevent attempts to manipulate the process. Sometimes, quota increase requests are escalated to human reviewers, who also follow strict criteria but can consider your unique circumstances.

You might be asked to pay in advance for some quota increases. For example, you might be asked to make a payment if you request more projects that will use paid cloud services. The payment can be applied to any charges you incur in the future and will be visible as a credit in your account.

To learn how to request more quota, see Requesting a higher quota limit. You don't need to have a paid Customer Care service to request a quota increase. Quota increase requests are typically completed within 2-3 business days. You're sent an email when your request is received, which you can be responded to. Use this feature if you have questions or want to provide additional information about your request (for example, if your increase request is urgent). You then get another email after the request is processed, notifying you whether the quota increase was approved or denied. The email provides the effective date of the increase, if applicable.

Permissions

Permissions for viewing project quota

To view your project quota in the Google Cloud console or to access your project quota programmatically, you must have the following Identity and Access Management (IAM) permissions:

To learn which roles include these permissions by default, see the IAM permissions reference.

Permissions for changing project quota

To change your quota at the project, folder, or organization level, you must have the following permission:

This permission is included by default for the following roles: Owner, Editor, Quota Administrator, and Service Usage Admin.

Permissions for viewing quota increase requests

To view quota increase requests in the Google Cloud console, you must have the following IAM permissions:

Permissions for creating an alert policy for a quota

To create an alert policy for a quota, you must have the following permission:

  • monitoring.alertPolicies.create

View your quota in the Google Cloud console

You can view your current quota limits in two different areas of the Google Cloud console:

  • The Quotas page, which lists all quota usage and limits for your project
  • The Google Cloud console API dashboard, which lists quota information for a particular API, including resource usage over time

View the quotas for your project

To view quota usage and limits for all resources in your project, follow these steps:

  1. In the Google Cloud console, go to the Quotas page.

    Go to Quotas
    The remaining steps will appear automatically in the Google Cloud console.

  2. To focus on the information that you need, you can filter and sort the list as follows:

    • To filter the list, enter the desired properties and values in the Filter field. For example, to view the BigQuery API quotas, select Service, and then select BigQuery API.
    • To sort the list, click the heading of the column you want to sort by. For example, to sort alphabetically by the quota name, click the Quota column heading.

      By default, the list is sorted to show your most used quotas first, which helps you see limits that are at risk of being exceeded.

The Quotas page displays a table with configurable columns. The Service and Quota columns provide general information about which quota is being described. For example, the Service might be Cloud Logging API and the Quota might be Log ingestion requests per minute. The Quota field also describes how the quota is evaluated. Rate quotas are evaluated per minute, per 100 seconds, or per day. Quotas without any of these statements are allocation quotas.

You can find additional information about the quota by using the Metric, Limit name, and Monitored resource columns. These columns provide the detailed information needed to chart a quota.

For information about your quota usage, view the Current usage and 7 day peak usage columns. The values shown in these fields are calculated as follows:

  • For per-minute rate quotas:

    • The Current usage is the total usage in the past 10 minutes.
    • The 7 day peak usage is the average peak usage, as averaged over 1-hour intervals, for the previous 7 days.
  • For per-100-second rate quotas:

    • The Current usage is the total usage in the past 10 minutes.
    • The 7 day peak usage is the peak of the total usage, as computed over 1-hour intervals, for the previous 7 days.
  • For per-day rate quotas:

    • The Current usage is the total usage so far in the current 24-hour period for day-rate quotas.
    • The 7 day peak usage is the peak of the total usage, as averaged over 1-day intervals, for the previous 7 days.
  • For allocation quotas:

    • The Current usage is the most recent value. For example, this number might show the number of load balancers currently in use by your project.
    • The 7 day peak usage is an estimate of the maximum usage. The estimate is computed by splitting the data from the previous 7 days into 1 hour intervals, selecting the data point from each interval with the latest timestamp, and then selecting the maximum of that set. Due to how the peak usage is estimated, the value of the field might underestimate the actual peak usage.
  • For concurrent quotas:

    • The Current usage is the most recent value. For example, this number might show the number of in flight insert_operations for a given service.
    • The 7 day peak usage is an estimate of the maximum usage. The estimate is computed by splitting the data from the previous 7 days into 1 hour intervals, selecting the data point from each interval with the latest timestamp, and then selecting the maximum of that set. Due to how the peak usage is estimated, the value of the field might underestimate the actual peak usage.

You can learn more about quotas for a specific service by reading the documentation for that service. For example, Compute Engine quota is documented in Resource quotas.

View API-specific quota

To view detailed quota information for a particular API, including usage over time, visit the quota page for the API in the Google Cloud console. Depending on the API, these limits can include requests per day, requests per minute, and requests per minute per user. Some APIs set very low limits until you enable billing on your project.

You can view the current limits for a particular API in two different areas of the Google Cloud console:

View the number of projects that you can create

Each user account (including service accounts) and billing account has a limit to the number of projects that they can create. If you have fewer than 30 projects remaining in your quota, a notification displays the number of projects remaining in your quota on the New Project page. You can find out more about managing this quota in Managing project quotas and Project quota requests.

Manage your quota using the Google Cloud console

Depending on your resource usage, you might want to adjust the quota limits if your project up or down. This section describes how to change your provided quota limits. To see your quota limits, in the Details column, click All Quotas.

Filter quotas

To filter the list of quotas by specific properties:

  1. Go to the Quotas page in the Google Cloud console:

    Go to Quotas

  2. Click Filter to query your quota by a specific property.

Request a higher quota limit

To request a higher quota limit by using the Google Cloud console:

  1. Go to the Quotas page:

    Go to Quotas
    The remaining steps will appear automatically in the Google Cloud console.

  2. On the Quotas page, find the quota you want to increase in the Quota column.

    You can use the Filter search box to search for your quota.

  3. Select the checkbox to the left of your quota.

  4. Click EDIT QUOTAS. The Quota changes form displays.

  5. In the Quota changes form, enter the increased quota that you want for your project in the New limit field.

  6. Complete any additional fields in the form, and then click DONE.

  7. Click SUBMIT REQUEST.

While the previous procedure applies to most quota increase requests, you might encounter one of the following exceptions:

  • In the case where there is an existing usage cap, the usage cap must be removed before the quota can be increased. You will be presented with a disclosure and agreement. The disclosure states that the usage cap will be deleted and the limit will be updated to the default limit immediately. Your quota increase request will then be processed by Google Cloud normally.
  • Sometimes, the Google Cloud console redirects you to a separate form to request an increased limit. After you submit the form, Google Cloud acknowledges your request by email.
  • Some quotas cannot be updated using the Google Cloud console. If you find that you cannot change a quota from the console, request the increase from Cloud Customer Care. The Billing team does not handle quota limit increases.

If your quota increase request requires approval, you can expect to receive an email from Google Cloud acknowledging receipt of your request. If you need further assistance, you can respond to the email . Cloud Customer Care typically processes your request within 2-3 business days. Cloud Customer Care then sends you a second email notifying you whether the quota increase was approved or denied. The email provides the effective date of the increase, if applicable.

To find out more about how the quota increase process works, see About quota increase requests.

View quota increase requests

You can see currently pending and past quota increase requests in the Google Cloud console.

To see pending quota increase requests:

  1. Ensure that you have permission to view quota increase requests.

  2. Go to the Quotas page:

    Go to Quotas

  3. On the Quotas page, Pending is shown next to the quota limits that are currently pending a decision on previously submitted increase requests. You can click Pending to view details of the pending requests.

Pending requests are also shown in the Quota changes form when a new quota increase request is about to be submitted.

To view all quota increase requests (currently pending and past requests):

  1. Go to the Quotas page:

    Go to Quotas

  2. Click the Increase Requests tab

  3. Click Filter to query your quota increase requests by a specific property.

When an organization or folder is selected, the page shows all quota increase requests for all projects within the organization or folder.

Cap usage

You might want to limit usage of a particular resource by setting your own quota limits. For example, to prevent getting billed for usage beyond the free courtesy usage limits, you can request per-day caps.

To cap a quota, follow the same steps as for requesting a higher quota limit.

Capping usage with quotas does not apply to all services. Check the specific quota page for your service for more information.

Manage your quota using the Google Cloud CLI (alpha)

You can use the Google Cloud CLI to get current quotas and limit usage for some Google Cloud APIs and services. Including project-, folder-, and organization-level quotas where available.

To use this approach, first ensure that you have installed and initialized the latest version of the Google Cloud CLI, including the alpha commands component. If you're using Cloud Shell to interact with Google Cloud, the Google Cloud CLI is installed for you.

To view a quota for a particular service, run the following command, substituting your project ID and service name:

gcloud alpha services quota list \
    --service=SERVICE_NAME.googleapis.com \
    --consumer=projects/PROJECT_ID

To view the same service's quota details for an organization:

gcloud alpha services quota list \
    --service=SERVICE_NAME.googleapis.com \
    --consumer=organizations/ORG_ID

For a complete list of gcloud quota commands and flags, see the Google Cloud CLI reference.

In addition to gcloud quota, some services have their own command-line access to quota and resource usage information. For example, Compute Engine lets you access quota information with gcloud compute.

Manage your quota using the Service Usage API

You can use the Service Usage APIs to get current quotas and limit the quota usage for some Google Cloud APIs and services. For more information about Service Usage, see the following:

You cannot use the Service Usage API to request a higher quota. For this activity, you must use the Google Cloud console.

Monitor and alert on quota metrics

Set up quota usage alerts in the Quotas page

You can set up quota alerts from the Quotas page to get notifications when quota usage reaches a defined threshold. This feature currently only supported for project-level quotas.

To set up an alert for a specific quota, do the following:

  1. Ensure you have the permission to create alerts

  2. Go to the Quotas page: Go to Quotas

  3. On the Quotas page, on the last column of the table, click the button to open the actions menu, and click Create quota alert.

  4. Select the quota usage template and select the desired notification channels.

  5. Click Create policies

  6. Optional: If you would like to customize the default alert policy, expand the drop-down, and follow the directions.

Use Cloud Monitoring

The Cloud Monitoring API and console allows you to monitor quota usage, limits, and errors in greater depth. You can use these metrics to create custom dashboards and alerts.You can monitor quota usage over time and receive alerts. For example, when you're approaching a quota limit.

Cloud Monitoring supports a wide variety of metrics that you can combine with filters and aggregations for new and insightful views into your quota usage. For example, you can combine a metric for allocation quota usage with a quota_metric filter on Cloud TPU names.

To use Metrics Explorer to view the metrics for a monitored resource, follow these steps:

  1. In the Google Cloud console, go to the Metrics Explorer page within Monitoring.
  2. Go to Metrics Explorer

  3. Select the Configuration tab.
  4. Expand the Select a metric menu, enter quota usage in the filter bar, and then use the submenus to select a specific resource type and metric:
    1. In the Active resources menu, select Consumer Quota.
    2. In the Active metric categories menu, select Quota.
    3. In the Active metrics menu, select Allocation quota usage or Rate quota usage.
    4. Click Apply.
  5. Optional: To configure how the data is viewed, add filters and use the Group By, Aggregator, and chart-type menus. For example, you can group by resource or metric labels. For more information, see Select metrics when using Metrics Explorer.
  6. Optional: Change the graph settings:
    • For quota and other metrics that report one sample per day, set the time frame to at least one week and set the plot type to Stacked bar chart.
    • For distribution valued metrics, set the plot type to Heatmap chart.

Similarly, to see quota limits or exceeded errors, first select Consumer Quota as the resource type and then select Quota limit or Quota exceeded error.

After you've found the quota usage information you want, you can use Cloud Monitoring to create custom dashboards and alerts to help you monitor and maintain a robust application. For more information, see the following documents:

For examples of common quota-specific alerting policies, see Using quota metrics.

The Cloud Monitoring reference guide includes a detailed reference for quota metrics.

Check quota metric support

Not all services support quota metrics in Cloud Monitoring. To see applicable quota metrics for supported services, select Consumer Quota as the resource type when building a chart or creating an alerting policy. Services that don't support quota metrics aren't displayed.

  • Common services that support quota metrics include Compute Engine, Dataflow, Cloud Spanner, Pub/Sub, Cloud Vision, Speech-to-Text, Cloud Monitoring, and Cloud Logging.

  • Common services that do not support quota metrics include App Engine, Cloud Storage, and Cloud SQL.

Quota errors

If your project exceeds a quota while using a service, Google Cloud returns an error based on how you accessed the service:

  • If you exceeded a quota with an HTTP/REST request, Google Cloud returns an HTTP 429 TOO MANY REQUESTS status code.
  • If you exceed a quota with an API request, Google Cloud returns an HTTP 413 REQUEST ENTITY TOO LARGE status code.
  • If you exceeded a quota using gRPC, Google Cloud returns a ResourceExhausted error. How this error appears to you depends on the service.
  • If you exceeded a quota using a Google Cloud CLI command, the gcloud CLI outputs a quota-exceeded error message and returns with the exit code 1.

Rate quotas reset after a predefined time interval that is specific to each service. For more information, see the quotas documentation for the specific service.

If you want to be alerted when errors happen in future, you can create custom alerts for specific quota errors, as described in Monitoring quota metrics.