Azure: managed identity vs service principal for a web app

asked 8 days ago241 viewsen

3

My App Service needs to read from Key Vault and a Storage Account. When should I use a system-assigned managed identity versus a registered service principal?

🤖 AI diagnosis

AI-generated. Not an answer — the community below confirms or corrects it. Always verify before relying on it.

asked 8 days ago
  • Thanks, this helped. Did you also try clearing the cache?

    fabiennedorval 5 days ago

1 Answer

4

Prefer a system-assigned managed identity — no secrets to rotate, lifecycle tied to the resource. Use a service principal only when the identity must be shared across resources or used from outside Azure.

Sign in to tell others whether this worked.

answered 8 days ago

Sign in and verify your email to post an answer.