coderef

Web authenticationBaseline · Widely available

The web authentication API allows you to create public key-based credentials and use them for authentication, such as when signing in. Also known as WebAuthn.

Supported in all major browsers for at least 30 months — safe to use without fallbacks. Baseline since Sep 7, 2021. Widely available since Mar 7, 2024.

Browser support

DesktopChrome
1–66Not supported
67+Supportedsince May 29, 2018
Current: 155
Edge
12–17Not supported
18+Supportedsince Oct 2, 2018
Current: 154
Firefox
1–59Not supported
60+Supportedsince May 9, 2018
Current: 157
Safari
1–12.1Not supported
13+Supportedsince Sep 19, 2019
Current: 27
MobileChrome Android
18–69Not supported
70+Supportedsince Oct 17, 2018
Current: 155
Firefox Android
4–91Not supported
92+Supportedsince Sep 7, 2021
Current: 157
Safari iOS
1–12.2Not supported
13+Supportedsince Sep 19, 2019
Current: 27

How to use

This feature is Baseline widely available — use it freely, no fallback needed.

Example

Full syntax and examples are on MDN: AuthenticatorAssertionResponse.

Feature detection

JS · check before using
if ("AuthenticatorAssertionResponse" in globalThis) {
  // AuthenticatorAssertionResponse is available
} else {
  // load a polyfill or use a fallback
}

Sub-features

Support for each part of the feature (42). The overall table above shows when the whole feature works.

Show 22 more
Sub-featureChromeEdgeFirefoxSafariChrome AndroidFirefox AndroidSafari iOS
CredentialsContainer.create.publicKey_option.extensions.minPinLength9898120✕98120✕
CredentialsContainer.create.publicKey_option.requireResidentKey8989✕✕108✕✕
CredentialsContainer.create.publicKey_option.residentKey8989114✕108128✕
CredentialsContainer.get.publicKey_option67186013706013
CredentialsContainer.get.publicKey_option.extensions67186013706013
CredentialsContainer.get.publicKey_option.extensions.appid67186013706013
CredentialsContainer.get.publicKey_option.extensions.largeBlob113113139✕113139✕
PublicKeyCredential67186013709213
PublicKeyCredential.authenticatorAttachment989812015.59812015.5
PublicKeyCredential.getClientCapabilities_static13313313517.413313517.4
PublicKeyCredential.getClientExtensionResults67186013709213
PublicKeyCredential.isConditionalMediationAvailable_static1081081191610811916
PublicKeyCredential.isUserVerifyingPlatformAuthenticatorAvailable_static67186013709213
PublicKeyCredential.parseCreationOptionsFromJSON_static12912911918.412911918.4
PublicKeyCredential.parseRequestOptionsFromJSON_static12912911918.412911918.4
PublicKeyCredential.rawId67186013709213
PublicKeyCredential.response67186013709213
PublicKeyCredential.toJSON12912911918.412911918.4
iframe.allow.publickey-credentials-create✕✕123✕✕123✕
iframe.allow.publickey-credentials-get8484118✕84118✕
http.headers.Permissions-Policy.publickey-credentials-create8888✕✕88✕✕
http.headers.Permissions-Policy.publickey-credentials-get8888✕✕88✕✕