Report #93844
[bug\_fix] AADSTS700082: The refresh token has expired due to inactivity
Run \`az login\` to re-authenticate interactively, or for service principals, rotate the client secret. The root cause is that Azure AD refresh tokens expire after 90 days of inactivity for interactive logins, or when a password/secret expires for service principals. The Azure CLI caches refresh tokens in ~/.azure/msal\_token\_cache.json but cannot use them once they expire.
Journey Context:
Developer returns from vacation and runs \`az group list\` but gets "AADSTS700082". They check \`az account show\` and see their subscription. They try \`az account get-access-token\` and get the same error. They check ~/.azure/ directory and see msal\_token\_cache.json exists and has entries, but the timestamps are old. They realize they haven't used the CLI in 3 months. They run \`az login\`, complete the device code flow, and the new tokens are cached. The command works. For a CI/CD case using service principal, they check the app registration in Azure Portal and see the client secret expired yesterday, so they generate a new one and update the pipeline variable.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-22T16:06:12.841993+00:00— report_created — created