> ## Documentation Index
> Fetch the complete documentation index at: https://docs.meru.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Passkeys

> Native Face ID / Touch ID / fingerprint sign-in, with the domain setup each platform requires.

Each SDK uses the platform's own passkey system — **no extra install**:

* **Web** — WebAuthn.
* **React Native / Flutter** — the passkey native module ships **inside** the SDK.
* **iOS** — `ASAuthorization` (system UI).
* **Android** — Credential Manager (system UI).

## Enable & sign in

<CodeGroup>
  ```ts React Native theme={null}
  await auth.enablePasskey();               // turn on for the signed-in user
  const session = await auth.loginWithPasskey(); // usernameless next time
  ```

  ```dart Flutter theme={null}
  await auth.enablePasskey();
  final session = await auth.loginWithPasskey();
  ```

  ```swift iOS theme={null}
  try await auth.enablePasskey()
  let session = try await auth.loginWithPasskey()
  ```

  ```kotlin Android theme={null}
  auth.enablePasskey(activity)              // pass an Activity context
  val session = auth.loginWithPasskey(activity)
  ```
</CodeGroup>

## Associated domains (required)

Passkeys are bound to `passkeyDomain` and only resolve if that domain is registered
as an associated domain for your app.

<Tabs>
  <Tab title="iOS">
    1. Add the **Associated Domains** capability in Xcode with
       `webcredentials:yourapp.com`.
    2. Serve an **Apple App Site Association** file at
       `https://yourapp.com/.well-known/apple-app-site-association` including your
       app's `webcredentials` entry (Team ID + bundle id).
  </Tab>

  <Tab title="Android">
    Serve a **Digital Asset Links** file at
    `https://yourapp.com/.well-known/assetlinks.json` listing your package name and
    the app's signing-certificate SHA-256 fingerprint.
  </Tab>

  <Tab title="Web">
    WebAuthn uses the page's origin as the Relying Party — no extra file. Serve the
    app over HTTPS (or `localhost` in dev).
  </Tab>
</Tabs>

<Warning>
  Until the associated domain is configured, the passkey buttons will error. Email
  OTP still works, so ship OTP first and layer passkeys on once the domain files
  are live.
</Warning>

## Version pinning (mobile)

<Note>
  When building against an older Xcode / Android SDK, the bundled passkey native
  library may pull a transitive dependency that targets a newer OS SDK. If a native
  build fails on an unknown symbol, pin that library down one minor version — see
  the SDK's README for the exact pin.
</Note>
