How Passkeys Work: Going Passwordless with Public Key
In this article
Passkeys replace passwords with a pair of cryptographic keys: a private key stored on your device and a public key stored on the website's server. When you sign in, the server sends a challenge that only your private key can answer, so you never type a password and the server never stores a secret. This guide explains the mechanics and walks you through setting up and using passkeys on your devices.
What You'll Need
- A device that supports passkeys: most modern smartphones (iOS 16+, Android 9+), computers with Windows 10/11, or a security key (like YubiKey).
- A browser that supports passkeys: Chrome, Edge, Safari, or Firefox (recent versions).
- An account on a website or app that has enabled passkey support (e.g., Google, Apple, Microsoft, PayPal, or many password managers).
- For cross-device sign-in: Bluetooth enabled on both devices, and you may need to scan a QR code.
Step-by-Step
- Understand the key pair. When you create a passkey, your device generates two keys: a private key that never leaves your device (stored in the secure hardware like TPM or Secure Enclave) and a public key that is sent to the website. The website stores only the public key.
- Enable passkeys on the website. Log in to the website with your existing password, then go to your account security settings. Look for a section labeled "Passkeys," "Security Keys," or "Passwordless sign-in." The exact wording varies by site.
- Create your first passkey. Click the option to add a passkey. The website will ask your device to generate a key pair. Your device may prompt you to confirm with your fingerprint, face scan, or PIN. That confirmation is the only authentication you'll need later.
- Choose where to store the private key. You can store it on the device itself (e.g., your phone's secure enclave) or in a password manager that supports passkeys (like 1Password or Bitwarden). If you use a password manager, the private key syncs across your devices, so you can sign in from any of them.
- Sign in with the passkey. On the website's login page, choose "Sign in with a passkey" instead of entering a password. The site sends a challenge to your device. Your device uses the private key to create a digital signature and sends it back. The site verifies the signature with your public key, and you're logged in.
- Use cross-device sign-in. If you're on a computer and your passkey is on your phone, select "Use a phone or tablet" on the login screen. A QR code appears. Scan it with your phone's camera, then approve the sign-in on your phone. Bluetooth must be on for the two devices to communicate.
- Back up your passkeys. Most platforms sync passkeys through your cloud account (iCloud Keychain, Google Password Manager, or Microsoft account). This ensures you don't lose access if you lose your device. For extra safety, export a recovery code if the site offers one.
Common Mistakes
- Storing passkeys only on one device without backup. If you lose that device and have no recovery method, you could be locked out.
- Using a public computer. Never create a passkey on a shared or borrowed device, because the private key stays on that device and could be used by others.
- Ignoring the website's recovery options. Always set up backup codes or alternate sign-in methods before going passwordless.
- Assuming all sites use the same passkey flow. Some sites require you to enter your username first, then choose the passkey option. Others may show a QR code immediately.
Tips
- Use a password manager that supports passkeys to sync them across all your devices securely.
- Enable two-factor authentication (2FA) as an extra layer even with passkeys, though passkeys themselves are already phishing-resistant.
- Keep your device's OS and browser updated to get the latest passkey security improvements.
- If you use a security key (hardware token), register it as a backup passkey on every important account.
- Test passkey sign-in on a less critical account first to get comfortable with the flow.
Troubleshooting
- Passkey option not showing. Make sure the website actually supports passkeys and that you're using a compatible browser. Update your browser and OS.
- QR code won't scan. Ensure Bluetooth is enabled on both devices and that your phone's screen is bright enough. Try moving closer.
- Cross-device sign-in fails. Check that both devices are signed into the same cloud account (e.g., iCloud or Google) if you're using a cloud-synced passkey. If not, you may need to create a passkey on the device you're using.
- Forgot which device holds the passkey. Try signing in with your password as a fallback. Then go to your account settings and review the list of registered passkeys, removing any you no longer use.
- Lost your device. Use your recovery codes or alternate sign-in method (like a backup email or phone number). After regaining access, revoke the lost device's passkey in your security settings.
- Passkey works on one site but not another. Different sites implement passkeys differently. Some may require a specific browser or may not support cross-device sign-in. Check the site's help page.
Frequently Asked Questions
Are passkeys more secure than passwords?
Yes. Passkeys use public-key cryptography, so the server never stores a secret that can be stolen. They are also phishing-resistant because they are tied to the specific website's domain.
What happens if I lose my device?
If you have cloud sync enabled, your passkey is backed up and you can restore it on a new device. Otherwise, you'll need to use your recovery codes or alternate sign-in methods to get back into your account.
Can I use passkeys on multiple devices?
Yes. You can create multiple passkeys for the same account, one per device, or use a password manager that syncs a single passkey across all your devices.
Do passkeys work on all websites?
No. Passkey support is growing, but not every site offers it yet. You'll still need a password for sites that haven't adopted passkeys.
Can I still use a password if I have a passkey?
Yes. Most sites let you keep your password as a fallback. You can choose to use the passkey for convenience and security, but the password remains as a backup.
Are passkeys the same as two-factor authentication?
No. Passkeys are a password replacement, not a second factor. They prove you have the private key, which is something you possess. Some sites may still ask for an additional factor like a PIN or biometric, but that's part of the passkey unlock, not a separate 2FA.