What is TOTP (time-based one-time password)? | Transmit Security

Glossary

What is TOTP (time-based one-time password)?

TOTP is a time-based one-time password generated by an authenticator app from a shared secret, refreshing every 30 seconds.
by Transmit Security

TOTP (time-based one-time password) is a one-time code generated on a device (usually an authenticator app) from a shared secret and the current time, refreshing at short intervals (typically every 30 seconds). It’s the code behind apps like the common authenticator tools, and a stronger second factor than SMS.

TOTP improved on SMS OTP by removing the delivery channel: the code is computed locally on the user’s device, so there’s no text message to intercept or SIM to swap.

How TOTP works

At setup, the service and the authenticator app share a secret seed (often via a QR code). From then on, both sides independently compute the same code from that seed plus the current time, using a standard algorithm. When the user enters the code shown in their app, the server computes the expected value and compares. Because both derive it from synchronized time, no code needs to be transmitted from server to user.

Strengths over SMS

  • No interception channel, nothing is sent over SMS or email to be intercepted.
  • SIM-swap resistant, the code isn’t tied to a phone number.
  • Offline, the app generates codes without connectivity.

The remaining weakness: phishing

TOTP still shares the fundamental OTP flaw: the user reads a code and types it, so a real-time phishing site can capture it and relay it within its 30-second window. It resists the passive attacks SMS is prone to, but not active real-time phishing. That’s why TOTP is a solid step up from SMS yet still short of phishing-resistant methods like passkeys. For many services it’s a reasonable second factor; for high-value accounts, phishing-resistant options are preferable.

Frequently asked questions

What does TOTP stand for?

Time-based one-time password.

Is TOTP more secure than SMS OTP?

Yes. It isn’t exposed to SIM swapping or interception, though it remains phishable in real time.

How often does a TOTP code change?

Typically every 30 seconds.

Can TOTP be phished?

Yes, a real-time phishing site can capture and relay the code within its valid window.

What replaces TOTP for stronger security?

Phishing-resistant methods like passkeys, where there’s no code to read and relay because the proof is cryptographic and origin-bound.

Related: One-Time Password (OTP) · SMS OTP / SMS 2FA · Multi-Factor Authentication (MFA) · Passkeys

Request a Demo

By clicking the button, you agree to the Terms and Conditions