TwoFac
2FA Authenticator app that works on mobile, web, desktop, watches and CLI!
Install / Use
/learn @championswimmer/TwoFacREADME
| <img src="docs/twofac-logo.png" alt="TwoFac logo" width="128" height="128" /> | <h1 align="left">TwoFac</h1> <br> Open Source, Native, Cross-Platform 2FA App for Watch, Mobile, Desktop, Web and CLI! | |---|---|
ROADMAP
- [ ] Common functionality
- [x] Add new accounts
- [x] Display accounts with 2FA codes
- [x] Save accounts to a storage
- [x] Delete account storage
- [ ] Backup & Restore via a backup transport
- [ ] Export & Import accounts (encrypted with passkey)
- [x] QR Account Scanning (Camera + Clipboard)
- [x] Import from other 2FA apps
- [x] Authy (JSON format)
- [x] 2FAS (JSON format)
- [x] Ente (plaintext otpauth:// URIs)
- [ ] Mobile Apps (Android & iOS)
- [x] Biometric Authentication
- [ ] Home / Accounts / Settings Bottom Tabs
- [x] Wearable Apps
- [x] Wear OS companion app with offline sync
- [x] watchOS companion app with offline sync
- [ ] Desktop App
- [ ] System Tray / Menu Bar Application
- [x] Web & Browser Extensions
- [x] Progressive Web App (PWA)
- [x] Chrome Extension
- [x] Firefox Extension
- [x] WebAuthn / Device-Credential Unlock
- [ ] CLI App
- [x] Add new accounts
- [x] Display 2FA codes with auto-refresh
- [x] 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:wasmJsBrowserDevelopmentRun
Related Skills
node-connect
339.5kDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps
frontend-design
83.9kCreate distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.
openai-whisper-api
339.5kTranscribe audio via OpenAI Audio Transcriptions API (Whisper).
commit-push-pr
83.9kCommit, push, and open a PR
