TOTP Generator

Generate time-based one-time codes from a secret, view time remaining and test two-factor authentication setup.

FreeBrowser
Local-only
Enter a Base32 secret to generate the current TOTP code.
Secret
Not loaded
Config
SHA-1 / 6 digits / 30s

Advanced settings

Only change these values when your issuer does not use the default TOTP settings.

Saved keys

Saved keys are stored in localStorage for this browser only. Avoid saving production credentials on shared devices.

Saved keys stay in this browser only.

Usage notes

  • By default, secrets stay in memory only. You can explicitly enable local persistence on this device.
  • Use otpauth URIs to prefill issuer, account, period, digits, and algorithm.
  • Authenticator apps often expect 30-second / 6-digit / SHA-1 unless configured otherwise.

About TOTP Generator

Generate time-based one-time codes from a shared secret or otpauth URI. See the current code and time remaining while checking the period, digits and algorithm used by a two-factor authentication integration.

How to use TOTP Generator

  1. Enter a Base32 secret or an otpauth URI for a test account.
  2. Confirm the period, code length and algorithm match the integration.
  3. Compare the current code with your authenticator or test service.

Input and output example

Input and settings
Test secret
Period: 30 seconds
Digits: 6
Expected output
A six-digit time-based code and a countdown until the next code.

The actual code depends on the secret, algorithm and current time.

When to use this tool

  • Debug a two-factor login integration.
  • Check whether mismatched clocks or settings explain rejected codes.

Limits to know before using it

Device clock accuracy matters. Use a dedicated authenticator for long-term credential management rather than keeping live secrets in a web tab.

Data handling and cost

Code generation runs in your browser. Secrets stay in memory by default, but the tool offers explicit local persistence and URL-based loading. Shared URLs can expose credentials; enable persistence only on a trusted device.

Free to use in your browser, with no sign-in needed.

Frequently Asked Questions

Code generation runs locally. Secrets stay in page memory by default, but you can explicitly enable device storage or load credentials from URL parameters. URLs can expose credentials through history or sharing; use test secrets and a trusted device.

TOTP codes are time-based. Make sure your device clock is accurate (within a few seconds of UTC). Also verify that the period (30s vs 60s) and digit count (6 vs 8) match the settings used when the secret was registered.

This tool is intended for testing and debugging 2FA integrations, not for managing live account credentials. For production use, store your secrets in a dedicated authenticator app or password manager.

Related Tools