Previous
None
Compute the current RFC 6238 code from a Base32 secret, see how many seconds it has left, and read the previous and next codes. Check a code against a clock-skew window, or derive an RFC 4226 HOTP code from a counter you type.
Length and a short-key warning appear after a valid secret.
Enter a Base32 secret to compute a code.
None
The report lists the codes and the HMAC of the counter. It omits the secret and the otpauth URI.
Compare a code you already have with this secret, clock, and settings. The search starts at the current step and moves outward. It does not contact a service.
Enter a code and choose Check code. The search stays in this tab.
RFC 4226. The counter is the event count you type. It does not advance by itself and it is not saved.
Not computed yet.
The URI is text you can copy into an app that accepts it. This page does not draw a QR code and does not call a QR service. Issuer and account change the URI only. They do not change the code.
A TOTP code is an HOTP code whose counter is the number of whole periods since T0. With the usual settings, T0 is 0 and the period is 30 seconds, so the counter is the Unix time divided by 30. That counter is eight big-endian bytes. This page signs those bytes with HMAC-SHA-1, HMAC-SHA-256, or HMAC-SHA-512 through crypto.subtle, then applies RFC 4226 dynamic truncation: the low four bits of the last digest byte pick an offset, four bytes there become a 31-bit integer, and the code is that integer modulo 10 to the digit count, padded with zeros.
The previous and next codes are the neighboring counters. Checking a code starts at the current step and moves outward up to the window you set. Offset -1 means the code belongs to the previous period. A match only means this page can reproduce the code. It does not ask a remote service what it will accept.
Base32 follows RFC 4648. Case, spaces, and hyphens are ignored, and trailing equals signs are optional. The digits 0, 1, 8, and 9 are not in the alphabet. A string that looks like hexadecimal is rejected rather than decoded as Base32. RFC 6238 Appendix B prints the 20-byte ASCII seed 12345678901234567890. The SHA-256 and SHA-512 rows match only when that pattern is extended to 32 and 64 bytes. The sample menu loads those seeds and pauses the clock. At Unix time 59 with 8 digits, SHA-1 is 94287082, and the previous code is 84755224. The last six digits of that previous code, 755224, are the counter-0 value in RFC 4226.
The otpauth text follows the Google Authenticator Key URI format. T0 is not part of it. Some authenticator apps ignore algorithm, period, or a digit count other than 6, so compare one code after you import a non-default URI. Standards: RFC 6238, RFC 4226, and the Key URI format.