PHPackages                             kduma/eloquent-ulidable - 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. [Database &amp; ORM](/categories/database)
4. /
5. kduma/eloquent-ulidable

ActiveLibrary[Database &amp; ORM](/categories/database)

kduma/eloquent-ulidable
=======================

Eloquent Ulidable Trait

v3.0.0(2mo ago)041MITPHPPHP ^8.3

Since Jul 26Pushed 2mo agoCompare

[ Source](https://github.com/kduma-OSS/LV-eloquent-ulidable)[ Packagist](https://packagist.org/packages/kduma/eloquent-ulidable)[ RSS](/packages/kduma-eloquent-ulidable/feed)WikiDiscussions master Synced today

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

Eloquent ULID-able
==================

[](#eloquent-ulid-able)

[![Latest Stable Version](https://camo.githubusercontent.com/d5972c5d7c9608c59fd40e7183203a966a1aca65635de5171145bedd15abe205/68747470733a2f2f706f7365722e707567782e6f72672f6b64756d612f656c6f7175656e742d756c696461626c652f762f737461626c652e737667)](https://packagist.org/packages/kduma/eloquent-ulidable)[![Total Downloads](https://camo.githubusercontent.com/78c06e985e1e153cb111446b08a7f52aac2a649ae7d0c3f5741f6de5f79c25cf/68747470733a2f2f706f7365722e707567782e6f72672f6b64756d612f656c6f7175656e742d756c696461626c652f646f776e6c6f6164732e737667)](https://packagist.org/packages/kduma/eloquent-ulidable)[![License](https://camo.githubusercontent.com/a56235e4ac3e887c53a927c590763d1893e83d8adae5e2c7ff159b33ef815f02/68747470733a2f2f706f7365722e707567782e6f72672f6b64756d612f656c6f7175656e742d756c696461626c652f6c6963656e73652e737667)](https://packagist.org/packages/kduma/eloquent-ulidable)

Eloquent trait that adds a ULID as an additional column alongside the numeric `id` in Laravel models.

Full documentation: [opensource.duma.sh/libraries/php/eloquent-ulidable](https://opensource.duma.sh/libraries/php/eloquent-ulidable)

Requirements
------------

[](#requirements)

- PHP `^8.3`
- Laravel `^13.0`

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

[](#installation)

```
composer require kduma/eloquent-ulidable
```

Usage
-----

[](#usage)

```
use KDuma\Eloquent\Ulidable;
use KDuma\Eloquent\Attributes\HasUlid;

#[HasUlid(field: 'ulid')]
class Post extends Model
{
    use Ulidable;
}
```

Add a `ulid` column to your migration:

```
$table->ulid()->unique();
```

ULID is auto-generated on create. Find by ULID with `Post::whereUlid($ulid)` or `Post::byUlid($ulid)`.

> Unlike Laravel's built-in `HasUlids`, this package keeps the numeric `id` as the primary key and stores the ULID in a separate column.

###  Health Score

41

—

FairBetter than 87% of packages

Maintenance83

Actively maintained with recent releases

Popularity4

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity60

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

Total

2

Last Release

85d ago

Major Versions

v1.0.0 → v3.0.02026-04-08

PHP version history (2 changes)v1.0.0PHP &gt;=8.1

v3.0.0PHP ^8.3

### Community

Maintainers

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

---

Top Contributors

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

---

Tags

laravelphplaraveleloquentulid

### Embed Badge

![Health badge](/badges/kduma-eloquent-ulidable/health.svg)

```
[![Health](https://phpackages.com/badges/kduma-eloquent-ulidable/health.svg)](https://phpackages.com/packages/kduma-eloquent-ulidable)
```

###  Alternatives

[mongodb/laravel-mongodb

A MongoDB based Eloquent model and Query builder for Laravel

7.1k8.4M95](/packages/mongodb-laravel-mongodb)[kirschbaum-development/eloquent-power-joins

The Laravel magic applied to joins.

1.6k32.6M46](/packages/kirschbaum-development-eloquent-power-joins)[psalm/plugin-laravel

Psalm plugin for Laravel

3355.3M346](/packages/psalm-plugin-laravel)[yajra/laravel-oci8

Oracle DB driver for Laravel via OCI8

8793.2M25](/packages/yajra-laravel-oci8)[glushkovds/phpclickhouse-laravel

Adapter of the most popular library https://github.com/smi2/phpClickHouse to Laravel

2051.5M2](/packages/glushkovds-phpclickhouse-laravel)[watson/validating

Eloquent model validating trait.

9803.5M53](/packages/watson-validating)

PHPackages © 2026

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