Safeguard
Security Guides•

Email code or SMS code: which should your app send?

A decision guide to email and SMS verification codes covering cost abuse, NIST's restricted status for SMS, and when to offer stronger options.

Safeguard Security Team
3 min read

Neither channel is strong on its own. NIST treats the public telephone network, meaning SMS and voice, as a restricted authenticator and expects an unrestricted alternative. Email codes avoid per-text fees and pumping abuse, but they are only as safe as the mailbox. Offer a passkey or authenticator app where you can.

Definition

An email code and an SMS code are both out-of-band secrets: your system sends a short code through a second channel and the user types it back. The channel changes the risks, not the idea.

Comparison

FactorEmail codeSMS code
Cost per sendUsually lowPer message charge you pay
Pumping abuseLess exposed to inflated traffic fraudA known target
Account takeover pathsAttacker with mailbox access gets the codeSIM change or number porting can redirect it
NIST positionOut-of-band secret; verifier rules applyRestricted; must offer an unrestricted alternative
ReachNeeds internet accessWorks on basic phones
Delivery delayVaries by mailboxVaries by carrier
Phishing resistanceLowLow

Search guidance on SMS pumping from messaging providers says email codes are generally less susceptible to the large scale network abuse that inflates SMS costs, and authenticator apps are another option. Those sources also sell protection, so verify claims against your own traffic. See what SMS pumping is.

What NIST says about SMS

NIST's digital identity guidance says use of the public telephone network for out-of-band verification is restricted. Verifiers must offer at least one unrestricted alternative and should consider risk indicators such as SIM changes or number porting. For both channels, secrets are invalid unless completed within 10 minutes and accepted once. See how long a code should last.

A decision guide

  1. Does your audience have reliable email access at sign-in time? If yes, email is a reasonable default for low-risk flows.
  2. Do you need phone reach for users without smartphones? Keep SMS, with tight limits.
  3. Is the account high value? Offer passkeys, security keys or an authenticator app, and treat codes as fallback. See which MFA to require.
  4. Can attackers reach the user's mailbox easily, for example a shared inbox? Avoid email as the only factor.
  5. Is there any chance of cost abuse? Add send limits and spend alerts either way.

Steps

  1. Offer at least two channels, including one unrestricted by NIST's definition.
  2. Rate limit sends and failed attempts per account.
  3. Do not reveal whether an address or number is registered.
  4. Alert users when a new factor is added or changed.
  5. Plan to move high value accounts to phishing resistant methods. See turning off SMS fallback.

Where Safeguard fits

Safeguard's API security scanning helps find verification endpoints without send limits, and its policy gates keep the fix in your release process. The free scan is at https://gold.safeguard.sh/scan.

Quick check

Is email always safer than SMS?

No. It avoids per-text abuse, but a compromised mailbox gives an attacker the code. Strength depends on the mailbox's own protection.

Do I need an alternative to SMS?

NIST guidance says verifiers must offer at least one unrestricted alternative when they use the telephone network for out-of-band verification.

Sources

Last reviewed: 19 October 2026.

Never miss an update

Weekly insights on software supply chain security, delivered to your inbox.

Self-healing security runs on Safeguard.

Your first fix PR is minutes away.

No sales call required, even your agent can complete the purchase over MCP.