English

Google App Engine

Quotas

An App Engine application can consume resources up to certain quotas. With these quotas, App Engine ensures that your application won't exceed your budget, and that other applications running on App Engine won't impact your application's performance.

Safety Limits and Billable Resource Limits

Safety quotas are set by Google to protect the integrity of the App Engine system. These quotas ensure that no single app can over-consume resources to the detriment of other apps. Billable resource quotas are set by the application administrator in the Billing Settings tab of the Administration Console. These quotas allow administrators to manage application performance and cost.

Safety Quotas

Safety quotas include daily quotas and per-minute quotas:

  • Daily quotas are refreshed daily at midnight Pacific time. Paid applications can exceed this free quota until their budget is exhausted.
  • Per-minute quotas protect the application from consuming all of its resources in very short periods of time, and prevent other applications from monopolizing a given resource. If your application consumes a resource too quickly and depletes one of the per-minute quotas, the word "Limited" appears next to the appropriate quota on the Quota Details screen in the Admin Console. Requests for resources that have hit their per-minute maximum will be denied. See When a Resource is Depleted for details.

Paid applications have higher daily and per-minute quotas than free applications. When a paid application exceeds this quota, it continues to use the resource until the budget is exhausted. You can see all the current quotas in the Resources section. These quotas are strictly for safety and represent an extreme that most applications will not encounter in normal usage.

Tip: For paid apps, the maximum per-minute quotas accommodate very high traffic levels, enough to handle a spike in traffic from your site getting mentioned in news stories. In extreme cases, you can request an increase in the maximums.

Billable Resource Quotas

Every application gets an amount of each billable resource for free, but application administrators can increase the billable quotas by enabling paid apps and setting a daily budget. You will be charged for the resources your application actually uses, and for the amount of resources used above the free quota thresholds. Paid applications incur a minimum spend of $2.10/week.

After you enable billing for your application, you can set your daily budget and adjust quotas using the Administration Console. For more information about setting your budget and allocating resources, see Billing. When you enable billing for your application, the application's safety quotas increase. See the Resources section for details.

How Resources are Replenished

App Engine tracks your application's resource usage against system quotas. For both free and paid applications, App Engine resets all resource measurements at the beginning of each calendar day (except for Stored Data, which always represents the amount of datastore storage in use). When free applications reach their quota for a resource, they cannot use that resource until the quota is replenished. Paid apps can exceed the free quota until their budget is exhausted.

Daily quotas are replenished daily at midnight Pacific time. Per-minute quotas are refreshed every 60 seconds.

When a Resource is Depleted

When an application consumes all of an allocated resource, the resource becomes unavailable until the quota is replenished. This may mean that your application will not work until the quota is replenished.

For resources that are required to initiate a request, when the resource is depleted, App Engine by default returns an HTTP 403 Forbidden status code for the request instead of calling a request handler. The following resources have this behavior:

  • Bandwidth, incoming and outgoing

Tip: You can configure your application to serve a custom error page when your application exceeds a quota. For details, see Custom Error Responses documentation for Python and Java.

For all other resources, when the resource is depleted, an attempt in the application to consume the resource results in an exception. This exception can be caught by the application and handled, such as by displaying a friendly error message to the user. In the Python API, this exception is apiproxy_errors.OverQuotaError. In the Java API, this exception is com.google.apphosting.api.ApiProxy.OverQuotaException.

The following example illustrates how to catch the OverQuotaError, which may be raised by the SendMessage() method if an email-related quota has been exceeded:

try:
  mail.SendMessage(to='test@example.com',
                   from='admin@example.com',
                   subject='Test Email',
                   body='Testing')
except apiproxy_errors.OverQuotaError, message:
  # Log the error.
  logging.error(message)
  # Display an informative message to the user.
  self.response.out.write('The email could not be sent. '
                          'Please try again later.')

If you're exceeding your system resource quota unexpectedly, consider profiling your application's performance.

Resources

An application may use the following resources, subject to quotas. Resources measured against billable resources are indicated with "(billable)." Resource amounts represent an allocation over a 24 hour period.

The cost of additional billable resources is listed on the Billing page.

Blobstore

Data stored in the blobstore counts toward the Stored Data (billable) quota, described above. The following quotas apply specifically to use of the blobstore.

Blobstore Stored Data
The total amount of data stored in the blobstore. Also counts toward the Stored Data (billable) quota. Available for both paid and free apps.
Resource Free Default Limit Billing Enabled Default Limit
Blobstore Stored Data 5 GB 5 GB free; no maximum

Channel

Channel API Calls
The total number of times the application accessed the Channel service.
Channels Created
The number of channels created by the application.
Channel Hours Requested
The number of hours of channel connect time requested by the application.
Channel Data Sent
The amount of data sent over the Channel service. This also counts toward the Outgoing Bandwidth quota.
Resource Free Default Limit Billing Enabled Default Limit
Daily Limit Maximum Rate Daily Limit Maximum Rate
Channel API Calls 657,000 calls 3,000 calls/minute 91,995,495 calls 32,000 calls/minute
Channels Created 100 channels 6 creations/minute Based on your budget 60 creations/minute
Channels Hours Requested 200 hours 12 hours requested/minute Based on your budget 120 hours requested/minute
Channel Data Sent Up to the Outgoing Bandwidth quota 22 MB/minute 2 GB 740 MB/minute
Outgrowing the maximums? Request an increase.

Conversion

Conversions
The quota for the conversion API is based on the number of conversions. Each application is limited to a number of conversions per API call, and a number of conversions per day:
Resource Free Default Limit Billing Enabled Default Limit
Daily Limit Maximum Rate Daily Limit Maximum Rate
Conversion API Calls 100 conversions 10 conversions/API call 100 conversions 10 conversions/API call

Datastore

The Stored Data (billable) quota refers to data stored for the application in the Master/Slave Datastore, the task queue and the Blobstore. The High Replication Storage (billable) quota refers to data stored for the application in the High Replication Datstore. Other quotas in the "Datastore" section of the Quota Details screen in the Administration Console refer to the Datastore service specifically.

Stored Data (billable)

The total amount of data stored in datastore entities and corresponding indexes, in the task queue, and in the Blobstore.

It's important to note that data stored in the datastore may incur significant overhead. This overhead depends on the number and types of associated properties, and includes space used by built-in and custom indexes. Each entity stored in the datastore requires the following metadata:

  • The entity key, including the kind, the ID or key name, and the keys of the entity's ancestors.
  • The name and value of each property. Since the datastore is schemaless, the name of each property must be stored with the property value for any given entity.
  • Any built-in and custom index rows that refer to this entity. Each row contains the entity kind, any number of property values depending on the index definition, and the entity key.

See How Entities and Indexes are Stored for a complete breakdown of the metadata required to store entities and indexes at the Bigtable level and How Index Building Works for a detailed explanation of how datastore indexes are managed.

Number of Indexes
The number of datastore indexes that exist for the application. This includes indexes that were created in the past and no longer appear in the application's configuration but have not been deleted using AppCfg's vacuum_indexes command.
Resource Free Default Limit Billing Enabled Default Limit
Stored Data (billable) 1 GB 1 GB free; no maximum
Number of Indexes 200 200
Outgrowing the maximums? Request an increase.

Deployments

Deployments
The number of times the application has been uploaded by a developer. The current quota is 1,000 per day.

An application is limited to 10,000 uploaded files per version. Each file is limited to a maximum size of 32 megabytes. Additionally, the total size of all files can not exceed 150 megabytes

Mail

Mail API Calls
The total number of times the application accessed the mail service to send an email message.
Recipients Emailed (billable)
The total number of recipients to whom the application has sent email messages. Note that the maximum quota for Recipients Emailed stays at free levels until the first charge for your application has cleared.
Admins Emailed
The total number of application admins to whom the application has sent email messages.
Message Body Data Sent
The amount of data sent in the body of email messages. This also counts toward the Outgoing Bandwidth quota.
Attachments Sent
The total number of attachments sent with email messages.
Attachment Data Sent
The amount of data sent as attachments to email messages. This also counts toward the Outgoing Bandwidth quota.
Resource Free Default Limit Billing Enabled Default Limit
Daily Limit Maximum Rate Daily Limit Maximum Rate
Mail API Calls 100 calls 32 calls/minute 1,700,000 calls 4,900 calls/minute
Recipients Emailed (billable) 100 recipients 8 recipients/minute 100 recipients until first charge cleared; 100 recipients free and no maximum thereafter 5,100 recipients/minute
Admins Emailed 5,000 mails 24 mails/minute 3,000,000 mails 9,700 mails/minute
Message Body Data Sent 60 MB 340 KB/minute 29 GB 84 MB/minute
Attachments Sent 2,000 attachments 8 attachments/minute 2,900,000 attachments 8,100 attachments/minute
Attachment Data Sent 100 MB 10 MB/minute 100 GB 300 MB/minute
Outgrowing the maximums? Request an increase.

Requests

Outgoing Bandwidth (billable)

The amount of data sent by the application in response to requests.

This includes:

  • data served in response to both secure requests and non-secure requests by application servers, static file servers, or the Blobstore
  • data sent in email messages
  • data sent over XMPP or the Channel API
  • data in outgoing HTTP requests sent by the URL fetch service.
Incoming Bandwidth (billable)

The amount of data received by the application from requests. Each incoming HTTP request can be no larger than 32MB.

This includes:

  • data received by the application in secure requests and non-secure requests
  • uploads to the Blobstore
  • data received in response to HTTP requests by the URL fetch service
Instance Hours (billable)
In general, instance usage is billed on an hourly basis based on the instance's uptime. Billing begins when the instance starts and ends fifteen minutes after the instance shuts down. You will be billed only for idle instances up to the number of maximum idle instances set in the Performance Settings tab of the Admin Console. Runtime overhead is counted against the instance memory.
Secure Outgoing Bandwidth
The amount of data sent by the application over a secure connection in response to requests. Secure outgoing bandwidth also counts toward the Outgoing Bandwidth quota.
Secure Incoming Bandwidth
The amount of data received by the application over a secure connection from requests. Secure incoming bandwidth also counts toward the Incoming Bandwidth quota.
Resource Free Default Limit Billing Enabled Default Limit
Daily Limit Maximum Rate Daily Limit Maximum Rate
Outgoing Bandwidth (billable, includes HTTPS) 1 GB 56 MB/minute 1 GB free; 14,400 GB maximum 10 GB/minute
Incoming Bandwidth (billable, includes HTTPS) 1 GB; 14,400 GB maximum 56 MB/minute none none
Outgrowing the maximums? Request an increase.

Task Queue

Task Queue API Calls
The total number of times the application accessed the task queue service to enqueue a task.
Task Queue Stored Task Count
The total number of tasks the application has enqueued that are not yet executed.
Task Queue Stored Task Bytes
The bytes consumed by tasks the application has enqueued that are not yet executed. This quota is counted as part of Stored Data (billable).

Tip: You can configure the Stored Task Bytes Limit by adjusting your queue configuration. See the Python or Java documentation for more details.

Resource Free Default Limit Billing Enabled Default Limit
Daily Limit Maximum Rate Daily Limit Maximum Rate
Task Queue API Calls 100,000 n/a 20,000,000 n/a
Outgrowing the maximums? Request an increase.
Resource Free Default Limit Billing Enabled Default Limit
Task Queue Stored Task Count 1,000,000 200,000,000
Task Queue Stored Task Bytes 500 MB. Configurable up to 1 GB. none MB. Configurable up to Stored Data (billable).
Outgrowing the maximums? Request an increase.

URL Fetch

URL Fetch API Calls
The total number of times the application accessed the URL fetch service to perform an HTTP or HTTPS request.
URL Fetch Data Sent
The amount of data sent to the URL fetch service in requests. This also counts toward the Outgoing Bandwidth quota.
URL Fetch Data Received
The amount of data received from the URL fetch service in responses. This also counts toward the Incoming Bandwidth quota.
Resource Free Default Limit Billing Enabled Default Limit
Daily Limit Maximum Rate Daily Limit Maximum Rate
UrlFetch API Calls 657,000 calls 3,000 calls/minute 46,000,000 calls 32,000 calls/minute
UrlFetch Data Sent up to the Outgoing Bandwidth quota 22 MB/minute up to the Outgoing Bandwidth quota 740 MB/minute
UrlFetch Data Received up to the Incoming Bandwidth quota 22 MB/minute up to the Incoming Bandwidth quota 740 MB/minute
Outgrowing the maximums? Request an increase.

XMPP

XMPP API Calls
The total number of times the application accessed the XMPP service.
XMPP Data Sent
The amount of data sent via the XMPP service. This also counts toward the Outgoing Bandwidth quota.
Recipients Messaged
The total number of recipients to whom the application has sent XMPP messages.
Invitations Sent
The total number of chat invitations sent by the application.
Stanzas Sent
XMPP stanzas sent when the application sends a message, invitation, or presence information.
Resource Free Default Limit Billing Enabled Default Limit
Daily Limit Maximum Rate Daily Limit Maximum Rate
XMPP API Calls 46,000,000 calls 257,280 calls/minute 46,000,000 calls 257,280 calls/minute
XMPP Data Sent 1 GB 5.81 GB/minute 1,046 GB 5.81 GB/minute
XMPP Recipients Messaged 46,000,000 recipients 257,280 recipients/minute 46,000,000 recipients 257,280 recipients/minute
XMPP Invitations Sent 100,000 invitations 2,000 invitations/minute 100,000 invitations 2,000 invitations/minute
XMPP Stanzas Sent 10,000 stanzas n/a Based on your budget n/a
Outgrowing the maximums? Request an increase.