To stop charges and fully remove Azure Foundry resources, both the Foundry project/hub and the underlying Azure resources must be deleted. Deletion behavior differs between classic hubs and the new Foundry experience.
- Identify whether this is a classic Foundry hub or a new Foundry project/resource
- Classic: Managed as a Foundry hub.
- New: Managed as a Foundry project under a Microsoft Foundry Azure resource.
- If using a classic Foundry hub
- In Foundry, select the hub.
- In Hub properties, select Delete hub.
- This deletes the hub and all associated projects and nested endpoints.
- Optionally delete connected resources, but only if no other applications use them.
- After deleting the hub, check the resource group in the Azure portal for remaining resources that can still accrue costs (for example: Azure Container Registry, Azure Blob Storage, Key Vault, Application Insights) and delete them if they are no longer needed.
- If using the new Foundry projects
- Delete projects in the Foundry portal:
- Go to Microsoft Foundry with New Foundry enabled.
- Select Operate → Admin.
- Select each project and use the trash can icon to delete it.
- Note: Projects do not support soft delete and cannot be recovered after deletion.
- Optionally delete projects via Azure CLI or Python SDK if portal deletion fails:
- Azure CLI example:
az cognitiveservices account project delete \
--name <foundry-resource-name> \
--resource-group <resource-group-name> \
--project-name <project-name>
- Python SDK example (loop through and delete all projects, then delete the Foundry resource):
projects = client.projects.list(resource_group_name, foundry_resource_name)
for project in projects:
print("Deleting project:", project.name)
client.projects.begin_delete(
resource_group_name,
foundry_resource_name,
project_name=project.name.split('/')[-1]
).wait()
print("Deleting resource:", foundry_resource_name)
client.accounts.begin_delete(resource_group_name, foundry_resource_name).wait()
- Delete the Foundry Azure resource or entire resource group
- In the Azure portal:
- Go to Resource groups.
- Open the resource group that contains the Microsoft Foundry resource.
- Either:
- Delete the entire resource group (removes all contained resources), or
- Select only the Foundry resource and delete it.
- Ensure no dependent resources continue to accrue costs
- Even after deleting Foundry hubs/projects, some Azure resources can remain and continue billing (for example: Storage accounts, Key Vault, Container Registry, Application Insights, VMs, load balancers, virtual networks, bandwidth, PTU-based deployments).
- For PTU-based Azure OpenAI/Foundry deployments:
- Delete the PTU deployments in the Foundry portal first.
- Then delete and purge the Azure AI resource so that charges stop.
- Manage or cancel reservations from the Reservations page in the Azure portal if needed.
- Recovery and soft delete considerations
- Foundry projects do not support soft delete and cannot be recovered once deleted.
- Some underlying services (for example, Azure Storage, Key Vault) may have soft delete enabled; these can be recovered separately if needed.
If deletion still fails after these steps, check for:
- Remaining deployments or endpoints under the project/hub.
- Other applications using shared resources in the same resource group.
- Resource locks or RBAC restrictions on the resource group or individual resources.
References: