Enable Azure App Service Health Check from Azure CLI

Enable the health check feature via Azure CLI instead of manually through Azure Resource Explorer.

How Health Check Works

Enable Health Check

Set the health check endpoint using az resource update:

az login  # if not already authenticated

az resource update \
  --ids /subscriptions/<SUBSCRIPTION_ID>/resourceGroups/<RESOURCE_GROUP_NAME>/providers/Microsoft.Web/sites/<APP_SERVICE_NAME>/config/web \
  --set properties.healthCheckPath="/health"

To find your resource ID: Navigate to Azure Resource Explorer → Your App Service → config → web.