Skip to content
WordPress.org
  • Showcase
  • Plugins
  • Themes
  • Hosting
  • News
    • Learn WordPress
    • Documentation
    • Education
    • Forums
    • Developers
    • Blocks
    • Patterns
    • Photos
    • Openverse ↗︎
    • WordPress.tv ↗︎
    • About WordPress
    • Make WordPress
    • Events
    • Five for the Future
    • Enterprise
    • Gutenberg ↗︎
    • Job Board ↗︎
  • Swag ↗︎
  • Get WordPress
Get WordPress
WordPress.org

Plugin Directory

L2S Login OTP 2FA

  • Submit a plugin
  • My favorites
  • Log in
  • Submit a plugin
  • My favorites
  • Log in

L2S Login OTP 2FA

By LANDOLSI SMART SOLUTION – L2S
Download
  • Details
  • Reviews
  • Installation
  • Development
Support

Description

L2S Login OTP 2FA adds a second step to the WordPress login. After entering their password, users confirm their identity with a second factor before the login cookie is set.

Available methods

  • Authenticator app (TOTP): 6-digit codes from Google Authenticator, Microsoft Authenticator, Authy, 1Password and any RFC 6238 app. The QR code is generated in the browser; the secret never leaves your site.
  • Email: a one-time code sent to the user’s email address, with a customizable email template.
  • SMS: a one-time code sent by text message through Twilio, Vonage (Nexmo) or TunisieSMS.
  • Biometrics / security key (WebAuthn): fingerprint, face recognition, device PIN or a hardware security key. Requires HTTPS.
  • Recovery codes: single-use backup codes, with an email alert each time one is used.

Features

  • Each administrator chooses which methods are available, and whether administrators are exempt.
  • Each user configures their methods from their profile and can pick a default one; other methods stay available via “Another method”.
  • Per-method limits: number of attempts, temporary lock duration and resend delay (with countdown).
  • SMS sending history, with the codes masked.
  • Interface in English, French, Spanish and German. The plugin follows the user’s language and falls back to English for any other language.
  • Emergency switch: add define( 'L2SOTP_DISABLE', true ); to wp-config.php to turn off two-factor authentication.

External services

This plugin connects to external services only for the SMS method, and only when an administrator enables it and selects a provider. Each time a code is sent by SMS (at login, or when the administrator sends a test SMS), the plugin sends the recipient’s phone number and the message text (which contains the one-time code) to the selected provider, along with the provider credentials entered in the settings. The administrator’s “test connection” buttons also query the provider for the account status or balance.

Twilio (api.twilio.com) – SMS delivery.
Terms of service: https://www.twilio.com/legal/tos
Privacy policy: https://www.twilio.com/legal/privacy

Vonage / Nexmo (rest.nexmo.com) – SMS delivery.
Terms of service: https://www.vonage.com/legal/
Privacy policy: https://www.vonage.com/legal/privacy-policy/

TunisieSMS (api.l2t.io, operated by L2T, owner of TunisieSMS) – SMS delivery in Tunisia.
Company: https://www.L2T.io
Product: https://www.TunisieSMS.tn
Terms of service: https://www.tunisiesms.tn/cgv/
Privacy policy: https://www.tunisiesms.tn/confidentialite/

No other data is sent to external services. Authenticator app codes, biometrics and recovery codes are verified locally on your site.

Third-party libraries

  • WebAuthn by Lukas Buchs (MIT license) – https://github.com/lbuchs/WebAuthn
  • QR Code Generator for JavaScript by Kazuhiko Arase (MIT license) – https://github.com/kazuhikoarase/qrcode-generator

Screenshots

Second step of the login screen with the one-time code field.
Second step of the login screen with the one-time code field.
Choosing a verification method.
Choosing a verification method.
Setting up the authenticator app with a QR code in the user profile.
Setting up the authenticator app with a QR code in the user profile.
Plugin settings page.
Plugin settings page.

Installation

  1. Upload the l2s-login-otp-2fa folder to /wp-content/plugins/, or install the zip from Plugins > Add New > Upload Plugin.
  2. Activate the plugin.
  3. Open the L2S OTP menu and enable the methods you want (and configure your SMS provider if you use SMS).
  4. Each user then sets up their methods from Users > Profile.

Important: before enabling two-factor authentication for administrators, test it on your own account and save your recovery codes.

FAQ

I am locked out. How can I log in?

Use one of your recovery codes. If you have none left, an administrator can reset your methods. As a last resort, add define( 'L2SOTP_DISABLE', true ); to wp-config.php, or rename the wp-content/plugins/l2s-login-otp-2fa folder via FTP.

I don’t receive the email codes.

Check your spam folder. Many hosts do not send WordPress emails reliably; configure SMTP with a dedicated plugin.

Biometrics do not work.

WebAuthn requires HTTPS (or localhost for testing) and a compatible browser and device.

Is the SMS method free?

The plugin is free, but sending SMS requires an account with one of the supported SMS providers, which charge for each message.

Reviews

There are no reviews for this plugin.

Contributors & Developers

“L2S Login OTP 2FA” is open source software. The following people have contributed to this plugin.

Contributors
  • LANDOLSI SMART SOLUTION – L2S

Translate “L2S Login OTP 2FA” into your language.

Interested in development?

Browse the code, check out the SVN repository, or subscribe to the development log by RSS.

Changelog

1.0.0

  • First public release.
  • Authenticator app, email, SMS (Twilio, Vonage, TunisieSMS), biometrics (WebAuthn) and recovery codes.
  • Per-method limits, resend countdown, SMS history.
  • English, French, Spanish and German.

Meta

  • Version 1.0.0
  • Last updated 3 hours ago
  • Active installations Fewer than 10
  • WordPress version 6.2 or higher
  • Tested up to 7.1.5
  • PHP version 8.0 or higher
  • Tags
    2FAloginotpsecuritytwo factor
  • Advanced View

Ratings

No reviews have been submitted yet.

Your review

See all reviews

Contributors

  • LANDOLSI SMART SOLUTION – L2S

Support

Got something to say? Need help?

View support forum

  • About
  • News
  • Hosting
  • Privacy
  • Showcase
  • Themes
  • Plugins
  • Patterns
  • Learn
  • Documentation
  • Developers
  • WordPress.tv ↗
  • Get Involved
  • Events
  • Donate ↗
  • Swag ↗
  • WordPress.com ↗
  • Matt ↗
  • bbPress ↗
  • BuddyPress ↗
WordPress.org

The WordPress® trademark is the intellectual property of the WordPress Foundation.

  • Visit our X (formerly Twitter) account
  • Visit our Bluesky account
  • Visit our Mastodon account
  • Visit our Threads account
  • Visit our Facebook page
  • Visit our Instagram account
  • Visit our LinkedIn account
  • Visit our TikTok account
  • Visit our YouTube channel
  • Visit our Tumblr account
Code is Poetry