An Azure service that enables bidirectional communication between internet of things (IoT) devices and applications.
Hello Abdeslem Bouchabane,
Welcome to Microsoft Q&A and Thank you for sharing the error details.
I understand that your student subscription has an Azure Policy in place that restricts which regions you can deploy resources into. The error
What the error means
RequestDisallowedByAzure
indicates that your subscription (likely an Azure free student account) is restricted by an Azure Policy that limits which regions you can deploy resources into.
This is not a credit issue, but a region restriction applied to your subscription.
When you try to create an Azure IoT Hub in a region that is not part of the “Allowed Locations” list, Azure blocks the deployment with this error.
Why this happens
With certain subscription types (such as student/free accounts), Azure enforces policies to:
Allow deployments only in specific approved regions
Ensure service availability and optimal performance
Control usage and costs
Here are the few troubleshooting steps to fix the issue,
- Verify allowed regions in your subscription
In the Azure Portal:
- Go to Policy
- Select Assignments
- Look for a policy like “Allowed Locations”
- Review the list of permitted regions
- Choose a supported region for your IoT Hub
When creating your IoT Hub, select a region from the allowed list, for example:
East US
East US 2
West Europe
North Europe
Southeast Asia
Avoid Regions not included in your policy, Regions not supported by IoT Hub.
- Redeploy the IoT Hub in an allowed region
Azure Portal
when creating the IoT Hub, pick an allowed region in the Region dropdown
Azure CLI example
az iot hub create \
ARM Template
Update the "location" property to one of your allowed regions
The deployment failed due to an Azure Policy restricting regions, not lack of credits
The Azure IoT Hub must be created in an allowed region
Switching to a permitted region should resolve the issue immediately.
Please refer this
iothub-westus3-disabled • ARM template / CLI / SDK IoT Hub reference: https://docs.microsoft.com/azure/templates/microsoft.devices/iothubs?tabs=json
• az iot hub create CLI docs: https://docs.microsoft.com/cli/azure/iot/hub#az-iot-hub-create
I Hope this helps. Do let me know if you have any further queries.
If this answers your query, please do click Accept Answer and Yes for was this answer helpful.
Thank you!