# 2FA Code Generator (TOTP)

> Generate 2FA codes from a Base32 secret or otpauth link. Runs entirely in your browser — nothing is uploaded.

Source: https://toffeekit.com/tools/totp-generator

**Category:** [Security](https://toffeekit.com/category/security) · **Price:** Free · **Runs:** in your browser, nothing is uploaded

Open the tool: https://toffeekit.com/tools/totp-generator

**Also useful for:** totp, 2fa, otp, authenticator, one-time password, mfa, otpauth, google authenticator

## How it works

1. Paste your Base32 secret, or a full otpauth:// link, into Secret or otpauth:// link.
2. Choose Digits: 6 or 8. Most services use 6.
3. Leave Period at 30 seconds and Algorithm at SHA-1 unless your service says otherwise.
4. Read the current code and countdown, then click Copy code. The next code is shown below it.

## FAQ

### How do I get a 2FA code without an authenticator app?

Enter the setup secret the service gave you, and this tool computes the same six digit code your app would. It uses the standard TOTP algorithm.

### What is a TOTP secret and where do I find it?

It is a Base32 string, like JBSWY3DPEHPK3PXP, shown when you set up two-factor authentication, often under a link such as Can't scan the QR code.

### Why does my code not match the service?

Check the digits, period and algorithm settings, and make sure your device clock is accurate. Most services use 6 digits, 30 seconds and SHA-1.

### What is an otpauth link?

It is the address encoded in a 2FA QR code, starting with otpauth://totp/. Pasting it fills in the secret and other settings for you.

### How long is each code valid?

30 seconds by default. The ring shows time remaining, and the next code is displayed so you can use it as the timer runs out.

### Is 2FA Code Generator (TOTP) free and private?

Yes. It's free with no sign-up or limits, and it runs entirely in your browser, so what you type or paste never leaves your device. It works on phones and computers alike.

## Privacy

2FA Code Generator (TOTP) runs entirely in your browser. Your files and text are processed on your device and are never uploaded.

## Related tools

- [Password Generator](https://toffeekit.com/tools/password-generator) — Strong random passwords from your browser's crypto.
- [Text Redactor](https://toffeekit.com/tools/text-redactor) — Hide emails, phones, cards and more in any text.
- [Passphrase Generator](https://toffeekit.com/tools/passphrase-generator) — Memorable random-word passphrases with entropy.
- [Password Strength Checker](https://toffeekit.com/tools/password-strength-checker) — Test a password's strength and crack time privately.
- [Text Encrypt / Decrypt](https://toffeekit.com/tools/text-encryption) — Encrypt messages with a password using AES-256.
- [File Encrypt / Decrypt](https://toffeekit.com/tools/file-encryption) — Password-protect any file with AES-256 encryption.

