TOTP Secret Generator — 2FA Setup
Create Base32 TOTP secrets and otpauth URIs for two-factor authentication workflows, labs, and account setup demonstrations.
Secret size
20 bytes
Base32 length
~32 chars
Default profile
30s / 6 digits
Configuration
Build a secret for a real setup flow.
Output
Secret, setup fields, and URI.
Base32 secret
Unpadded Base32 is used here for broad authenticator compatibility.
Manual entry
Issuer: MuhammadLab
Account: student@example.com
TOTP settings
Algorithm: SHA1
Digits / period: 6 / 30s
Secret format
Encoding: Base32
Padding: omitted
Best for
Authenticator setup guides, staging accounts, lab walkthroughs, and local teaching demos.
Examples
Good uses for this tool.
Student lab demo: create a sample issuer and account to show how authenticator setup works before students touch a real account.
Documentation: generate an example otpauth URI when writing internal setup guides for VPN, Git hosting, or lab portals.
Testing: create disposable TOTP seeds for staging or browser-only demos without pasting real secrets into screenshots.
How it works
The setup flow in plain language.
1. The browser generates random bytes with `crypto.getRandomValues`.
2. Those bytes are encoded into Base32 so authenticator apps can store them as a shared secret.
3. The secret, issuer, account, algorithm, digits, and period are packed into an `otpauth://` URI.
4. An authenticator app uses that shared secret to generate time-based one-time codes every period window.
Frequently Asked Questions
Related Tools
API Key / Token Generator — Free Online
Generate random API keys and tokens with custom length, alphabet, and prefix.
Password Generator — Secure & Customizable
Generate strong, random passwords with custom length, complexity, and character options. Includes strength meter.
JWT Decoder — Inspect JSON Web Tokens
Decode and inspect JWT tokens — view header, payload, expiration, and claims without a private key.