Migrate App Engine container images to Artifact Registry
Stay organized with collectionsSave and categorize content based on your preferences.
Region ID
TheREGION_IDis an abbreviated code that Google assigns
based on the region you select when you create your app. The code does not
correspond to a country or province, even though some region IDs may appear
similar to commonly used country and province codes. For apps created after
February 2020,REGION_ID.ris included in
App Engine URLs. For existing apps created before this date, the
region ID is optional in the URL.
Container Registry is deprecated and wasshutdownon March 18, 2025.
We recommend that you useArtifact Registryfor
storing and managing container images.
By default, new deployments created after March 5, 2025 use Artifact Registry instead of
Container Registry for storing application images.
Artifact Registry provides the same container management features as Container Registry
and includes additional features and benefits. As a fully managed service with
support for both container images and non-container artifacts, Artifact Registry extends
the capabilities of Container Registry.
For projects created before May 2024 or that
haven't yet run theautomated migration tooling, follow the steps in this guide to enable App Engine to
automatically migrate your deployment flows.
App Engine standard environment
Most of your application components in the standard environment follow an automated
migration process. However, for a smooth
transition to Artifact Registry, ensure that your service account has the
following required permissions:
For existing standard deployments, the
deploying service account (either theApp Engine default service account(PROJECT_ID@appspot.gserviceaccount.com)
or yourcustom service account) must
have a role that grants the explicit Artifact Registry write permissionartifactregistry.repositories.uploadArtifacts. To find the roles associated with your
deploying service account, seeManage access to service accounts.
New deployments can use Artifact Registry if any of the following
roles are present in the service account associated with deployments:
Custom role that grantsartifactregistry.repositories.uploadArtifactspermission. You can verify custom roles access from theGoogle Cloud consoleor by
running thegcloud iam roles describecommand.
If none of these roles are present, grant the Artifact Registry Writer role (roles/artifactregistry.writer) to your deploying service account.
Failing to provide the required permissions prevents you from deploying
new versions in the standard environment.
During automated migrations, Google Cloud might create new repositories and copy
images from Container Registry to Artifact Registry.
App Engine flexible environment
Most of your application components in the flexible environment follow an automated
migration process. However, for a smooth
transition to Artifact Registry, ensure that your service account has the
following required permissions:
For existing flexible deployments to work as expected with Artifact Registry, the
deploying service account (either theApp Engine default service account(PROJECT_ID@appspot.gserviceaccount.com) or yourcustom service account)
must have a role that grants the explicit Artifact Registry permissions such asartifactregistry.repositories.downloadArtifactsfor read andartifactregistry.repositories.uploadArtifactsfor write. To find the roles associated with your
deploying service account, seeManage access to service accounts.
New deployments can use Artifact Registry, if any of the following roles
are present in the service account associated with deployments:
Custom role that grantsartifactregistry.repositories.downloadArtifactsandartifactregistry.repositories.uploadArtifactspermissions. You can
verify custom roles access from theGoogle Cloud consoleor by
running thegcloud iam roles describecommand.
If none of these roles are present, grant the Artifact Registry Repository Administrator
role (roles/artifactregistry.repoAdmin) to your deploying service account.
Failing to provide the required permissions prevents you from deploying
applications in the flexible environment. Scaling and restarting instances
also fail.
During automated migrations, Google Cloud might create new repositories and copy
images from Container Registry to Artifact Registry.
Migrate to Artifact Registry for manually built container images
The automated migration process doesn't apply if you previously deployed your apps
by usingprebuilt or manually built container imagesfromContainer Registry.
For example, the automated migration process doesn't work if you built container
images with Docker, pushed these images to the Container Registry, and deployed
your apps by using thegcloud app deploy --image-urlcommand.
If you use prebuilt or manually built container images from Container Registry
to deploy your apps, choose one of the following options to migrate to Artifact Registry:
Use the automatic migration tool to migrate from Container Registry togcr.iorepositories that are hosted on Artifact Registry. You don't need to redeploy new
versions of your service if you use this tool. For more information, seeAutomatically migrate from Container Registry to Artifact Registry.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-09-04 UTC."],[[["\u003cp\u003eRegion IDs are codes assigned by Google based on the selected region during app creation, and they are included in App Engine URLs for apps created after February 2020.\u003c/p\u003e\n"],["\u003cp\u003eContainer Registry is deprecated and will be shut down on March 18, 2025, with Artifact Registry recommended as its replacement for managing container images.\u003c/p\u003e\n"],["\u003cp\u003eFor a smooth transition to Artifact Registry, service accounts deploying to App Engine standard and flexible environments must have appropriate Artifact Registry permissions, such as \u003ccode\u003eartifactregistry.repositories.uploadArtifacts\u003c/code\u003e or the Artifact Registry Writer role.\u003c/p\u003e\n"],["\u003cp\u003eThe automated migration process to Artifact Registry does not cover apps deployed using prebuilt or manually built container images from Container Registry; these must use manual migration or other migration tools.\u003c/p\u003e\n"],["\u003cp\u003eNew deployments created after March 5, 2025 will use Artifact Registry instead of Container Registry for storing application images by default.\u003c/p\u003e\n"]]],[],null,["# Migrate App Engine container images to Artifact Registry\n\n### Region ID\n\nThe \u003cvar translate=\"no\"\u003eREGION_ID\u003c/var\u003e is an abbreviated code that Google assigns\nbased on the region you select when you create your app. The code does not\ncorrespond to a country or province, even though some region IDs may appear\nsimilar to commonly used country and province codes. For apps created after\nFebruary 2020, \u003cvar translate=\"no\"\u003eREGION_ID\u003c/var\u003e`.r` is included in\nApp Engine URLs. For existing apps created before this date, the\nregion ID is optional in the URL.\n\nLearn more\n[about region IDs](/appengine/docs/standard/python/how-requests-are-routed#region-id). \nOK\n\nContainer Registry is deprecated and was [shutdown](/artifact-registry/docs/transition/prepare-gcr-shutdown) on March 18, 2025.\nWe recommend that you use [Artifact Registry](/artifact-registry/docs/overview) for\nstoring and managing container images.\nBy default, new deployments created after March 5, 2025 use Artifact Registry instead of\nContainer Registry for storing application images.\nArtifact Registry provides the same container management features as Container Registry\nand includes additional features and benefits. As a fully managed service with\nsupport for both container images and non-container artifacts, Artifact Registry extends\nthe capabilities of Container Registry.\n\nFor projects created before May 2024 or that\nhaven't yet run the [automated migration tooling](/artifact-registry/docs/transition/auto-migrate-gcr-ar), follow the steps in this guide to enable App Engine to\nautomatically migrate your deployment flows.\n\nApp Engine standard environment\n-------------------------------\n\nMost of your application components in the standard environment follow an automated\nmigration process. However, for a smooth\ntransition to Artifact Registry, ensure that your service account has the\nfollowing required permissions:\n\n- For existing standard deployments, the\n deploying service account (either the [App Engine default service account](/appengine/docs/standard/configure-service-accounts#assign_an_app-level_default_service_account)\n (*\u003cvar translate=\"no\"\u003ePROJECT_ID\u003c/var\u003e`@appspot.gserviceaccount.com`* )\n or your [custom service account](/appengine/docs/standard/configure-service-accounts)) must\n have a role that grants the explicit Artifact Registry write permission `artifactregistry.repositories.uploadArtifacts`. To find the roles associated with your\n deploying service account, see [Manage access to service accounts](/iam/docs/manage-access-service-accounts#view-access).\n\n- New deployments can use Artifact Registry if any of the following\n roles are present in the service account associated with deployments:\n\n - [Editor role](/appengine/docs/standard/roles#basic_roles)\n\n - [Pre-defined Artifact Registry role](/artifact-registry/docs/access-control#roles)\n with write access, such as Artifact Registry Writer (`roles/artifactregistry.writer`).\n\n - Custom role that grants `artifactregistry.repositories.uploadArtifacts`\n permission. You can verify custom roles access from the\n [Google Cloud console](/iam/docs/creating-custom-roles#get-metadata) or by\n running the [`gcloud iam roles describe`](/sdk/gcloud/reference/iam/roles/describe) command.\n\n If none of these roles are present, grant the Artifact Registry Writer role (`roles/artifactregistry.writer`) to your deploying service account.\n\nFailing to provide the required permissions prevents you from deploying\nnew versions in the standard environment.\n\nDuring automated migrations, Google Cloud might create new repositories and copy\nimages from Container Registry to Artifact Registry.\n\nApp Engine flexible environment\n-------------------------------\n\nMost of your application components in the flexible environment follow an automated\nmigration process. However, for a smooth\ntransition to Artifact Registry, ensure that your service account has the\nfollowing required permissions:\n\n- For existing flexible deployments to work as expected with Artifact Registry, the\n deploying service account (either the\n [App Engine default service account](/appengine/docs/flexible/configure-service-accounts#assign_an_app-level_default_service_account)\n (*\u003cvar translate=\"no\"\u003ePROJECT_ID\u003c/var\u003e`@appspot.gserviceaccount.com`* ) or your [custom service account](/appengine/docs/flexible/configure-service-account))\n must have a role that grants the explicit Artifact Registry permissions such as `artifactregistry.repositories.downloadArtifacts` for read and `artifactregistry.repositories.uploadArtifacts` for write. To find the roles associated with your\n deploying service account, see [Manage access to service accounts](/iam/docs/manage-access-service-accounts#view-access).\n\n- New deployments can use Artifact Registry, if any of the following roles\n are present in the service account associated with deployments:\n\n - [Editor role](/appengine/docs/flexible/roles#basic_roles)\n\n - [Pre-defined Artifact Registry role](/artifact-registry/docs/access-control#roles)\n with read and write access, such as Artifact Registry Writer (`roles/artifactregistry.writer`).\n\n - Custom role that grants `artifactregistry.repositories.downloadArtifacts`\n and `artifactregistry.repositories.uploadArtifacts` permissions. You can\n verify custom roles access from the [Google Cloud console](/iam/docs/creating-custom-roles#get-metadata) or by\n running the [`gcloud iam roles describe`](/sdk/gcloud/reference/iam/roles/describe) command.\n\n If none of these roles are present, grant the Artifact Registry Repository Administrator\n role (`roles/artifactregistry.repoAdmin`) to your deploying service account.\n\nFailing to provide the required permissions prevents you from deploying\napplications in the flexible environment. Scaling and restarting instances\nalso fail.\n\nDuring automated migrations, Google Cloud might create new repositories and copy\nimages from Container Registry to Artifact Registry.\n\n### Migrate to Artifact Registry for manually built container images\n\nThe automated migration process doesn't apply if you previously deployed your apps\nby using [prebuilt or manually built container images](/appengine/docs/flexible/testing-and-deploying-your-app?tab=python#remote-container-build) from [Container Registry](/container-registry/docs/pushing).\nFor example, the automated migration process doesn't work if you built container\nimages with Docker, pushed these images to the Container Registry, and deployed\nyour apps by using the `gcloud app deploy --image-url` command.\n\nIf you use prebuilt or manually built container images from Container Registry\nto deploy your apps, choose one of the following options to migrate to Artifact Registry:\n\n- Use the automatic migration tool to migrate from Container Registry to\n `gcr.io` repositories that are hosted on Artifact Registry. You don't need to redeploy new\n versions of your service if you use this tool. For more information, see\n [Automatically migrate from Container Registry to Artifact Registry](/artifact-registry/docs/transition/auto-migrate-gcr-ar).\n\n- Manually move the container images from Container Registry to Artifact Registry and\n redeploy new versions of your service. For more information, see\n [Manual migration to `gcr.io` repositories in Artifact Registry](/artifact-registry/docs/transition/manual-gcr-repositories).\n\n- Use the [`copy-only`](/artifact-registry/docs/transition/auto-migrate-gcr-ar#copy_images)\n flag to copy your container images to Artifact Registry and redeploy new versions\n of your service."]]