PHPackages                             junityco/laravel-hashids - 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. junityco/laravel-hashids

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

junityco/laravel-hashids
========================

A Hashids service provider for Laravel

1.5(9y ago)14.1k1MITPHPPHP ^5.6.4 || ^7.0

Since Feb 17Pushed 9y ago1 watchersCompare

[ Source](https://github.com/junityco/laravel-hashids)[ Packagist](https://packagist.org/packages/junityco/laravel-hashids)[ Docs](http://hashids.org/php)[ RSS](/packages/junityco-laravel-hashids/feed)WikiDiscussions master Synced 4d ago

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

Hashids for Laravel
===================

[](#hashids-for-laravel)

**Hashids** is small PHP library to generate YouTube-like ids from numbers. Use it when you don't want to expose your database ids to the user:

[![Total Downloads](https://camo.githubusercontent.com/28d0ff8605500136e763f6c2534d9116d4cfe4ee70e342d4228fc89b979b8205/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f646d2f6a756e697479636f2f6c61726176656c2d686173686964732e7376673f7374796c653d666c6174)](https://packagist.org/packages/junityco/laravel-hashids)[![Latest Version](https://camo.githubusercontent.com/cc240a94aee56bde3e70099a84240e3bfedd6bed72f8f39d36c7f27a42b313be/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6a756e697479636f2f6c61726176656c2d686173686964732e7376673f7374796c653d666c6174)](https://github.com/junityco/laravel-hashids/releases)[![License](https://camo.githubusercontent.com/63819dad81f20325a23906d88dcb192864de15234f8e1b55884d2ebaf39f62f9/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f6c2f6a756e697479636f2f6c61726176656c2d686173686964732e7376673f7374796c653d666c6174)](https://packagist.org/packages/junityco/laravel-hashids)

Installation
------------

[](#installation)

Require this package, with [Composer](https://getcomposer.org/), in the root directory of your project.

```
$ composer require junityco/laravel-hashids
```

Add the service provider to `config/app.php` in the `providers` array.

```
Junity\Hashids\HashidsServiceProvider::class
```

If you want you can use the [facade](http://laravel.com/docs/facades). Add the reference in `config/app.php` to your aliases array.

```
'Hashids' => Junity\Hashids\Facades\Hashids::class
```

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

[](#configuration)

Laravel Hashids requires connection configuration. To get started, you'll need to publish all vendor assets:

```
$ php artisan vendor:publish --provider="Junity\Hashids\HashidsServiceProvider"
```

This will create a `config/hashids.php` file in your app that you can modify to set your configuration. Also, make sure you check for changes to the original config file in this package between releases.

Quick Example
-------------

[](#quick-example)

```
use Junity\Hashids\Facades\Hashids;

$id = Hashids::encode(1, 2, 3); // o2fXhV
$numbers = Hashids::decode($id); // [1, 2, 3]
```

There are other methods in this package that are not documented here. For documentation visit the [Hashids package](https://github.com/ivanakimov/hashids.php) homepage.

###  Health Score

31

—

LowBetter than 66% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity20

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity62

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

Total

6

Last Release

3423d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/3335268?v=4)[Junity](/maintainers/Junity)[@junity](https://github.com/junity)

---

Top Contributors

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

---

Tags

hashidslaravelphphashyoutubeencodedecodebitlyidshashidsobfuscatehashid

### Embed Badge

![Health badge](/badges/junityco-laravel-hashids/health.svg)

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

###  Alternatives

[hashids/hashids

Generate short, unique, non-sequential ids (like YouTube and Bitly) from numbers

5.4k52.1M316](/packages/hashids-hashids)[psalm/plugin-laravel

Psalm plugin for Laravel

3355.3M345](/packages/psalm-plugin-laravel)[illuminate/pagination

The Illuminate Pagination package.

12234.1M1.0k](/packages/illuminate-pagination)[illuminate/pipeline

The Illuminate Pipeline package.

9349.2M282](/packages/illuminate-pipeline)[illuminate/redis

The Illuminate Redis package.

8314.6M375](/packages/illuminate-redis)[delight-im/ids

Short, obfuscated and efficient IDs for PHP

2810.1k1](/packages/delight-im-ids)

PHPackages © 2026

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