Got this error when trying to upload an app service with azure cli

QR 20 Reputation points
2026-01-02T14:54:24.0533333+00:00

was disallowed by Azure: This policy maintains a set of best available regions where your subscription can deploy resources. The objective of this policy is to ensure that your subscription has full access to Azure services with optimal performance. Should you need additional or different regions, contact support..

Code: RequestDisallowedByAzure

I am using a student subscription from school and other students are able to do this with no problem.

I am using the default az webapp up command without adding a region.

Please help.

Azure App Service
Azure App Service

Azure App Service is a service used to create and deploy scalable, mission-critical web apps.


Answer accepted by question author
Golla Venkata Pavani 7,355 Reputation points Microsoft External Staff Moderator
2026-01-02T17:44:27.91+00:00

Hii @QR,

You are seeing the error “RequestDisallowedByAzure” because your subscription has Azure Policies that restrict which regions you are allowed to deploy resources into. This behavior is expected, especially for Azure for Students subscriptions.Azure for Students subscriptions only allow deployments in a small, predefined list of regions, and these allowed regions can vary from one student account to another. If the Azure CLI selects a region that is not permitted, any App Service, Static Web App, VM, or other resource creation will fail with this error.

This Happens because:

  • Azure automatically enforces policies such as “Allowed resource deployment regions.”
  • Azure for Students has limited regional availability, so even globally available services may not be allowed for your specific subscription.
  • When you run az webapp up without specifying a region, Azure chooses a default region which may not be allowed for your subscription.

Please follow below recommended steps to resolve the issue:

1.You can check the Allowed locations by following below step:

  • Go to Azure Portal > Policy > Assignments > search for Allowed resource deployment regions / Allowed locations > View the list of regions permitted for your subscription.2.

2.Deploy using an allowed region:
Run the command below, replacing values with your app name, resource group, and an allowed region from your policy list:

az webapp up --name YourAppName --resource-group YourResourceGroupName --location YourPreferredLocation

Some student subscriptions have restrictions where certain services (like App Service or Static Web Apps) are not available in any allowed region. In this case, you may need to open an Azure Support request to clarify or request additional region access.

Reference:
https://learn.microsoft.com/en-us/cli/azure/webapp?view=azure-cli-latest#az-webapp-up
https://learn.microsoft.com/en-us/microsoft-365/services/error-request-disallowed-by-policy?view=o365-worldwide

Kindly let us know if the above comment helps or you need further assistance on this issue.

Please "accept" if the information helped you. This will help us and others in the community as well.

Was this answer helpful?

1 person found this answer helpful.

1 additional answer

Sort by: Most helpful
  1. QR 20 Reputation points
    2026-01-07T13:15:40.2433333+00:00

    Golla Venkata Pavani • Follow 565 Reputation points• Microsoft External Staff • Moderator Jan 2, 2026, 6:44 PM Hii @QR, You are seeing the error “RequestDisallowedByAzure” because your subscription has Azure Policies that restrict which regions you are allowed to deploy resources into. This behavior is expected, especially for Azure for Students subscriptions.Azure for Students subscriptions only allow deployments in a small, predefined list of regions, and these allowed regions can vary from one student account to another. If the Azure CLI selects a region that is not permitted, any App Service, Static Web App, VM, or other resource creation will fail with this error. This Happens because:

    • Azure automatically enforces policies such as “Allowed resource deployment regions.”
    • Azure for Students has limited regional availability, so even globally available services may not be allowed for your specific subscription.
    • When you run az webapp up without specifying a region, Azure chooses a default region which may not be allowed for your subscription. Please follow below recommended steps to resolve the issue: 1.You can check the Allowed locations by following below step:
    • Go to Azure Portal > Policy > Assignments > search for Allowed resource deployment regions / Allowed locations > View the list of regions permitted for your subscription.2. 2.Deploy using an allowed region: Run the command below, replacing values with your app name, resource group, and an allowed region from your policy list: Azure CLI
    `az webapp up --name YourAppName --resource-group YourResourceGroupName --location YourPreferredLocation
    `
    

    Some student subscriptions have restrictions where certain services (like App Service or Static Web Apps) are not available in any allowed region. In this case, you may need to open an Azure Support request to clarify or request additional region access. Reference: https://learn.microsoft.com/en-us/cli/azure/webapp?view=azure-cli-latest#az-webapp-up https://learn.microsoft.com/en-us/microsoft-365/services/error-request-disallowed-by-policy?view=o365-worldwide Kindly let us know if the above comment helps or you need further assistance on this issue. Please "upvote" if the information helped you. This will help us and others in the community as well.Golla Venkata Pavani •  Follow 565 Reputation points• Microsoft External Staff • Moderator Jan 2, 2026, 6:44 PM Hii @QR, You are seeing the error “RequestDisallowedByAzure” because your subscription has Azure Policies that restrict which regions you are allowed to deploy resources into. This behavior is expected, especially for Azure for Students subscriptions.Azure for Students subscriptions only allow deployments in a small, predefined list of regions, and these allowed regions can vary from one student account to another. If the Azure CLI selects a region that is not permitted, any App Service, Static Web App, VM, or other resource creation will fail with this error. This Happens because:

    • Azure automatically enforces policies such as “Allowed resource deployment regions.”
    • Azure for Students has limited regional availability, so even globally available services may not be allowed for your specific subscription.
    • When you run az webapp up without specifying a region, Azure chooses a default region which may not be allowed for your subscription. Please follow below recommended steps to resolve the issue: 1.You can check the Allowed locations by following below step:
    • Go to Azure Portal > Policy > Assignments > search for Allowed resource deployment regions / Allowed locations > View the list of regions permitted for your subscription.2. 2.Deploy using an allowed region:
      Run the command below, replacing values with your app name, resource group, and an allowed region from your policy list: Azure CLI
    `az webapp up --name`` YourAppName ``--resource-group`` YourResourceGroupName ``--location`` YourPreferredLocation
    `
    

    Some student subscriptions have restrictions where certain services (like App Service or Static Web Apps) are not available in any allowed region. In this case, you may need to open an Azure Support request to clarify or request additional region access. Reference:
    https://learn.microsoft.com/en-us/cli/azure/webapp?view=azure-cli-latest#az-webapp-up
    https://learn.microsoft.com/en-us/microsoft-365/services/error-request-disallowed-by-policy?view=o365-worldwide Kindly let us know if the above comment helps or you need further assistance on this issue. Please "upvote" if the information helped you. This will help us and others in the community as well.

    Was this answer helpful?

    0 comments No comments

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.