PHPackages                             seguce92/laravel-hashid - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. seguce92/laravel-hashid

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

seguce92/laravel-hashid
=======================

Hashid for Laravel framework.

v2.2.1(7y ago)02041MITPHP

Since May 2Pushed 7y ago1 watchersCompare

[ Source](https://github.com/seguce92/laravel-hashid)[ Packagist](https://packagist.org/packages/seguce92/laravel-hashid)[ RSS](/packages/seguce92-laravel-hashid/feed)WikiDiscussions master Synced 4d ago

READMEChangelogDependencies (1)Versions (9)Used By (1)

Laravel-Hashid
==============

[](#laravel-hashid)

Install
-------

[](#install)

```
$ composer require seguce92/laravel-hashid
```

Add service provider in 'config/app.php'

```
'providers' => [
    ...
    Seguce92\LaravelHashid\ServiceProvider::class,
    ...
],
```

Add alias in 'config/app.php' (optionnal)

```
'aliases' => [
    ...
    'Hashid' => Seguce92\LaravelHashid\Facade::class,
    ...
],
```

Publish configuration

```
$ php artisan vendor:publish
```

Configuration
-------------

[](#configuration)

```
/**
 * Min lenght of generated Hashid
 */
'min_lenght' => 8,

/*
 * Alphabet use in Hashid generation
 */
'alphabet'   => 'aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ0123456789',
```

Usage
-----

[](#usage)

```
// without custom value salt (default is app key and 'laravel-hashid')
$hashid = Hashid::encode($id); // return string

$id = Hashid::decode($hasid); // return integer

// with custom value salt
$hashid = Hashid::encode($id, $salt); // return string

$id = Hashid::decode($hasid, $salt); // return integer
```

###  Health Score

30

—

LowBetter than 62% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity11

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity68

Established project with proven stability

 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 ~112 days

Recently: every ~182 days

Total

8

Last Release

2563d ago

Major Versions

v1.2 → v2.02017-06-25

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/7014932?v=4)[Sergio G. Cruz Espinoza](/maintainers/seguce92)[@seguce92](https://github.com/seguce92)

---

Top Contributors

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

---

Tags

laravelhashidseguce92

### Embed Badge

![Health badge](/badges/seguce92-laravel-hashid/health.svg)

```
[![Health](https://phpackages.com/badges/seguce92-laravel-hashid/health.svg)](https://phpackages.com/packages/seguce92-laravel-hashid)
```

###  Alternatives

[vinkla/hashids

A Hashids bridge for Laravel

2.1k13.9M78](/packages/vinkla-hashids)[ashallendesign/short-url

A Laravel package for creating shortened URLs for your web apps.

1.4k2.2M5](/packages/ashallendesign-short-url)[deligoez/laravel-model-hashid

Generate, Save, and Route Stripe/Youtube-like Hash IDs for Laravel Eloquent Models

166114.2k](/packages/deligoez-laravel-model-hashid)[torann/hashids

Laravel package for Hashids

54341.1k](/packages/torann-hashids)[balping/laravel-hashslug

Package providing a trait to use Hashids on a model

25189.6k2](/packages/balping-laravel-hashslug)[solspace/craft-freeform

The most flexible and user-friendly form building plugin!

53675.5k17](/packages/solspace-craft-freeform)

PHPackages © 2026

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