TOTP / 2FA Code Generator help

TOTP / 2FA Code Generator implements RFC 6238. Give it the base32 secret from a service's two-factor setup and it shows the current code and the seconds left before it changes.

Steps

  1. Paste the base32 secret, or generate a random one to experiment.
  2. Set the digit count, period, and hash algorithm to match the service.
  3. Read the code, or copy the otpauth:// link to load it into an authenticator app.

Common questions

What is a base32 secret?

It is the string a service gives you when you set up two-factor authentication, often shown next to the QR code. It uses the letters A to Z and digits 2 to 7.

Why does my code not match the service?

Check the digit count, period, and algorithm. Most services use 6 digits, a 30-second period, and SHA1. Also make sure your device clock is accurate.

Is it safe to paste my real secret here?

The secret never leaves your browser. Still, anyone who has the secret can generate your codes, so only do this on a device you trust and clear the field when done.

Does this replace my authenticator app?

It can generate the same codes, but an app keeps the secret in secure storage. Use this for testing or as a short-term backup.

Everything runs in your browser. Nothing you enter or drop is uploaded.

Back to TOTP / 2FA Code Generator