M365Con 2027 – free online conference · 11–22 Jan 2027 · 120 sessions→ m365con.net

Blog · Mirko Peters

Understanding the AADSTS50011 Redirect URI Mismatch Error

By · · Updated

AADSTS50011 redirect URI mismatch means the redirect URI sent by an application does not exactly match a URI registered in Microsoft Entra ID. Compare the applicati…

Cover: Stop OAuth Consent Attacks in Microsoft Entra ID

AADSTS50011 redirect URI mismatch means the redirect URI sent by an application does not exactly match a URI registered in Microsoft Entra ID. Compare the application’s request with the registered redirect URI, including scheme, hostname, path, port, and trailing slash. Correct the application or registration, then retest the intended sign-in flow.

Fix AADSTS50011 redirect URI mismatch

  1. Copy the redirect URI from the error or sign-in request.
  2. Compare it exactly with the Entra app registration.
  3. Correct the approved URI and retest in the appropriate environment.

See Microsoft Learn for Entra.

If you’ve ever tried setting up Microsoft authentication and hit a roadblock, chances are the AADSTS50011 redirect URI mismatch error popped up like an uninvited guest. This error is infamous among developers and admins working with Microsoft Entra ID (formerly Azure Active Directory), Microsoft 365, and integrations in Azure or Power Platform.

Why does it matter? This glitch can bring your login flows to a screeching halt, leaving users unable to sign in and applications stuck outside the gates. Redirect URI mismatches are a common trap that snags both new projects and changes to existing setups. Getting to grips with what triggers AADSTS50011—and knowing how to fix it—not only keeps your apps running smoothly, it’s critical for securing authentication and authorization with Microsoft’s platforms.

In this guide, you’ll see what causes the error, how to spot its symptoms, and get practical tips for finding and fixing those mismatched redirect URIs. Even if you’re brand new to Microsoft authentication, you’ll walk away ready to troubleshoot and lock down your sign-in flows the right way.

What Is Causing the AADSTS50011 Error?

The root cause of the AADSTS50011 error is a mismatch between the redirect URI used by your application and the list of URIs registered within Microsoft Entra ID. When someone tries to sign in, Microsoft’s authentication system checks that the redirect URI sent in the OAuth or OpenID Connect request exactly matches one on file for the app registration.

This strict security check prevents unauthorized endpoints from intercepting user tokens—a cornerstone of modern identity protection. If there’s any difference—even a stray slash, the wrong protocol (like http instead of https), or a typo—Entra ID instantly blocks the sign-in and throws the AADSTS50011 error. Understanding this safeguard helps you not only resolve errors faster, but also avoid risky misconfigurations going forward.

Problem Symptoms and Error Messages to Watch For

Fixing the Redirect URI for Resolution of AADSTS50011

The good news is, resolving AADSTS50011 is usually a matter of detective work and careful double-checking—no magic required. At a high level, you’ll need to bring the redirect URI used by your application into exact alignment with those registered in the Azure portal under your app registration. Even tiny differences in protocol, spelling, or slashes can cause the mismatch, so attention to detail is the name of the game.

Fixing this isn’t only about stopping errors. Keeping your redirect URIs straight is essential for Microsoft authentication security. Entra ID expects precision to prevent attackers from intercepting tokens or exploiting weak points in your login flow. That’s why you want to be extra careful when adding or editing URIs, and why it pays to review them any time you change environments or hostnames.

Behind the scenes, Microsoft insists that the redirect URI sent on a login attempt matches exactly what’s listed for your application. This matching goes all the way down to casing, trailing slashes, and the use of HTTPS—which keeps you, your users, and your organization safe from redirect attacks. With multiple devices, code changes, and environments in play, it’s easy for mismatches to sneak in, but a solid process for registering and reviewing URIs means you’ll rarely see this error again.

If you're interested in tightening your security measures even further—especially against OAuth consent attacks—explore resources like this detailed guide on OAuth consent abuse and Entra ID controls. Staying ahead of both configuration snafus and evolving threats makes for a more resilient authentication setup.

Common Causes Behind Redirect URI AADSTS50011 Errors

How to Register and Verify Redirect URIs in the Azure Portal

More Information, Resources, and Community Feedback

Wrapping up the redirect URI mismatch struggle? Good news—you don’t have to wing it alone. Microsoft delivers a mountain of documentation and useful references to keep you out of trouble next time. If you’re looking for the nitty-gritty details, start with their official error code docs for authentication and authorization issues in Entra ID (formerly Azure AD). These guides walk you through common missteps and how to undo them, plus they offer code samples for all you tinkerers.

Of course, sometimes docs don’t hit the weird edge cases. That’s where community forums become your lifeline. Microsoft Q&A, Stack Overflow, and feedback threads are packed with real war stories from folks who have wrestled—and pinned—the dreaded AADSTS50011. Jump in with your symptoms, or scroll through solved threads and see if your fix is hiding in plain sight. It’s like having a whole support group dedicated to your headaches.

For more on keeping your apps—and your organization—safe and sane, check out the bigger picture around cloud governance and identity security. Want to keep policy drift and configuration chaos at bay? Dip into this primer on Azure enterprise governance strategy. Want the lowdown on airtight identity practices? This discussion about reducing identity risk with Entra ID conditional access is for you.

If you found this helpful, or ran into something unusual, share your feedback or drop your workaround in the comments. The more you contribute, the easier it is for the next engineer to escape the redirect URI quicksand. Who knows—your insight might be the missing puzzle piece for someone else tomorrow.

🎧 You Should Also Listen To

Microsoft Entra ID Microsoft Entra Microsoft 365 Power Platform Microsoft

RSS