Cloud IoT Core limits resource allocation and use and enforces appropriate quotas on a per-project basis. Specific policies vary depending on resource availability, user profile, service usage history, and other factors, and are subject to change without notice.
Limits
This section lists the quotas for Cloud IoT Core in three categories: project/device/telemetry, rate, and time.
Project, device, and telemetry limits
Quota | Limit | Can be increased |
---|---|---|
Devices per project, per region | Unlimited, but the default is 100,000 | Yes |
Device registries per project, per region | 100 | Yes |
Devices bound to a gateway | 10,000 | No |
Devices attached to a gateway | 1,000 | No |
Gateways bound to a device | 10 | No |
Device ID length | 256 bytes | No |
Device registry ID length | 256 bytes | No |
Device metadata | 500 key-value pairs | No |
Device metadata key | 128 characters | No |
Device metadata value | 32 KB | No |
Combined size of metadata key-value pairs | 256 KB | No |
Credentials per device | 3 | No |
Configuration versions per device | 10 | No |
Device configuration data | 64 KB | No |
Maximum page size for list request | 500 | No |
Device state payload | 64 KB | No |
Telemetry event notification configurations | 10 | No |
Telemetry event payload | 256 KB | No |
MQTT connections per device | 1 | No |
Open MQTT connections, per project per region | 10,000 | Yes |
Active HTTP device connections (within the past 5 minutes), per project per region | 10,000 | Yes |
Rate limits
Quota | Limit | Can be increased |
---|---|---|
HTTP device telemetry publishes per device | 6,000 per min | No |
Device telemetry publishes per project | Unlimited, but the default is 60,000 per min | Yes |
Device-to-cloud throughput, per device | 512 KB/s | No |
Cloud-to-device throughput, per device | 512 KB/s | No |
Configuration updates per device | 1 per sec | No |
Attribute updates per device | 1 per sec | No |
Attribute updates per registry | 1 per sec | No |
Device manager API read calls per project | 30,000 per min | Yes |
Device manager API create and delete calls per project | 3,000 per min | No |
Device manager API update calls per project (see the exception in the next row) |
3,000 per min | Yes |
Device manager API modifyCloudToDeviceConfig calls per project |
6,000 per min | Yes |
MQTT incoming messages per sec, per connection | 100 per sec | No |
Device MQTT connections per device | 1 per sec | No |
Device MQTT connections and HTTP requests per project | 60,000 per min | Yes |
State updates per device | 1 per sec* | No |
State updates per project | 6,000 per min* | Yes |
Number of logged events per project | 1,000 per sec | Yes |
Size of logged events per project | 1 MB per sec (each log entry is roughly 1 KB) | Yes |
Commands per registry | 1,000 per sec | Yes |
Commands per project | 1,000 per sec | Yes |
MQTT subscriptions to the commands topic per device connection | 1 per sec | No |
*For details, see Getting Device State.
Time limits
Quota | Limit | Can be increased |
---|---|---|
JWT authorization clock skew | 10 min | No |
JWT lifetime (exp minus iat cannot exceed the limit) |
24 hr | No |
MQTT idle time (without heartbeat or message) | 20 min | No |
MQTT connection time | 24 hr** | No |
Command timeout | 60 sec | No |
Command retries | 60 sec | No |
**Connections may be reset occasionally (for example, for a server restart).
Quota enforcement
The consequences of exceeding quota are different for projects and resources, such as a registries and devices:
- Project exceeds quota: Project is blocked until usage is back under the limit. In rare cases, a quota enforcement period can continue even when your usage is no longer over the limit. If your project is still being blocked even though you're no longer exceeding any quotas, wait a while and try again.
- Device using the MQTT bridge exceeds quota: Device is disconnected.
- Device using the HTTP bridge exceeds quota: Device receives a
RESOURCE_EXHAUSTED
response.
For example, if you attempt to update a device's configuration more than once per second over the MQTT bridge, Cloud IoT Core disconnects the device. To fix the problem, ensure you publish device configurations no more than once per second, ideally once per 10 seconds, then reconnect the device. See Configuring Devices for more information.
Quota increases
Limits are set at their maximum values by default. To request an increase above the maximum:
In the APIs & Services in Google Cloud console, select the quota to edit.
Click Edit quotas.
Fill out the Edit quotas pane and click Next.
Click apply for higher quota, then fill out and submit the Quota Request form.
If you want to increase a quota, but it doesn't appear in Google Cloud console, complete the Quota Request form.
Compressed HTTP requests
As noted in Using the HTTP Bridge, a device can send gzip-compressed data to Cloud IoT Core over the HTTP bridge.
Limits for telemetry event payloads and device state payloads are calculated using the uncompressed size of each request.
For example, if a device sends a compressed telemetry event payload that is 10 KB, but the original payload before compression was 257 KB, the request fails because 257 KB exceeds the telemetry event payload limit of 256 KB.