PHPackages                             narekmarkosyan/laravel-admin-telegram-two-factor - 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. narekmarkosyan/laravel-admin-telegram-two-factor

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

narekmarkosyan/laravel-admin-telegram-two-factor
================================================

Add Telegram based two factor authentication to laravel-admin

v0.0.3(8mo ago)096MITPHPPHP &gt;=7.4.0

Since May 9Pushed 5mo agoCompare

[ Source](https://github.com/narekmarkosyan/laravel-admin-telegram-two-factor)[ Packagist](https://packagist.org/packages/narekmarkosyan/laravel-admin-telegram-two-factor)[ Docs](https://github.com/narekmarkosyan/laravel-admin-telegram-two-factor)[ RSS](/packages/narekmarkosyan-laravel-admin-telegram-two-factor/feed)WikiDiscussions master Synced 1w ago

READMEChangelog (3)Dependencies (2)Versions (4)Used By (0)

Telegram two-factor authentication for laravel-admin
====================================================

[](#telegram-two-factor-authentication-for-laravel-admin)

Inspired from

Adds two-factor authentication to admin login, admin will be sent a message in Telegram with a 6-digit code to complete sign in.

### Notes

[](#notes)

A new "telegram\_id" field is added to the database as laravel-admin does not have this by default. Once installed and migrations completed, you will need to set each user's telegram ID via the database. No way of doing it via UI has been implemented at this time.

### Installation

[](#installation)

```
composer require narekmarkosyan/laravel-admin-telegram-two-factor

```

### Migration

[](#migration)

Add telegram\_id field to admin users table.

```
php artisan migrate

```

### Configuration

[](#configuration)

In the extensions section of the `config/admin.php` file, add configurations

```
'extensions' => [
    'auth-telegram-two-factor' => [
        'enable' => (bool)env('ADMIN_AUTH_TELEGRAM_TWO_FACTOR', true),
        'botKey' => env('ADMIN_AUTH_TELEGRAM_TWO_FACTOR_BOT_KEY', true),
        'pinLength' => (int)env('ADMIN_AUTH_TELEGRAM_TWO_FACTOR_PIN_LENGTH', 6),
        'rememberDays' => (bool)env('ADMIN_AUTH_TELEGRAM_TWO_FACTOR_REMEMBER_DAYS', 1),
    ]
]

```

In the `.env` file, add configurations

```
ADMIN_AUTH_TELEGRAM_TWO_FACTOR=true
ADMIN_AUTH_TELEGRAM_TWO_FACTOR_BOT_KEY=123456789:AABBB_ZXCVBNMdfghjXCVvb_AA
ADMIN_AUTH_TELEGRAM_TWO_FACTOR_PIN_LENGTH=6
ADMIN_AUTH_TELEGRAM_TWO_FACTOR_REMEMBER_DAYS=1

```

### License

[](#license)

Licensed under [The MIT License (MIT)](LICENSE).

###  Health Score

33

—

LowBetter than 72% of packages

Maintenance67

Regular maintenance activity

Popularity13

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity37

Early-stage or recently created project

 Bus Factor1

Top contributor holds 84.6% 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 ~477 days

Total

3

Last Release

243d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/8b2ac2166622ca39b9f548ef6abdb99132814d87b13f9e0eb88027f3fb5a0945?d=identicon)[narekmarkosyan](/maintainers/narekmarkosyan)

---

Top Contributors

[![narekmarkosyan](https://avatars.githubusercontent.com/u/2436875?v=4)](https://github.com/narekmarkosyan "narekmarkosyan (11 commits)")[![shanerutter](https://avatars.githubusercontent.com/u/1963677?v=4)](https://github.com/shanerutter "shanerutter (2 commits)")

---

Tags

extensionlaravel-admin

### Embed Badge

![Health badge](/badges/narekmarkosyan-laravel-admin-telegram-two-factor/health.svg)

```
[![Health](https://phpackages.com/badges/narekmarkosyan-laravel-admin-telegram-two-factor/health.svg)](https://phpackages.com/packages/narekmarkosyan-laravel-admin-telegram-two-factor)
```

###  Alternatives

[aws/aws-sdk-php

AWS SDK for PHP - Use Amazon Web Services in your PHP project

6.2k555.0M2.8k](/packages/aws-aws-sdk-php)[backpack/crud

Quickly build admin interfaces using Laravel, Bootstrap and JavaScript.

3.4k3.8M228](/packages/backpack-crud)[neuron-core/neuron-ai

The PHP Agentic Framework.

2.0k832.6k55](/packages/neuron-core-neuron-ai)[tencentcloud/tencentcloud-sdk-php

TencentCloudApi php sdk

3661.3M49](/packages/tencentcloud-tencentcloud-sdk-php)[eslazarev/wildberries-sdk

Wildberries OpenAPI clients (generated).

353.6k](/packages/eslazarev-wildberries-sdk)[ellaisys/aws-cognito

Laravel Authentication using AWS Cognito (Web and API)

121269.8k1](/packages/ellaisys-aws-cognito)

PHPackages © 2026

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