PHPackages                             stefan-z/laravel-totp - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Authentication &amp; Authorization](/categories/authentication)
4. /
5. stefan-z/laravel-totp

ActiveLibrary[Authentication &amp; Authorization](/categories/authentication)

stefan-z/laravel-totp
=====================

Create a TAN/TOTP for usage in any kind of two-factor-scenarios

0.0.3(1y ago)092↓50%MITPHPPHP ^8.1

Since Nov 8Pushed 1y ago1 watchersCompare

[ Source](https://github.com/StefanZimmermann98/laravel-totp)[ Packagist](https://packagist.org/packages/stefan-z/laravel-totp)[ RSS](/packages/stefan-z-laravel-totp/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependenciesVersions (4)Used By (0)

PHP TOTP Code Generation
========================

[](#php-totp-code-generation)

Generate simple TOTP-Codes for multi-factor purpoises and validate them quickly.

Example
=======

[](#example)

```
use StefanZ\LaravelTOTP\TOTP;

$token = (new TOTP('sha256', 0, 600))->GenerateToken('SUPER-SECRET', NULL, 8);

```

```

if (Validator::validate('SUPER-SECRET', 'XXXXXXXX', ['sha256', 0, 600])) {
    // Token is valid
}

```

###  Health Score

26

—

LowBetter than 43% of packages

Maintenance35

Infrequent updates — may be unmaintained

Popularity11

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity43

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~152 days

Total

3

Last Release

613d ago

PHP version history (2 changes)0.0.1PHP ^8.2

0.0.3PHP ^8.1

### Community

Maintainers

![](https://www.gravatar.com/avatar/b9f6add3e167ace14935760302662c9bba0945e2072a343629a4540e9867a012?d=identicon)[StefanZimmermann98](/maintainers/StefanZimmermann98)

---

Top Contributors

[![StefanZimmermann98](https://avatars.githubusercontent.com/u/47888671?v=4)](https://github.com/StefanZimmermann98 "StefanZimmermann98 (4 commits)")

### Embed Badge

![Health badge](/badges/stefan-z-laravel-totp/health.svg)

```
[![Health](https://phpackages.com/badges/stefan-z-laravel-totp/health.svg)](https://phpackages.com/packages/stefan-z-laravel-totp)
```

###  Alternatives

[namshi/jose

JSON Object Signing and Encryption library for PHP.

1.8k99.6M101](/packages/namshi-jose)[league/oauth1-client

OAuth 1.0 Client Library

99698.8M106](/packages/league-oauth1-client)[bezhansalleh/filament-shield

Filament support for `spatie/laravel-permission`.

2.8k2.9M88](/packages/bezhansalleh-filament-shield)[gesdinet/jwt-refresh-token-bundle

Implements a refresh token system over Json Web Tokens in Symfony

70516.4M35](/packages/gesdinet-jwt-refresh-token-bundle)[league/oauth2-google

Google OAuth 2.0 Client Provider for The PHP League OAuth2-Client

41721.2M118](/packages/league-oauth2-google)[illuminate/auth

The Illuminate Auth package.

9327.3M1.0k](/packages/illuminate-auth)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
