When your Azure Functions app shows a “runtime is unreachable” error, it means the Functions host cannot access the Azure Storage account it needs for internal bookkeeping. This guide explains the storage and networking causes behind that error and walks you through the fixes that restore normal operation.
What the Runtime Actually Needs from Storage
The Azure Functions runtime uses an Azure Storage account for several critical tasks, not just for your function’s data. It stores the function code in a container called azure-webjobs-hosts, keeps lease blobs for singleton coordination, and writes diagnostic logs to a queue. If the host cannot reach this storage account, it cannot start or stay healthy, and the portal shows the unreachable error.
Three storage services are involved:
- Blob storage — holds the host’s configuration and the function code package.
- Queue storage — used for internal coordination messages.
- Table storage — stores execution history and other metadata.
The connection string or the managed identity used to access these services is defined in the AzureWebJobsStorage application setting. If that setting is missing, empty, or points to a storage account that is not reachable from the function app’s network, the runtime cannot start.
Networking: The Most Common Culprit
In many real-world cases, the storage account is perfectly healthy, but the function app cannot reach it because of network restrictions. This happens when you enable any of these features on the storage account:
- Firewall — the storage account only allows traffic from specific IP ranges or virtual networks.
- Private endpoint — the storage account is attached to a virtual network and no longer has public access.
- Service endpoint — similar to a private endpoint but uses the service’s public IP space.
If your function app is not in the same virtual network (or is not allowed by the firewall rules), it cannot reach the storage account. The portal error “Azure Functions runtime is unreachable” is the symptom, but the root cause is often a network path that is blocked.
Diagnosing the Exact Cause
Before changing anything, confirm that the storage account is actually reachable from the function app. You can do this with the Kudu console (available at https://<your-app>.scm.azurewebsites.net) or with the Azure CLI.
- Open the Kudu console and navigate to
Debug console → CMD. - Run
nslookup <storage-account>.blob.core.windows.netto see if DNS resolves. - Run
curl https://<storage-account>.blob.core.windows.net/?comp=list— a successful response (even an error likeAuthenticationFailed) means the network path is open. - If the curl command times out or returns a connection error, the network is blocked.
Also check the function app’s AzureWebJobsStorage setting. In the portal, go to Configuration → Application settings and verify the value is a full connection string (starting with DefaultEndpointsProtocol=) or a managed identity configuration. If it is empty or malformed, the runtime cannot connect.
Fixing the Most Common Scenarios
Once you know the cause, the fix is usually one of these:
- Storage firewall is too restrictive — add the function app’s outbound IP addresses to the storage account’s firewall allow list. You can find these IPs in the function app’s Properties blade under “Outbound IP Addresses”.
- Storage uses a private endpoint — either place the function app in the same virtual network and subnet as the private endpoint, or use a virtual network integration on the function app so it can route to the private endpoint.
- Storage is behind a service endpoint — similar to the private endpoint, the function app must be in the same virtual network and the service endpoint must be enabled on the subnet.
- Storage connection string is wrong — regenerate the key from the storage account and update the application setting.
If you are using a managed identity (system-assigned or user-assigned), ensure the identity has the Storage Blob Data Contributor, Storage Queue Data Contributor, and Storage Table Data Contributor roles on the storage account.
Common Misconception: It’s Always a Storage Key Problem
Many people assume the error means the storage key is invalid or expired. While that is possible, it is far more common that the network path is blocked. A quick way to distinguish: if the key were wrong, you would see an authentication error (HTTP 403) in the logs, not a timeout or connection refused. If the portal shows “runtime is unreachable” and you cannot reach the storage endpoint from Kudu, it is a networking issue, not a key issue.
When the Storage Account Is in a Different Region
Azure Functions does not require the storage account to be in the same region, but latency and network egress costs increase. More importantly, if the storage account is in a region with different compliance or availability requirements, you may need to adjust your disaster recovery plan. The runtime itself works fine across regions as long as the network path is open.
Frequently Asked Questions
Why does the runtime become unreachable after I enable a private endpoint on the storage account?
When you enable a private endpoint, the storage account’s public endpoint is typically disabled. The function app, unless it is in the same virtual network, can no longer resolve or reach the storage account. You need to integrate the function app with that virtual network (using regional virtual network integration) so it can route through the private endpoint.
Can I use a different storage account than the one in the connection string?
Yes, you can change the AzureWebJobsStorage setting to point to any storage account that meets the requirements. However, the new account must be accessible from the function app’s network and the appropriate roles must be granted if using managed identity.
Does the storage account need to be in the same resource group?
No, the storage account can be in a different resource group or even a different subscription, as long as the function app has network access and the connection string or identity is valid.
What if I see the error only after deploying a new function?
This often happens when the deployment process tries to write to the storage account but the network path is blocked. Check the deployment logs for errors related to storage. Also, ensure the function app’s staging slot (if used) has its own storage settings.
Is it safe to disable the storage firewall temporarily?
It is safe for a short time to confirm the diagnosis, but you should re-enable it and then whitelist the function app’s outbound IPs or use a private endpoint. Leaving the firewall off exposes your storage account to the internet, which increases the risk of unauthorized access.
Related
Method: the standard formula for this calculation, rounded as each result states. See how the calculators work or report an error.
More cards in this drawer
- Philips DST7060/20 7000 Series Iron: Specs & Fit
- Coal Fueled Jet Aircraft: Could It Work?675 L
- Remote Desktop on Raspberry Pi: How to Enable It
- Word Select Last Line in Paragraph?
- Google Assistant IFTTT Recipes: 7 Useful Automations
- OLED TVs in Dark Rooms: Why They Look Better and When They Don’t