Home › Cloud › AADSTS700016: App Not Found in Directory Tenant
Intermediate 6 min · September 23, 2026

AADSTS700016: App Not Found in Directory Tenant

Fix AADSTS700016 by signing into the right tenant: verify the directory, add the service principal, and configure consent..

N
Naren Founder & Principal Engineer

20+ years shipping production backend systems. Lessons pulled from things that broke in production.

Follow
✓ Production
production tested
September 27, 2026
last updated
2,085
articles · all by Naren
Before you start⏱ 13 min
  • ✓An Azure subscription with access to a Microsoft Entra tenant
  • ✓Azure CLI installed with az login completed
  • ✓Basic familiarity with OAuth2 sign-in flows
 ● Production Incident 🔎 Debug Guide
⚡Quick Answer
  • AADSTS700016 means your app's client ID isn't registered in the tenant that handled the sign-in, so Azure stops before checking secrets
  • You're likely aimed at the wrong directory: run az account show and confirm the tenant ID matches the app registration
  • An app registration alone isn't enough — each sign-in tenant also needs an enterprise app (service principal)
  • For multi-tenant SaaS, set signInAudience to AzureADMultipleOrgs and complete admin consent in each customer tenant
✦ Definition~90s read
What is Azure AADSTS700016?

AADSTS700016 is an error code from Microsoft Entra ID (formerly Azure AD) meaning the application identifier in your sign-in request wasn't found in the directory that processed it. The typical message reads: Application with identifier 'xxx' was not found in the directory 'yyy'.

★
Think of each company Microsoft directory as a separate apartment building with its own front desk.

It fires at the very start of the OAuth2/OIDC flow, when Azure tries to load your app's registration and can't. No tokens are issued, no user is authenticated, and your app's redirect endpoint never gets called back.

Three conditions produce it. First, the authority URL points at the wrong tenant — your app says log in via tenant B while the registration lives in tenant A. Second, the tenant is right but holds no service principal for the app, which happens with guest users, new customer tenants, or after someone deletes the enterprise app.

Third, the app is registered single-tenant (signInAudience AzureADMyOrg) while an account from another tenant attempts sign-in. All three look identical on screen, which is why the error has a reputation for wasting afternoons.

The identity objects matter here. An app object is created once in the home tenant and defines the app globally: its client ID, redirect URIs, API permissions, and signInAudience. A service principal is the per-tenant instance that makes the app usable there — it carries consent grants and conditional-access assignments.

The portal shows service principals under Enterprise applications, a name that confuses everyone exactly once. Deleting the app object kills the app everywhere; deleting one service principal revokes access in that tenant only.

That split turns AADSTS700016 into a checklist: right tenant, right client ID, service principal present, audience correct, consent granted.

Plain-English First

Think of each company Microsoft directory as a separate apartment building with its own front desk. Your app is a visitor with a badge number (the client ID). AADSTS700016 means the visitor arrived at the wrong building: the desk has no record of that badge, so they are turned away. Send them to the right building, register them at that desk (the enterprise app), or issue a multi-building pass (multi-tenant setup). New keys will not help when the building never heard of them.

It's 10 AM on launch day and your first enterprise trial customer can't sign in. They enter their work email, get bounced to Microsoft, and land on a stark error page: AADSTS700016, application not found in the directory. Your team reads it as a credentials problem and burns two hours rotating secrets that were never broken. The customer starts doubting the product before they've seen a single screen of it.

This error is one of the most misread in the Microsoft identity platform. It doesn't mean your code is wrong or your password expired. It means Azure looked for your app's client ID inside a specific tenant directory and found nothing. The app either lives in a different tenant, was never provisioned there as an enterprise app, or was registered as single-tenant while an outsider tried to use it.

The stakes are real because this error almost always appears at the worst moment: customer onboarding, a tenant migration, or the first login after a merger. Every failed attempt erodes trust, and the fix sits with identity configuration that developers rarely touch.

This guide walks you through the three checks that resolve nearly every case: confirming the tenant, confirming the service principal, and confirming the app's audience. You'll get exact CLI commands, a real incident story, and a setup that stops this error from ever paging you again.

What AADSTS700016 Actually Means (and What It Does Not)

AADSTS700016 is Microsoft Entra's way of saying: I looked for this application in the directory that received the request, and it isn't there. The full text reads application with identifier was not found in the directory, followed by the tenant name. Every part of that sentence matters. The identifier is your client ID (app ID). The directory is the specific tenant that handled the sign-in, not some global registry. Not found means exactly that — no app object, no service principal, nothing matching that ID where Azure looked.

What the error doesn't mean is just as important. It doesn't mean the user's password is wrong. It doesn't mean your client secret expired. It doesn't mean your code has a bug in token handling. All of those checks happen later in the pipeline, and Azure never reaches them when the app itself is unknown. Teams routinely waste hours rotating secrets because secret problems feel familiar, while tenant problems feel exotic. Train yourself to read 700016 as a directory problem, not a credential problem.

The error also tells you which tenant answered the request, right in the message text. That tenant name is your first clue. Compare it against the tenant where your app registration lives (visible in the portal's overview blade or via az ad app show). If they differ, you've likely found the whole story: the login flow pointed at a directory that never heard of your app. Common culprits include hardcoding the wrong tenant ID in the authority URL, using common when you meant a specific tenant, or testing with a personal account against a work-only app.

📊 Production Insight
In production this error spikes during tenant migrations and mergers, when users authenticate from a new directory nobody told engineering about. One team saw hundreds of 700016s the Monday after an acquisition closed. Their monitor on sign-in error codes caught it in minutes; without that alert they'd have learned about it from support tickets days later.
🎯 Key Takeaway
Read AADSTS700016 as app unknown in this directory, then compare the tenant in the message against your registration's tenant.

Wrong Tenant, Wrong Directory: Confirming Where You Signed In

The authority URL in your auth configuration decides which tenant handles the login, and getting it wrong is the top cause of AADSTS700016. An authority like https://login.microsoftonline.com/common lets users from any tenant sign in, which is convenient but hides exactly which directory answered. A tenant-specific authority like https://login.microsoftonline.com/aaaabbbb-cccc-tenant-id pins the login to one directory. If that ID is stale — copied from the wrong subscription, left over from a deleted directory, or swapped between staging and production — every login fails with 700016 even though your app registration is perfectly healthy.

Start every investigation by printing the effective tenant on both sides. On the CLI side, az account show --query tenantId reveals which directory your session targets, and az account list shows every directory your account can reach. On the app side, open the registration's overview blade or run the Graph query in the snippet below. If those two tenant IDs don't match, stop debugging code — fix the authority string in your config, environment variable, or appsettings file first.

Directory switching adds another wrinkle. A single Microsoft account can belong to several tenants, and the portal header shows only the current one. Developers often create the registration in tenant A, then run the CLI or open the enterprise-apps blade while switched to tenant B, and conclude the app doesn't exist. It does exist — they're just looking at the wrong building's front desk. Get in the habit of echoing the tenant ID at the top of every debug session so the whole team sees the same directory.

check-tenant.shBASH
1
2
3
4
5
6
7
8
9
10
11
# Which tenant is this session actually using?
az account show --query "{tenant:tenantId, subscription:name}" -o table

# List every directory your account can reach
az account list --query "[].{tenant:tenantId, name:name}" -o table

# Switch to the tenant that holds the app registration
az login --tenant aaaabbbb-0000-1111-2222-333344445555

# Compare with the registration audience setting
az ad app show --id <APP_CLIENT_ID> --query "{appId:appId, audience:signInAudience}" -o json
📊 Production Insight
Production configs drift: staging points at the dev tenant, production points at staging's tenant, and nobody notices until a deploy. One team now asserts tenant ID equality in their release pipeline — the deploy fails if the authority tenant doesn't match the registration's tenant. That single check killed an entire class of Monday-morning auth outages.
🎯 Key Takeaway
Print the tenant on both sides first: CLI session vs app registration. Mismatched tenants explain most 700016s.

App Registration vs Enterprise App: the Missing Service Principal

Azure's identity model splits every app into two objects, and AADSTS700016 lives in the gap between them. The app object lives in exactly one tenant — the home tenant where someone clicked New registration. The service principal (shown in the portal as an enterprise app) is the local instance inside each tenant where people actually sign in. Your home tenant gets one automatically; every other tenant needs its own, created the first time an admin consents or runs the creation command. Without that local instance, Azure has nowhere to attach permissions, consent grants, or conditional access — so it rejects the login outright.

This is why the classic symptom pattern exists: the developer who created the registration can sign in, but nobody else can. The developer's account lives in the home tenant where the service principal exists. Everyone else authenticates from a tenant with no record of the app. The error message doesn't explain any of this; it just says not found, which sends teams hunting for typos in the client ID.

The fix is mechanical. List service principals in the failing tenant with the filter query below. If it's empty, create the service principal and grant consent. For multi-tenant SaaS this happens once per customer tenant during onboarding — automate it rather than treating it as a one-off favor. And remember that deleting an enterprise app revokes everyone's access in that tenant instantly, which makes it both a useful kill-switch and a dangerous button to click during cleanup.

check-service-principal.shBASH
1
2
3
4
5
6
7
8
# Does the failing tenant hold an enterprise app for this client ID?
az ad sp list --filter "appId eq '<APP_CLIENT_ID>'" --query "[].{name:displayName}" -o table

# Empty result? Create the service principal, then retry sign-in
az ad sp create --id <APP_CLIENT_ID>

# Confirm it now exists before changing anything else
az ad sp list --filter "appId eq '<APP_CLIENT_ID>'" --query "[].{name:displayName}" -o table
📊 Production Insight
A cleanup script once deleted stale enterprise apps and took down a paying customer's SSO for an hour — the app looked unused because its sign-ins came from a different tenant's logs. The team now tags service principals with owner and customer metadata, and the cleanup script refuses to touch anything with an active consent grant.
🎯 Key Takeaway
App object defines the app once; a service principal must exist in every tenant whose users sign in.

If your product serves more than one company, the app must be multi-tenant — and that means two settings have to agree. First, signInAudience in the app manifest must be AzureADMultipleOrgs (or AzureADandPersonalMicrosoftAccount for consumer scenarios). The default AzureADMyOrg restricts sign-in to the home tenant only, which produces AADSTS700016 for every external user no matter how perfect the rest of the setup is. Second, each customer tenant needs its service principal plus an admin consent grant, because most enterprise tenants disable user self-consent.

The consent flow is where trials go to die quietly. Your app redirects the user to Microsoft, Microsoft notices the tenant hasn't approved the requested permissions, and the login fails. The remedy is the admin consent endpoint: https://login.microsoftonline.com/customer-tenant-id/adminconsent?client_id=your-app-id, opened by someone with admin rights in the customer tenant. Approving it creates the service principal and records the grants in one step. Send this link to the customer's IT contact before kickoff day, not after the failure.

Verify the audience value in automation, not by memory. The snippet below shows how to read and set it from the CLI. Add that read to your deployment checks so a well-meaning portal edit can't silently flip a SaaS app back to single-tenant. Also decide your personal-account policy deliberately: allowing personal Microsoft accounts widens the door to account types you may not want in an enterprise product.

set-multitenant-audience.shBASH
1
2
3
4
5
6
7
8
9
10
11
# Read the audience: AzureADMyOrg rejects every outside tenant
az ad app show --id <APP_CLIENT_ID> --query signInAudience -o tsv

# Convert a SaaS app to multi-tenant
az ad app update --id <APP_CLIENT_ID> --sign-in-audience AzureADMultipleOrgs

# Admin consent URL: a tenant admin opens this once per customer tenant
echo "https://login.microsoftonline.com/<TENANT_ID>/adminconsent?client_id=<APP_CLIENT_ID>"

# Verify the audience change landed
az ad app show --id <APP_CLIENT_ID> --query signInAudience -o tsv
⚠ Don't Convert Tenancy Without a Test Tenant
Never flip a live single-tenant app to multi-tenant on a Friday afternoon. The change alters who can sign in and which consent flows trigger — test it with a second tenant first, confirm existing users keep working, then roll it out on a normal weekday.
📊 Production Insight
One vendor converted to multi-tenant during a live trial and locked out the customer's existing users for 40 minutes because the consent grants didn't carry over the way they expected. They now rehearse tenancy changes against a spare tenant that mirrors the customer's conditional-access policies before touching production.
🎯 Key Takeaway
Multi-tenant SaaS needs AzureADMultipleOrgs plus per-tenant consent; verify both in your pipeline.

Diagnosing With Sign-In Logs and Audit Trails in Production

When the basics look right but logins still fail, the sign-in logs tell the truth. Microsoft Entra records every authentication attempt — successes, failures, error codes, tenant IDs, conditional-access results — in the sign-in log stream. Filter by your app's client ID around the failure timestamp and you'll see exactly which tenant handled the request, which error code Azure returned, and whether a policy interfered. This beats guessing from the app side, because your app never sees the requests that die at Microsoft's endpoint.

In production, export these logs instead of clicking through the portal. Stream sign-in and audit logs to Log Analytics with a diagnostic setting, then query for error 700016 grouped by tenant and app. A sudden spike from a new tenant name means someone new tried to onboard (or an attacker is spraying client IDs). A steady trickle from a known tenant means a config drifted — often a redirect URI or a rotated certificate that broke a downstream step after the directory lookup succeeded.

Keep the retention window in mind: interactive sign-in logs age out after 30 days by default, so export anything you'll need for a postmortem. Correlate each log row with your app's own callback logs by timestamp and state parameter. If Microsoft logged a failure and your app logged nothing, the request died before redirect — a directory problem. If both sides logged something, you're past 700016 territory and into token or consent errors, which is genuine progress.

query-signin-logs.shBASH
1
2
3
4
5
# Pull the latest sign-in failures for this app via Microsoft Graph
az rest --method get --url "https://graph.microsoft.com/v1.0/auditLogs/signIns?$filter=appId eq '<APP_CLIENT_ID>'&$top=10" --query "value[].{user:userPrincipalName, code:status.errorCode}" -o table

# Watch subscription activity around the failure window
az monitor activity-log list --offset 1h --query "[].{time:eventTimestamp, op:operationName.value, status:status.value}" -o table
📊 Production Insight
A team added a 15-minute alert on 700016 counts per tenant and caught a broken onboarding email template the same afternoon it shipped — the template linked to the wrong tenant's consent URL. The alert fired before the customer even replied to the email. Identity error budgets work just like availability budgets.
🎯 Key Takeaway
Filter sign-in logs by client ID to see the real tenant and error; export them so spikes page you.

Hardening Auth Config So This Never Pages You Again

Once the immediate fire is out, harden the setup so this class of error can't recur silently. Store the tenant ID next to the client ID in every environment's configuration and validate the pair at application startup: if the authority tenant doesn't match the expected registration tenant, fail fast with a message naming both values. A loud startup crash beats a quiet trickle of failed customer logins every time.

Separate your registrations by environment. A single app registration shared across dev, staging, and production guarantees eventual cross-wiring, because redirect URIs and tenant IDs leak between slots. One registration per environment costs nothing and lets you grant consent, rotate secrets, and test tenancy changes without touching production. Name them unambiguously — myapp-prod, myapp-staging — so nobody picks the wrong client ID from a dropdown at midnight.

Finally, put identity checks in the pipeline. Assert signInAudience equals the expected value, assert a service principal exists in each target tenant, and assert the admin consent grants are present. Run these checks on every deploy and on a nightly schedule, because portal edits and customer IT changes drift outside your release process. Identity configuration is production infrastructure — review it, test it, and monitor it like everything else you'd get paged for.

📊 Production Insight
Nightly identity checks once caught a customer IT admin removing a consent grant during a permissions audit — sign-ins would have failed Monday morning. Because the check failed Sunday night, the team re-requested consent with a polite explanation before any user noticed. Monitoring config you don't own is part of running SaaS auth.
🎯 Key Takeaway
Validate tenant, audience, and consent in the pipeline and at startup; one registration per environment.
● Production incidentPOST-MORTEMseverity: high

The Trial-Day Login Failure That Was Never a Secret Problem

Symptom
Every user at the trial customer hit the Microsoft error page with AADSTS700016 the moment they were redirected back from login. The startup's own accounts signed in fine. No application logs showed anything useful because the failure happened at Microsoft's login endpoint, before control ever returned to the app.
Assumption
The team assumed the trial customer's Azure AD was misconfigured or blocking the app, so they asked the customer to check firewall rules and conditional access. Then they assumed the client secret had expired, rotated it twice, and redeployed. Each guess cost a day because every test required the customer's IT admin to reproduce the login on a screenshare.
Root cause
The app registration used signInAudience AzureADMyOrg (single-tenant), so it only accepted accounts from the startup's own directory. The trial customer signed in from their company's tenant, where no service principal for the app existed. Azure couldn't find the client ID in that directory and returned AADSTS700016 before ever validating credentials.
Fix
The fix had two parts. First, the app registration's signInAudience was changed from AzureADMyOrg to AzureADMultipleOrgs so outside tenants were accepted. Second, the customer's tenant admin opened the /adminconsent URL for the app's client ID, which created the enterprise app (service principal) in the customer tenant and recorded the permission grants. Sign-in worked on the next attempt. The team also added the consent URL to their onboarding email template so future trials complete it before kickoff day.
Key lesson
  • Don't let developers debug identity errors by rotating secrets first. AADSTS700016 fires before secrets are even checked, so every rotation is wasted time that burns customer trust during onboarding.
  • Single-tenant is the wrong default for any SaaS product. If more than one company will ever sign in, ship multi-tenant from day one — converting later means re-testing every auth flow under deadline pressure.
  • Make admin consent a visible onboarding step with a link, an owner, and a verification check. Silent consent failures in locked-down tenants look exactly like broken software to the customer.
Production debug guideFive checks, in order, that isolate the tenant, the registration, and the consent state.5 entries
Symptom · 01
You don't actually know which tenant the failing sign-in hit
→
Fix
Run az account show --query "{tenant:tenantId, sub:name}" -o table to see the tenant your session uses. Then run az account list -o table to list every directory you can reach. If the tenant in your app's authority URL isn't the one holding the registration, you've found the bug — fix the authority or switch directories.
Symptom · 02
The client ID might be wrong or the app's audience too narrow
→
Fix
Run az ad app show --id <APP_CLIENT_ID> --query "{appId:appId, audience:signInAudience}" -o json. If the command fails, the client ID is wrong or you lack Graph permissions. If signInAudience is AzureADMyOrg, the app is single-tenant and every outside account will keep failing until you change the audience.
Symptom · 03
App registration exists, yet users in another tenant still fail
→
Fix
Run az ad sp list --filter "appId eq '<APP_CLIENT_ID>'" --query "[].{name:displayName}" -o table inside the failing tenant. Empty output means no enterprise app exists there. Create it with az ad sp create --id <APP_CLIENT_ID>, then retry sign-in before changing anything else.
Symptom · 04
The common endpoint hides which tenant handled the request
→
Fix
Stop using common while debugging and switch to https://login.microsoftonline.com/<TENANT_ID> with the explicit tenant. Reproduce the login, then query sign-in logs: az rest --method get --url "https://graph.microsoft.com/v1.0/auditLogs/signIns?$filter=appId eq '<APP_CLIENT_ID>'". The log row shows the exact tenant and error the app hit.
Symptom · 05
Everything looks right but locked-down tenants still reject sign-in
→
Fix
Have a tenant admin open https://login.microsoftonline.com/<TENANT_ID>/adminconsent?client_id=<APP_CLIENT_ID> and approve the permissions. Then verify with az ad sp show --id <OBJECT_ID> --query "oauth2PermissionGrants" or the enterprise app's permissions blade. Retry sign-in only after the grants are visible.
AADSTS700016 Root Causes Compared
Root CauseHow to ConfirmFixPrevention
Wrong tenant in the authority URLRun az account show --query tenantId -o tsv and compare with the registration's tenant; sign-in logs show an unknown client IDPoint the authority at the registration's tenant or switch directories before signing inStore tenant ID with the client ID in config; assert they match at startup
No service principal in the sign-in tenantaz ad sp list --filter "appId eq '<ID>'" returns empty in the user's tenantRun az ad sp create --id <ID> in that tenant, then retry sign-inAutomate service principal creation as part of tenant onboarding
Single-tenant app used from another tenantaz ad app show --id <ID> --query signInAudience returns AzureADMyOrgSet signInAudience to AzureADMultipleOrgs and publish the multi-tenant appDefault new SaaS registrations to multi-tenant; review audience in code review
Admin consent never grantedEnterprise app shows zero granted permissions; users get consent errorsComplete the /adminconsent flow with a tenant admin and verify permissionsMake admin consent a checklist item in customer onboarding runbooks
⚙ Quick Reference
4 commands from this guide
FileCommand / CodePurpose
check-tenant.shaz account show --query "{tenant:tenantId, subscription:name}" -o tableWrong Tenant, Wrong Directory
check-service-principal.shaz ad sp list --filter "appId eq '<APP_CLIENT_ID>'" --query "[].{name:displayNam...App Registration vs Enterprise App
set-multitenant-audience.shaz ad app show --id <APP_CLIENT_ID> --query signInAudience -o tsvMulti-Tenant Setup
query-signin-logs.shaz rest --method get --url "https://graph.microsoft.com/v1.0/auditLogs/signIns?$...Diagnosing With Sign-In Logs and Audit Trails in Production

Key takeaways

1
AADSTS700016 means the client ID isn't registered in the tenant that handled sign-in
check tenant first, not secrets.
2
An app registration alone isn't enough
each sign-in tenant needs an enterprise app (service principal).
3
Single-tenant apps reject every outside account; SaaS apps must use AzureADMultipleOrgs plus admin consent.
4
Run az account show and az ad sp list before touching code
the answer is usually in those two outputs.
5
Make admin consent a documented onboarding step, verified in the enterprise app's permissions blade.
6
Alert on 700016 spikes in sign-in logs so broken onboarding pages you instead of waiting for tickets.

Common mistakes to avoid

5 patterns
×

Assuming the client secret is wrong when the tenant is wrong

Symptom
You rotate the client secret twice, update Key Vault, redeploy, and the same AADSTS700016 comes back word for word. Nothing about the secret ever mattered because Azure never got far enough to check it.
Fix
Check the tenant in your authority URL first. Run az account show --query tenantId -o tsv and compare it with the tenant where the app registration lives. If they differ, sign in against the right tenant or switch directories in the portal before changing any code.
×

Creating the app registration but never creating the service principal

Symptom
Sign-in works for the developer who created the registration but fails for every other user with AADSTS700016. The app object exists in exactly one tenant while the users authenticate somewhere else.
Fix
After creating the app registration, create the service principal in every tenant that must sign in: az ad sp create --id <APP_CLIENT_ID>. Then confirm with az ad sp list --filter "appId eq '<APP_CLIENT_ID>'". No service principal means no sign-in, every time.
×

Leaving a SaaS app as single-tenant while selling to other tenants

Symptom
Your tenant's users sign in fine, but the first external customer gets AADSTS700016 on day one of the trial. The deal stalls while your team debates whether it's a customer firewall issue. It isn't.
Fix
Set signInAudience to AzureADMultipleOrgs (or AzureADandPersonalMicrosoftAccount if you truly need personal accounts) via the manifest or az ad app update --id <ID> --sign-in-audience AzureADMultipleOrgs. Then complete admin consent in each customer tenant with the /adminconsent endpoint.
×

Registering a redirect URI that doesn't match the running app

Symptom
After you fix AADSTS700016 you immediately hit AADSTS50011 (reply URL mismatch). The login loop bounces between your app and Microsoft, and users can't complete sign-in from staging or preview deployments.
Fix
Open the app's Authentication blade and register every redirect URI exactly as your code sends it, including scheme, host, port, path, and trailing slash. Keep localhost and production URIs in separate registrations when you can.
×

Skipping admin consent and hoping users can consent themselves

Symptom
Users see AADSTS90094 (admin consent required) or fall back to AADSTS700016 in locked-down tenants. Most enterprise tenants disable user consent, so self-service consent silently fails for exactly the customers you care about.
Fix
Grant admin consent through the tenant admin account using https://login.microsoftonline.com/<TENANT_ID>/adminconsent?client_id=<APP_CLIENT_ID>, then verify the enterprise app shows the granted permissions. Document consent as a required onboarding step, not an optional one.
INTERVIEW PREP · PRACTICE MODE

Interview Questions on This Topic

Q01JUNIOR
What does AADSTS700016 mean, and what are its three most common causes?
Q02SENIOR
Explain app objects vs service principals. How do you check for a missin...
Q03SENIOR
Single-tenant vs multi-tenant apps: what changes for AADSTS700016?
Q04SENIOR
How would you diagnose AADSTS700016 with sign-in logs in production?
Q05SENIOR
How do you prevent AADSTS700016 from recurring across environments?
Q01 of 05JUNIOR

What does AADSTS700016 mean, and what are its three most common causes?

ANSWER
It means the application with the given client ID wasn't found in the directory that handled the request. The usual causes are signing into the wrong tenant, a missing service principal in that tenant, or a single-tenant app being used from another tenant. You confirm it by comparing the authority's tenant against the registration and checking for the service principal.
FAQ · 6 QUESTIONS

Frequently Asked Questions

01
Will rotating the client secret fix AADSTS700016?
02
What's the difference between an app registration and an enterprise app?
03
How do I make my app work for customers in other tenants?
04
How do I tell which tenant my sign-in actually hit?
05
How does admin consent fix sign-in for a whole tenant?
06
Is AADSTS700016 the same as AADSTS50011 (reply URL mismatch)?
N
Naren Founder & Principal Engineer

20+ years shipping production backend systems. Lessons pulled from things that broke in production.

Follow
✓ Verified
production tested
September 27, 2026
last updated
2,085
articles · all by Naren
🔥

That's Azure. Mark it forged?

6 min read · try the examples if you haven't

←
Previous
Terraform count vs for_each: Why Index Shifts Destroy Resources
1 / 4 · Azure
Next
Azure App Service 502.5 Process Failure
→