Create public delegated prefixes
You can createpublic delegated prefixesbefore the public advertised prefix creation is complete.
The public advertised prefix type determines the configuration of the publicdelegated prefix. For more information, seeBring your own IPconfigurations.
We recommend that you use v2 public advertised prefixes to create regionalpublic delegated prefixes. You must use v2 public advertised prefixes to importIPv6 prefixes to Google Cloud.
Before you begin
- Create a public advertised prefix.
- If you're creating a global public delegated prefix, the parent publicadvertised prefix must meet these requirements:
- The public advertised prefix is used for global public delegatedprefixes only.
- The public advertised prefix is in a project that has been added to theallowlist for global prefixes. For more information, seeGlobal publicdelegated prefixes.
Roles
To get the permissions that you need to complete the tasks in this guide, ask your administrator to grant you theCompute Public IP Admin (roles/compute.publicIpAdmin) IAM role on your project. For more information about granting roles, seeManage access to projects, folders, and organizations.
You might also be able to get the required permissions throughcustom roles or otherpredefined roles.
Create public delegated prefixes
A public delegated prefix name can't be changed without deleting and recreatingthe resource. For this reason, we recommend that you create generic names thatwon't need to change—for example,pdp-203-0-113-0-25, wherepdpdenotes the resource type and203-0-113-0-25 denotes the specific prefix andprefix length.
To create a global public delegated prefix, you must use a public advertisedprefix that is used for global public delegated prefixes only, and is in aproject that has been added to the allowlist for global prefixes. For moreinformation, seeGlobal public delegatedprefixes.
Console
- In the Google Cloud console, go toBring your own IP.
- Click the public advertised prefix that you want to delegate.
- ClickCreate PDP.
- ForName, enter a name for the public delegated prefix.
- ForDescription, enter an optional description for the publicdelegated prefix.
- If you're creating a public delegated prefix for an IPv4 address range,do the following:
- Select a prefix length from thePrefix length list.
- Select a range of IP addresses from theIP addresses list.
- Select aScope for the public delegated prefix.
- If you selectedRegional for the scope, select aRegion.
- If you're creating a public delegated prefix for an IPv6 address range,do the following:
- Select a prefix length from theIPv6 prefix length list.
- Enter an IPv6 address range inIPv6 range.
- Select a region from theRegion list.
- Select aProject for the public delegated prefix.
- ClickCreate.
gcloud
Use thepublic-delegated-prefixescreatecommand.
To create an IPv4 PDP, use the following command:
gcloud compute public-delegated-prefixes createPDP_NAME \ --public-advertised-prefix=PAP_NAME \ --range=PDP_IP_RANGE \ --region=PDP_REGION
Replace the following:
PDP_NAME: the name to use for the public delegatedprefix that you are creating.PAP_NAME: the name of the public advertised prefix touse to create the public delegated prefix.PDP_IP_RANGE: the IPv4 or IPv6 address range to useto create the public delegated prefix.PDP_DESCRIPTION: an optional description for thepublic delegated prefix.PDP_REGION: the region where you want to use thepublic delegated prefix addresses. If you want a global public delegatedprefix instead, replace--region=PDP_REGIONwith--global.
To create an IPv6 PDP, use the following commamd:
gcloud compute public-delegated-prefixes createPDP_NAME \ --public-advertised-prefix=PAP_NAME \ --range=PDP_IP_RANGE \ --region=PDP_REGION \ --mode=DELEGATION
Check the status of a public delegated prefix
You can check the status of a public delegated prefix. The available statusesfor both v2 and v1 public delegated prefixes are described in the followingtable.
| Status | Description | v2 | v1 |
|---|---|---|---|
INITIALIZING | The public delegated prefix is being initialized and addresses can't be created yet. | ||
READY_TO_ANNOUNCE | The public delegated prefix is withdrawn, and is ready to be announced. | ||
ANNOUNCED | The public delegated prefix is active and is announced. | ||
ANNOUNCED_TO_GOOGLE | The prefix is announced within Google Cloud's network. | ||
ANNOUNCED_TO_INTERNET | The prefix is announced to the internet and within Google Cloud's network. | ||
DELETING | The public delegated prefix is being deprovisioned. |
Console
In the Google Cloud console, go toBring your own IP.
TheStatus column displays the status for all public delegatedprefixes.
gcloud
To describe the public delegated prefix and get its status, use thepublic-delegated-prefixes describecommand.
gcloud compute public-delegated-prefixes describePDP_NAME \ --region=PDP_REGION \ --format='value(status)'
Replace the following:
PDP_NAME: the public delegated prefix or sub-prefixthat you want to get information for.PDP_REGION: the region of the public delegated prefixor sub-prefix.PDP_REGION: the region where you want to use thepublic delegated prefix addresses. If you want a global public delegatedprefix instead, replace--region=PDP_REGIONwith--global.
What's next
Except as otherwise noted, the content of this page is licensed under theCreative Commons Attribution 4.0 License, and code samples are licensed under theApache 2.0 License. For details, see theGoogle Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-12-17 UTC.