Azure Function App Error: We are not able to retrieve the runtime master key


When you access an Azure Function app from the portal it will attempt to retrieve the Function runtime keys.  This is documented at .  There are a number of reasons why the keys cannot be retrieved and this article documents a recent change that means you may see this issue.

Possible errors

"We are not able to retrieve the runtime master key. Please try again later"


"We are not able to retrieve the keys for function .....This can happen if the runtime is not able to load your function app"


"We are not able to create or update the key default for function ......"

Possible solutions

The Azure Function runtime has been updated to include Application Insights support. This was previously offered in the beta runtime which you accessed by setting your Functions Runtime version to “beta”.  Some of these problems are related to the fact that beta is no longer usable.  Ensure you are not on beta.

These are a few solutions.

1) You are on the beta. At this point, the beta is no longer usable, and you need to switch the app setting back to ~1.


2) If you're not on the beta and are still seeing this, try Stopping and then Starting your Function App

3) if neither of those work make sure you are using the latest version of the runtime:

This link helps run through it but make sure you are using this commit in particular:

NOTE: that using a private site extension is by nature unsupported. Once you move to that mode, you are responsible for keeping it updated as the product evolves. Just merge the latest bits and redeploy, and you'll be ok.

4)  App has a runtime error (check Failed Request Tracing for errors)

5)  App has exhausted some resource such as threads, cpu, memory etc…  (Typically deadlocked functions due to waiting on async tasks using .Result)

6)  Web browser is caching an old result (clear the browser cache, log out and back in).

7)  You regenerated the keys but did not set them in the app settings:

8) host.json is not properly formatted json or invalid




This is just a simple quick post that hopefully will set you in the right direction!  Drop me a note if this was helpful to you.  Thanks to Tyler Spring from my team for surfacing these issues and helping with the post.

For more assistance please jump on to the github issues, or functions forums and StackOverflow.