2FAuth

Open source

A self-hosted web app for managing two-factor authentication accounts and generating TOTP and HOTP codes, as an alternative to Google Authenticator.

docs.2fauth.app
2FAuth homepage screenshot
GitHub stars
4.2k
Last 30 days
+42(+1%)
Last commit
10 days ago
Repository age
7 years
Version
v9.0.1
Licence
AGPL-3.0
Self-hosted
Yes

About 2FAuth

2FAuth is a self-hosted web application for managing two-factor authentication accounts and generating their security codes. It serves as a web-based alternative to one-time passcode apps such as Google Authenticator and is designed to work on both mobile and desktop screens.

Accounts can be organized into groups, added by scanning and decoding a QR code or by filling in an advanced form, and edited later, including imported ones. It generates TOTP, HOTP and Steam Guard codes. The author built it to avoid interfaces that show every code at once with stressful countdowns, to keep 2FA accounts in a standalone database that is easy to back up and restore, and to avoid reaching for a phone when working on a desktop.

Access requires a user account, and since version 4.0 multiple users are possible, with public registration, registration limited by email domain, SSO-only registration or no registration at all. 2FAuth is written in PHP, licensed under AGPL-3.0, localized in English and French, and offers a public demo.

Key features

  • TOTP, HOTP and Steam Guard codes
  • QR code scanning to add accounts
  • Manual account entry form
  • Groups for organizing accounts
  • Multi-user support with SSO option
  • Standalone database for easy backup

Good fit for

  • Replacing a phone-only authenticator app
  • Generating codes on a desktop
  • Backing up 2FA accounts
Built with
PHP tools
Tags
2fa
totp
hotp
authenticator
two-factor-authentication
self-hosted
php
otp

2FAuth: questions and answers

What is 2FAuth used for?
2FAuth is a self-hosted web app for managing two-factor authentication accounts and generating TOTP and HOTP codes, as an alternative to Google Authenticator. It is a good fit for replacing a phone-only authenticator app, generating codes on a desktop and backing up 2FA accounts.
Is 2FAuth open source?
Yes. 2FAuth is open source under the AGPL-3.0 licence. Its source code is on GitHub at Bubka/2FAuth and is written mainly in PHP.
Is 2FAuth free?
Yes. 2FAuth is open source, so the software itself is free to use.
Can I self-host 2FAuth?
Yes. 2FAuth can be self-hosted on your own server or infrastructure; there is no official hosted version.
What is 2FAuth an alternative to?
2FAuth is an open-source alternative to Microsoft Authenticator and Google Authenticator. Other open-source alternatives to Microsoft Authenticator include Aegis Authenticator, Bitwarden and KeePassXC.
Is 2FAuth actively maintained?
Yes. The most recent commit to 2FAuth was on 3 November 2026, and the latest release is v9.0.1, published on 2 November 2026. The project has 4.2k stars on GitHub, with 42 added in the last 30 days.

Open-source alternatives to 2FAuth

See all

SaaS alternatives to 2FAuth

See all