Skip to main content
New

2FA codes. From any setup key.

Paste a TOTP setup key and get a fresh 6-digit code every 30 seconds. Everything runs in your browser — your secrets never touch our servers.

Codes follow the open TOTP standard, RFC 6238, the same algorithm authenticator apps use.

2FA Setup Key

Paste the base32 secret your service showed when enabling 2FA. Spaces and dashes are ignored.

Setup keys never leave your browser. A key is kept only if you press Save.

Saved keys stay in this browser on this device, unencrypted. Anyone who uses this browser can open them, so do not save keys on a shared computer.

Current code

Generate a code to begin

What this 2FA generator does

Two-factor authentication (2FA) adds a second step to a login: after your password, a site asks for a short code that changes every few seconds. The most common kind is TOTP — a time-based one-time password. When you turn on 2FA, the site gives you a setup key (the text behind the QR code). An authenticator app stores that key and uses it, together with the current time, to work out the 6-digit code. This page does the same calculation in your browser so you can read the current code and copy it in.

How to use it, step by step

  1. On the website, choose “authenticator app” when setting up 2FA and reveal the setup key.
  2. Paste that key into the box above. The current 6-digit code appears with a countdown.
  3. Enter the code on the website before the timer runs out; a fresh code is ready every 30 seconds.
  4. Keep the site’s backup/recovery codes somewhere safe in case you lose access.

Keeping your keys safe

Codes and keys are computed entirely in your browser with the Web Crypto API; they are never sent to Tmail. If you save a key for later, it is kept in this browser’s local storage on this device, so only save on a device that is yours and clear saved keys when you are done. A 2FA setup key is as sensitive as a password — anyone who has it can generate your codes. For your most important accounts, a dedicated authenticator app or a hardware security key remains the safest home for these secrets.

2FA generator — frequently asked questions

What is a TOTP 2FA code?
A TOTP (time-based one-time password) is the 6-digit code an authenticator app shows for a login. It is worked out from a secret setup key and the current time, and it changes every 30 seconds. It follows the open RFC 6238 standard, so any app that supports TOTP produces the same code for the same key.
How do I use this 2FA generator?
When a website shows you a 2FA setup key (the string of letters and numbers under the QR code), paste it here. The generator shows the current 6-digit code and counts down to the next one. Type the code into the website to finish signing in. You can also keep a key saved on this device to get its codes again later.
Is it safe to generate 2FA codes in the browser?
The setup key and the codes are worked out entirely in your browser using the Web Crypto API — nothing is sent to our servers. Any key you choose to save stays in this browser's local storage on this device, unencrypted, so only use Save on a device that is yours, and use the Clear option to remove saved keys. For important accounts, keep the provider's backup codes as well.
My code is rejected — why?
TOTP depends on the clock. If your device's time is off by more than about a minute, the code can be wrong. Make sure your system clock is set to update automatically, then try the next code. Also check you pasted the full setup key with no missing characters.
Does this replace my authenticator app?
It can generate the same codes, but a code generator is only as safe as where the key is kept. For high-value accounts, a dedicated authenticator app or a hardware key is still the better long-term home for your 2FA secrets. This tool is handy for quick access and for testing.