You can use GPU with your Cloud Run workerpools for AI and other compute-intensive workloads. Google provides NVIDIA RTX PRO 6000 Blackwell GPU with 96 GB of GPU memory (VRAM) for a full GPU or 48 GB of GPU memory (VRAM) for a fractional (0.5) GPU, and NVIDIA L4 GPU with 24 GB of GPU memory (VRAM). GPU memory is separate from instance memory.
When using an LLM, be sure to also see Best practices: Cloud Run workerpools with GPU.
GPU on Cloud Run is fully managed, with no extra drivers or libraries required. Cloud Run GPU offers on-demand availability with no reservations needed, similar to the way on-demand CPU and on-demand memory work in Cloud Run.
Cloud Run container instances with an NVIDIA RTX PRO 6000 Blackwell Blackwell or L4 GPU start in about 5 seconds. Your container can use the GPU as soon as the startup finishes.
You can configure up to one GPU per Cloud Run container instance. If you use sidecar containers, the GPU can only be attached to one container.
Supported GPU types
Cloud Run supports two GPU types:
NVIDIA RTX PRO 6000 Blackwell GPU:
- Full GPU with the current NVIDIA driver version is 580.x.x (13.0). This GPU requires a minimum of 20 CPU and 80 GiB of memory.
- Fractional GPU with the current NVIDIA driver version is 580.x.x
(13.0), type: GRID. Fractional
GPU (
0.5GPU, 48 GB VRAM) requires 10, 12, 14, or 16 CPU and at least 40 GiB of memory (up to 4 GiB per CPU).
L4 GPU with the current NVIDIA driver version: 580.x.x (13.0). For L4 GPU, you must use a minimum of 4 CPU and 16 GiB of memory. Fractional GPU is not supported on L4 GPU.
Fractional GPU
Fractional GPU lets you to reduce your GPU allocation for models that don't require a full GPU, while still benefiting from the GPU's advanced architecture and performance. With a fractional GPU, you can have a more cost effective solution for inference workloads that don't need the full capabilities of a full-sized NVIDIA RTX PRO 6000 Blackwell GPU. See Known issues for fractional GPU limitations.
Supported regions
The following regions are supported by the NVIDIA RTX PRO 6000 Blackwell GPU:
asia-southeast1(Singapore).asia-south2(Delhi, India).europe-west4(Netherlands)Low CO2
us-central1(Iowa)Low CO2
Fractional NVIDIA RTX PRO 6000 Blackwell GPU (Preview) are available in the following regions:
The following regions are supported by the L4 GPU:
asia-southeast1(Singapore)asia-south1(Mumbai) . This region is available by invitation only. Contact your Google Account team if you are interested in this region.europe-west1(Belgium)Low CO2
europe-west4(Netherlands)Low CO2
us-central1(Iowa)Low CO2 . Additional resource scaling in this region might require a quota increase request. Contact your Google Account team if you are interested in this region.
us-east4(Northern Virginia) . Additional resource scaling in this region might require a quota increase request. Contact your Google Account team if you are interested in this region.
Pricing impact
See Cloud Run pricing for GPU pricing details. Note the following requirements and considerations:
- For GPU pricing, there's a cost difference between GPU zonal redundancy and non-zonal redundancy.
- GPU worker pools cannot be autoscaled. You are charged for GPU even if GPU isn't running any process for as long as the worker pool GPU instance is running.
- While worker pools price their GPU differently than services and jobs, their SKU pricing is all the same.
- The CPU and memory configurations of your resource impact pricing.
- GPU is billed for the entire duration of the instance lifecycle.
GPU zonal redundancy options
By default, Cloud Run deploys your worker pool across multiple zones within a region. This architecture provides inherent resilience: if a zone experiences an outage, Cloud Run automatically routes traffic away from the affected zone to healthy zones within the same region.
When working with GPU resources, keep in mind GPU resources have specific capacity constraints. During a zonal outage, the standard failover mechanism for GPU workloads relies on sufficient unused GPU capacity being available in the remaining healthy zones. Due to the constrained nature of GPU, this capacity might not always be available.
To increase the availability of your GPU-accelerated worker pools during zonal outages, you can configure zonal redundancy specifically for GPU:
Zonal Redundancy Turned On (default): Cloud Run reserves GPU capacity for your worker pool across multiple zones. This significantly increases the probability that your worker pool can successfully handle traffic rerouted from an affected zone, offering higher reliability during zonal failures with additional cost per GPU second.
Zonal Redundancy Turned Off: Cloud Run attempts failover for GPU workloads on a best-effort basis. Traffic is routed to other zones only if sufficient GPU capacity is available at that moment. This option does not guarantee reserved capacity for failover scenarios but results in a lower cost per GPU second.
SLA
The SLA for Cloud Run GPU depends on whether the worker pool uses the zonal redundancy or non-zonal redundancy option. Refer to the SLA page for details.
Request a quota increase
Quota for Cloud Run nvidia-rtx-pro-6000 GPU is granted in milliGPUs.
A full (1) nvidia-rtx-pro-6000 GPU consumes 1,000 milliGPUs of quota, and a
fractional (0.5) nvidia-rtx-pro-6000 GPU consumes 500 milliGPUs of quota.
Projects using nvidia-rtx-pro-6000 GPU in a region for the first time will be
automatically granted 3,000 milliGPU quota (zonal redundancy off) when the first
deployment is created. This is equivalent to 3 full GPUs or 6 fractional (0.5)
GPUs. Projects using Cloud Run nvidia-l4 GPU in a region for the
first time are automatically granted 3 GPU quota (zonal redundancy off) when the
first deployment is created.
If you need additional Cloud Run GPUs, you must request a quota increase for your Cloud Run worker pool. Use the links provided in the following buttons to request the quota you need.
| Quota needed | Quota link |
|---|---|
| NVIDIA RTX PRO 6000 Blackwell GPU with zonal redundancy turned off (lower price) | Request GPU quota without zonal redundancy |
| NVIDIA RTX PRO 6000 Blackwell GPU with zonal redundancy turned on (higher price) | Request GPU quota with zonal redundancy |
| L4 GPU with zonal redundancy turned off (lower price) | Request GPU quota without zonal redundancy |
| L4 GPU with zonal redundancy turned on (higher price) | Request GPU quota with zonal redundancy |
For more information on requesting quota increases, see How to increase quota.
Before you begin
The following list describes requirements and limitations when using GPU in Cloud Run:
- Sign in to your Google Cloud account. 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.
-
In the Google Cloud console, on the project selector page, select or create a Google Cloud project.
Roles required to select or create a project
- Select a project: Selecting a project doesn't require a specific IAM role—you can select any project that you've been granted a role on.
-
Create a project: To create a project, you need the Project Creator role
(
roles/resourcemanager.projectCreator), which contains theresourcemanager.projects.createpermission. Learn how to grant roles.
-
Verify that billing is enabled for your Google Cloud project.
-
In the Google Cloud console, on the project selector page, select or create a Google Cloud project.
Roles required to select or create a project
- Select a project: Selecting a project doesn't require a specific IAM role—you can select any project that you've been granted a role on.
-
Create a project: To create a project, you need the Project Creator role
(
roles/resourcemanager.projectCreator), which contains theresourcemanager.projects.createpermission. Learn how to grant roles.
-
Verify that billing is enabled for your Google Cloud project.
Enable the Cloud Run API, if it is not already enabled.
Roles required to enable APIs
To enable APIs, you need the
serviceusage.services.enablepermission. If you created the project, then you likely already have this permission through the Owner role (roles/owner). Otherwise, you can get this permission through the Service Usage Admin role (roles/serviceusage.serviceUsageAdmin). Learn how to grant roles.- Request required quota.
- Consult GPU Best practices: Cloud Run worker pools with GPU for recommendations on building your container image and loading large models.
- Make sure your Cloud Run worker pool has the following configurations:
- The minimum memory and CPU requirements based on the type of GPU you are using.
- An optimal maximum concurrency for your GPU usage.
Required roles
To get the permissions that you need to configure and deploy Cloud Run worker pools, ask your administrator to grant you the following IAM roles on workerpools:
- Cloud Run Developer (
roles/run.developer) - the Cloud Run worker pool - Service Account User (
roles/iam.serviceAccountUser) - the service identity
For a list of IAM roles and permissions that are associated with Cloud Run, see Cloud Run IAM roles and Cloud Run IAM permissions. If your Cloud Run worker pool interfaces with Google Cloud APIs, such as Cloud Client Libraries, see the service identity configuration guide. For more information about granting roles, see deployment permissions and manage access.
Configure a Cloud Run worker pool with GPU
Any configuration change leads to the creation of a new revision. Subsequent revisions will also automatically get this configuration setting unless you make explicit updates to change it.
You can use the Google Cloud console, Google Cloud CLI or YAML to configure GPU.
Console
In the Google Cloud console, go to Cloud Run:
Select Worker Pools from the Cloud Run navigation menu:
- If you are configuring a new worker pool, click Deploy container. Fill out the initial worker pool settings page, then click Containers, Networking, Security.
- If you are configuring an existing worker pool, click the worker pool, then click Edit and deploy new revision.
Click the Containers tab.
- Configure CPU, memory, concurrency, execution environment, and startup probe following the recommendations in Before you begin
- Check the GPU checkbox, then select the GPU type from the GPU type menu, and the number of GPU from the Number of GPUs menu.
- By default, zonal redundancy is turned on. To change the current setting, select the GPU checkbox to show the GPU redundancy options.
- Select No zonal redundancy to turn off zonal redundancy
- Select Zonal redundancy to turn on zonal redundancy.
Click Create or Deploy.
gcloud
To create a GPU-enabled worker pool, use the
gcloud run worker-pools deploy
command:
gcloud run worker-pools deploy WORKER_POOL \ --image IMAGE_URL \ --gpu GPU_NUMBER \ --gpu-type GPU_TYPE
Replace the following:
- WORKER_POOL: the name of your Cloud Run worker pool.
IMAGE_URL: a reference to the container image that contains the worker pool, such asus-docker.pkg.dev/cloudrun/container/worker-pool:latest.- GPU_NUMBER: the number of GPU to attach (
1for a full GPU, or0.5for a fractional GPU). - GPU_TYPE: the GPU type (
nvidia-rtx-pro-6000ornvidia-l4).
To update the GPU configuration for a worker pool, use the
gcloud run worker-pools update
command:
gcloud run worker-pools update WORKER_POOL \ --image IMAGE_URL \ --cpu CPU \ --memory MEMORY \ --gpu GPU_NUMBER \ --gpu-type GPU_TYPE \ --GPU_ZONAL_REDUNDANCY
Replace the following:
- WORKER_POOL: the name of your Cloud Run worker pool.
IMAGE_URL: a reference to the container image that contains the worker pool, such asus-docker.pkg.dev/cloudrun/container/worker-pool:latest.- CPU: the number of CPUs. Ensure this meets the minimum requirements.
- MEMORY: the amount of memory. Ensure this meets the minimum requirements.
- GPU_NUMBER: the number of GPU to attach (
1for a full GPU, or0.5for a fractional GPU). - GPU_TYPE: the GPU type. For NVIDIA RTX PRO 6000 Blackwell GPU,
enter
nvidia-rtx-pro-6000. For L4 GPU, enter valuenvidia-l4(nvidia-L4 lowercase L, not numeric value fourteen). - GPU_ZONAL_REDUNDANCY:
no-gpu-zonal-redundancyto turn off zonal redundancy, orgpu-zonal-redundancyto turn on zonal redundancy.
YAML
If you are creating a new worker pool, skip this step. If you are updating an existing worker pool, download its YAML configuration:
gcloud run worker-pools describe WORKER_POOL --format export > worker-pool.yaml
Update the
nvidia.com/gpu:attribute andnodeSelector::
run.googleapis.com/accelerator:apiVersion: run.googleapis.com/v1 kind: WorkerPool metadata: name: WORKER_POOL spec: template: metadata: annotations: run.googleapis.com/gpu-zonal-redundancy-disabled: 'GPU_ZONAL_REDUNDANCY' spec: containers: - image: IMAGE_URL resources: limits: cpu: 'CPU' memory: 'MEMORY' nvidia.com/gpu: 'GPU_NUMBER' nodeSelector: run.googleapis.com/accelerator: GPU_TYPE
Replace the following:
- WORKER_POOL: the name of your Cloud Run worker pool.
IMAGE_URL: a reference to the container image that contains the worker pool, such asus-docker.pkg.dev/cloudrun/container/worker-pool:latest.- CPU: the number of CPUs. Ensure this meets the minimum requirements.
- MEMORY: the amount of memory. Ensure this meets the minimum requirements.
- GPU_NUMBER: the number of GPU to attach (
1for a full GPU, or0.5for a fractional GPU). - GPU_TYPE: the GPU type. For NVIDIA RTX PRO 6000 Blackwell GPU,
enter
nvidia-rtx-pro-6000. For L4 GPU, enter valuenvidia-l4(nvidia-L4 lowercase L, not numeric value fourteen). - GPU_ZONAL_REDUNDANCY:
falseto turn on GPU zonal redundancy, ortrueto turn it off.
Create or update the worker pool using the following command:
gcloud run worker-pools replace worker-pool.yaml
The
gcloud run worker-pools replacecommand defaults to usingworker-pool.yamlfile if present.
Terraform
To learn how to apply or remove a Terraform configuration, see Basic Terraform commands.
Add the following to agoogle_cloud_run_v2_worker_pool
resource in your Terraform configuration:resource "google_cloud_run_v2_worker_pool" "default" {
provider = google-beta
name = "WORKER_POOL"
location = "REGION"
template {
gpu_zonal_redundancy_disabled = "GPU_ZONAL_REDUNDANCY"
containers {
image = "IMAGE_URL"
resources {
limits = {
"cpu" = "CPU"
"memory" = "MEMORY"
"nvidia.com/gpu" = "GPU_NUMBER"
}
}
}
node_selector {
accelerator = "GPU_TYPE"
}
}
}
Replace the following:
- WORKER_POOL: the name of your Cloud Run worker pool.
- REGION: the Google Cloud region where your worker pool is deployed.
- GPU_ZONAL_REDUNDANCY:
falseto turn on GPU zonal redundancy, ortrueto turn it off. IMAGE_URL: a reference to the container image that contains the worker pool, such asus-docker.pkg.dev/cloudrun/container/worker-pool:latest.- CPU: the number of CPUs. Ensure this meets the minimum requirements.
- MEMORY: the amount of memory. Ensure this meets the minimum requirements.
- GPU_NUMBER: the number of GPU to attach (
1for a full GPU, or0.5for a fractional GPU). - GPU_TYPE: the GPU type. For NVIDIA RTX PRO 6000 Blackwell GPU,
enter
nvidia-rtx-pro-6000. For L4 GPU, enter valuenvidia-l4(nvidia-L4 lowercase L, not numeric value fourteen).
View GPU settings
To view the current GPU settings for your Cloud Run worker pool, use the Google Cloud console or the Google Cloud CLI:
Console
In the Google Cloud console, go to the Cloud Run worker pools page:
Click the worker pool to open the Worker pools details page.
Click Edit and deploy new revision.
Locate the GPU setting in the configuration details.
gcloud
Run the following command:
gcloud run worker-pools describe WORKER_POOL
Locate the GPU setting in the returned configuration.
Remove GPU
You can remove GPU using the Google Cloud console, the Google Cloud CLI, or YAML.
Console
In the Google Cloud console, go to Cloud Run:
Select Worker Pools from the Cloud Run navigation menu, and click Deploy container to configure a new worker pool. If you are configuring an existing worker pool, click the worker pool, then click Edit and deploy new revision.
If you are configuring a new worker pool, fill out the initial worker pool settings page, then click Containers, Networking, Security to expand the worker pool configuration page.
Click the Containers tab.
Clear the GPU checkbox.
Click Create or Deploy.
gcloud
To remove GPU, set the number of GPU to 0:
gcloud run worker-pools update WORKER_POOL --gpu 0
Replace WORKER_POOL with the name of your Cloud Run worker pool.
YAML
If you are creating a new worker pool, skip this step. If you are updating an existing worker pool, download its YAML configuration:
gcloud run worker-pools describe WORKER_POOL --format export > worker-pool.yaml
Delete the
nvidia.com/gpu:and thenodeSelector: run.googleapis.com/accelerator: GPU_TYPElines.Create or update the worker pool using the following command:
gcloud run worker-pools replace worker-pool.yaml
The
gcloud run worker-pools replacecommand defaults to usingworker-pool.yamlfile if present.
Driver libraries
By default, all of the NVIDIA RTX PRO 6000 Blackwell GPU and NVIDIA L4 GPU driver libraries
are mounted under /usr/local/nvidia/lib64. Cloud Run automatically
appends this path to the LD_LIBRARY_PATH environment variable
(i.e. ${LD_LIBRARY_PATH}:/usr/local/nvidia/lib64) of the container with the
GPU. This allows the dynamic linker to find the NVIDIA driver libraries. The
linker searches and resolves paths in the order you list in the LD_LIBRARY_PATH
environment variable. Any values you specify in this variable take precedence
over the default Cloud Run driver libraries path /usr/local/nvidia/lib64.
If you want to use a CUDA version greater than 13.0,
the easiest way is to depend on a newer NVIDIA base image
with forward compatibility packages already installed. Another option is to
manually install the NVIDIA forward compatibility packages
and add them to LD_LIBRARY_PATH. Consult NVIDIA's compatibility matrix
to determine which CUDA versions are forward compatible with the provided NVIDIA
driver version.