Stay organized with collections
Save and categorize content based on your preferences.
Configure domain peering
This page shows you how to configure domain peering with Managed Service for Microsoft Active Directory (Managed Microsoft AD).
Before you begin
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.
PEERING_RESOURCE_NAME: a name for your domain peering resource (such as my-domain-peering).
DOMAIN_NAME: a full resource name for your
Managed Microsoft AD domain, in the form of:
projects/PROJECT_ID/locations/global/domains/DOMAIN_NAME.
VPC_NETWORK_NAME: a full resource name for your
VPC network, in the form of:
projects/PROJECT_ID/global/networks/NETWORK_NAME.
VPC_RESOURCE_PROJECT_ID: the project ID of the VPC network project that is hosting the VPC.
You receive the following response that indicates domain peering creation has started:
Create request issued for: PEERING_RESOURCE_NAME
Waiting for operation-1842751821453-5857b78a1a49e-02bc63a3-77e5c7ee to complete...
This operation can take up to 15 mins to complete.
You can repeat the process to create multiple domain peerings in a project.
However, you can peer up to 10 VPC networks with a Managed Microsoft AD domain.
[[["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-08-28 UTC."],[],[],null,["# Quickstart: Configure domain peering\n\nConfigure domain peering\n========================\n\nThis page shows you how to configure [domain peering](/managed-microsoft-ad/docs/domain-peering) with Managed Service for Microsoft Active Directory (Managed Microsoft AD).\n\nBefore you begin\n----------------\n\n- Sign in to your Google Cloud account. If you're new to Google Cloud, [create an account](https://console.cloud.google.com/freetrial) to evaluate how our products perform in real-world scenarios. New customers also get $300 in free credits to run, test, and deploy workloads.\n- In the Google Cloud console, on the project selector page,\n select or create a Google Cloud project.\n\n | **Note**: If you don't plan to keep the resources that you create in this procedure, create a project instead of selecting an existing project. After you finish these steps, you can delete the project, removing all resources associated with the project.\n\n [Go to project selector](https://console.cloud.google.com/projectselector2/home/dashboard)\n-\n [Verify that billing is enabled for your Google Cloud project](/billing/docs/how-to/verify-billing-enabled#confirm_billing_is_enabled_on_a_project).\n\n-\n\n\n Enable the\n Managed Microsoft AD, Cloud DNS, and Compute Engine\n APIs.\n\n\n [Enable the APIs](https://console.cloud.google.com/flows/enableapi?apiid=\n managedidentities.googleapis.com,dns.googleapis.com,compute.googleapis.com\n )\n\n- In the Google Cloud console, on the project selector page,\n select or create a Google Cloud project.\n\n | **Note**: If you don't plan to keep the resources that you create in this procedure, create a project instead of selecting an existing project. After you finish these steps, you can delete the project, removing all resources associated with the project.\n\n [Go to project selector](https://console.cloud.google.com/projectselector2/home/dashboard)\n-\n [Verify that billing is enabled for your Google Cloud project](/billing/docs/how-to/verify-billing-enabled#confirm_billing_is_enabled_on_a_project).\n\n-\n\n\n Enable the\n Managed Microsoft AD, Cloud DNS, and Compute Engine\n APIs.\n\n\n [Enable the APIs](https://console.cloud.google.com/flows/enableapi?apiid=\n managedidentities.googleapis.com,dns.googleapis.com,compute.googleapis.com\n )\n\n1. [Create a Managed Microsoft AD domain](/managed-microsoft-ad/docs/create-domain) in the domain resource project.\n2. [Create a VPC network](/vpc/docs/create-modify-vpc-networks) in the VPC resource project to which you want to peer your domain with.\n3. Make sure that the IP ranges assigned to Managed Microsoft AD and any authorized networks don't overlap.\n4. Make sure that you have any one of the following IAM roles:\n - Google Cloud Managed Identities Admin (`roles/managedidentities.admin`)\n - Google Cloud Managed Identities Peering Admin (`roles/managedidentities.peeringAdmin`)\n5. Optional: Check if you have the following IAM roles as well:\n - Google Cloud Managed Identities Viewer (`roles/managedidentities.viewer`)\n - Compute Network User (`roles/compute.networkUser`)\n - Compute Network Viewer (`roles/compute.networkViewer`)\n\n| **Note:** Be sure to enable the APIs and create the VPC in the same project where you enabled billing.\n\nConfigure domain peering\n------------------------\n\nAfter you complete the prerequisites and gather your domain information, you\ncan create the domain peering. \n\n### Console\n\nTo create a peering from the domain resource project, follow these steps:\n\n1. In the Google Cloud console, go to the **Managed Microsoft AD** page. \n [Go to Managed Microsoft AD](https://console.cloud.google.com/security/cloud-ad)\n2. Click the **Peerings** tab.\n3. On the **Peerings** page, click **Create peering**.\n4. In the **Name** field, enter a name for your peering resource.\n5. Select **Domain**.\n6. In the **Select domain from this project** list, select your Managed Microsoft AD domain.\n7. Enter the project ID or number that includes the VPC network you want to peer with.\n8. Enter the name of your VPC network.\n9. Optional: To add labels, expand the **Labels** section. Click **Add labels**, and then enter the key-value pairs.\n10. Click **Create**.\n\nAfter the operation is complete, the **Peerings** page lists the peering with status as **Disconnected**.\n\nTo create a peering from the VPC resource project, follow these steps:\n\n1. In the Google Cloud console, go to the **Managed Microsoft AD** page. \n [Go to Managed Microsoft AD](https://console.cloud.google.com/security/cloud-ad)\n2. Click the **Peerings** tab.\n3. On the **Peerings** page, click **Create peering**.\n4. In the **Name** field, enter a name for your peering resource.\n5. Select **Network**.\n6. In the **Select network from this project** list, select your VPC network.\n7. Enter the project ID or number that includes your Managed Microsoft AD domain.\n8. Enter the name of your Managed Microsoft AD domain.\n9. Optional: To add labels, expand the **Labels** section. Click **Add labels**, and then enter the key-value pairs.\n10. Click **Create**.\n\nAfter the operation is complete, the **Peerings** page lists the peerings with status as **Connected** on both the projects.\n\n### gcloud\n\nRun the following gcloud CLI command. \n\n```\ngcloud active-directory peerings create PEERING_RESOURCE_NAME \\\n --domain=DOMAIN_NAME \\\n --authorized-network=VPC_NETWORK_NAME\n```\n\nReplace the following:\n\n- \u003cvar translate=\"no\"\u003ePEERING_RESOURCE_NAME\u003c/var\u003e: a name for your domain peering resource (such as *my-domain-peering*).\n- \u003cvar translate=\"no\"\u003eDOMAIN_NAME\u003c/var\u003e: a **[full resource name](/iam/docs/full-resource-names)** for your Managed Microsoft AD domain, in the form of: `projects/`\u003cvar translate=\"no\"\u003ePROJECT_ID\u003c/var\u003e`/locations/global/domains/`\u003cvar translate=\"no\"\u003eDOMAIN_NAME\u003c/var\u003e.\n- \u003cvar translate=\"no\"\u003eVPC_NETWORK_NAME\u003c/var\u003e: a **[full resource name](/iam/docs/full-resource-names)** for your VPC network, in the form of: `projects/`\u003cvar translate=\"no\"\u003ePROJECT_ID\u003c/var\u003e`/global/networks/`\u003cvar translate=\"no\"\u003eNETWORK_NAME\u003c/var\u003e.\n\nYou receive the following response that indicates domain peering creation has\nstarted: \n\n```\nCreate request issued for: PEERING_RESOURCE_NAME\nWaiting for operation-1842751234221-5857b78a1a49e-02bc63a3-77e5c7ee to complete...\n```\n\nAfter the operation is complete, configure domain peering in the VPC resource\nproject.\nRun the following gcloud CLI command. \n\n```\ngcloud active-directory peerings create PEERING_RESOURCE_NAME \\\n --domain=DOMAIN_NAME \\\n --authorized-network=VPC_NETWORK_NAME \\\n --project=VPC_RESOURCE_PROJECT_ID\n```\n\nReplace the following:\n\n- \u003cvar translate=\"no\"\u003ePEERING_RESOURCE_NAME\u003c/var\u003e: a name for your domain peering resource (such as *my-domain-peering*).\n- \u003cvar translate=\"no\"\u003eDOMAIN_NAME\u003c/var\u003e: a **[full resource name](/iam/docs/full-resource-names)** for your Managed Microsoft AD domain, in the form of: `projects/`\u003cvar translate=\"no\"\u003ePROJECT_ID\u003c/var\u003e`/locations/global/domains/`\u003cvar translate=\"no\"\u003eDOMAIN_NAME\u003c/var\u003e.\n- \u003cvar translate=\"no\"\u003eVPC_NETWORK_NAME\u003c/var\u003e: a **[full resource name](/iam/docs/full-resource-names)** for your VPC network, in the form of: `projects/`\u003cvar translate=\"no\"\u003ePROJECT_ID\u003c/var\u003e`/global/networks/`\u003cvar translate=\"no\"\u003eNETWORK_NAME\u003c/var\u003e.\n- \u003cvar translate=\"no\"\u003eVPC_RESOURCE_PROJECT_ID\u003c/var\u003e: the project ID of the VPC network project that is hosting the VPC.\n\nYou receive the following response that indicates domain peering creation has started: \n\n```\nCreate request issued for: PEERING_RESOURCE_NAME\nWaiting for operation-1842751821453-5857b78a1a49e-02bc63a3-77e5c7ee to complete...\n```\n\nThis operation can take up to 15 mins to complete.\nYou can repeat the process to create multiple domain peerings in a project.\nHowever, you can peer up to 10 VPC networks with a Managed Microsoft AD domain.\n\nWhat's next\n-----------\n\n- [Manage domain peerings](/managed-microsoft-ad/docs/list-describe-delete-domain-peering)\n- [Join a Windows VM to a domain](/managed-microsoft-ad/docs/quickstart-domain-join-windows)\n- [Join a Linux VM to a domain](/managed-microsoft-ad/docs/quickstart-domain-join-linux)\n- [Connect to a Managed Microsoft AD domain](/managed-microsoft-ad/docs/connect-to-active-directory-domain)"]]