CH
championswimmer/TwoFac
2FA Authenticator app that works on mobile, web, desktop, watches and CLI!
![]() |
TwoFacOpen Source, Native, Cross-Platform 2FA App for Watch, Mobile, Desktop, Web and CLI! |
|---|
ROADMAP
- Common functionality
- Add new accounts
- Display accounts with 2FA codes
- Save accounts to a storage
- Delete account storage
- Backup & Restore via a backup transport
- Export & Import accounts (encrypted with passkey)
- QR Account Scanning (Camera + Clipboard)
- Import from other 2FA apps
- Authy (JSON format)
- 2FAS (JSON format)
- Ente (plaintext otpauth:// URIs)
- Mobile Apps (Android & iOS)
- Biometric Authentication
- Home / Accounts / Settings Bottom Tabs
- Wearable Apps
- Wear OS companion app with offline sync
- watchOS companion app with offline sync
- Desktop App
- System Tray / Menu Bar Application
- Web & Browser Extensions
- Progressive Web App (PWA)
- Chrome Extension
- Firefox Extension
- WebAuthn / Device-Credential Unlock
- CLI App
- Add new accounts
- Display 2FA codes with auto-refresh
- Delete account storage
Documentation
- Importing from Other Apps - Guide to importing 2FA secrets from Authy, 2FAS, Ente Auth, and other authenticator apps
- Development Guide - Setup, building, and running the project
- GitHub Copilot Setup - Pre-configured environment with Java 21, Node.js 22, and Gradle caching
Development
Prerequisites
- JDK 17+ (recommended: JDK 21)
- Android SDK (if building Android targets)
- Xcode (if building iOS targets on macOS)
- Native toolchains for your platform (GCC/Clang for Linux, MSVC for Windows)
Project structure
TwoFac/
├── sharedLib/ # Shared 2FA library (TOTP/HOTP, crypto, storage)
├── cliApp/ # CLI application (Clikt-based, native binaries)
├── composeApp/ # Compose Multiplatform UI application
├── watchApp/ # Wear OS app
└── iosApp/ # iOS application wrapper
Common commands
# Baseline checks
./gradlew check
# Module tests
./gradlew :sharedLib:test
./gradlew :cliApp:test
./gradlew :composeApp:test
# Run desktop app
./gradlew :composeApp:run
# Run web app
./gradlew :composeApp:wasmJsBrowserDevelopmentRunOn this page
Languages
Kotlin88.2%TypeScript4.2%JavaScript3.4%Swift3.3%Shell0.7%HTML0.2%CSS0.0%
Created June 17, 2025
Updated March 13, 2026

