Login with Passkeys in a .NET MAUI App
.NET MAUI Preview 7 quietly added a real cross-platform Passkeys API — not a browser wrapper, but a bridge to the native passkey APIs on each platform. Tony Edwards explores what a production implementation actually looks like, from the client call to the security-sensitive server work.
What you’ll learn
- The MAUI surface —
Passkeys.IsSupported,CreateAsync, andAssertAsync, and why the JSON-in/JSON-out design keeps challenges and verification on the server - Registration and authentication flows — the full begin/finish round trips between app, native authenticator, and an ASP.NET Core Identity backend
- Server setup — relying-party ID,
ValidateOriginfor native app origins, and Identity schema version 3 for storing passkeys - Token-based sign-in — using
PerformPasskeyAssertionAsyncto verify without a cookie session and issue your normal access/refresh tokens - Platform association — Apple Associated Domains, Android Digital Asset Links, ceremony state,
PreferImmediatelyAvailable, and handling cancellation cleanly
Read the full ~21 minute walkthrough for the endpoint code, the gotchas, and links to the MAUI sample and backend.