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

# Stytch Passkey Registration

> Implement passkey registration UI using the Stytch React SDK

![Example of Passkey Registration component](https://mintcdn.com/stytch-34ca0595/chUftqYqk2C1W0Ql/images/api-reference/b2c/frontend-sdks/prebuilt-ui-passkey-registration.png?fit=max\&auto=format\&n=chUftqYqk2C1W0Ql\&q=85\&s=12e20bfc4c558cbfe1d979f046e23011)

The SDK comes with a pre-built UI component to register passkeys. This component will only work when the user has an existing Stytch session.

## Props

**config** `object`

The configuration object for the UI component. This component accepts the same `config` as StytchLogin so you can reuse the config, although most options will not have any effect.

**properties**

**passkeysOptions** `object`

The options for passkeys.

**properties**

**domain** `string`

Sets the domain option for both WebAuthn registration and authentication. Defaults to the current page's hostname.

**presentation**

The `presentation` field allows you to customize the look of the SDK. This component accepts the same `presentation` prop as `StytchLogin` so you can reuse it. For more information, see the [Theming documentation](https://stytch.com/docs/api-reference/consumer/frontend-sdks/react/prebuilt-ui/theming.md).

**callbacks** `object`

Optional callbacks that are triggered by various events in the SDK. See more details about the callbacks [here](https://stytch.com/docs/api-reference/consumer/frontend-sdks/react/prebuilt-ui/login/callbacks.md).

**onEvent** `(data) =\> void`

A callback function that responds to events sent from the SDK.

**events**

**PASSKEY\_REGISTER** `(data) =\> void`

Fired when the user successfully registers a new passkey.

```js data theme={null}
{
  user_id: "user_id",
  session: { ... },
  user: { ... },
  webauthn_registration_id: "webauthn-registration-test-db72fcc0-edae-4bb4-8d52-0b2a765683df"
}
```

**PASSKEY\_SKIP**

Fired when the user presses the skip button.

**PASSKEY\_DONE**

Fired when the user presses the done button.

**onError** `(data) =\> void`

A callback function that responds to errors in the SDK. It is useful for debugging during development and error handling in production.

**strings** `object`

Specify custom strings to be used in the prebuilt UI. Consult the message catalog (messages/en.po) for the list of available strings. Each value should be specified using ICU MessageFormat.

Strings that are not defined will use the default English value as a fallback.

See [Text Customization](https://stytch.com/docs/api-reference/consumer/frontend-sdks/react/prebuilt-ui/text-customization.md) for more information.

```jsx theme={null}
import { Products, StytchPasskeyRegistration } from '@stytch/react';

const config = {
  passkeysOptions: {
    domain: 'example.com',
  },
};

export const PasskeyRegistration = () => {
  return <StytchPasskeyRegistration config={config} />;
};
```
