Skip to content

Prototype

PHP Hijri or Laravel Hijri

Do you need the Hijri library on its own, or its Laravel integration?

Facts checked against the source on . Releases, requirements and lines are read live from each package's latest release.

PHP Hijri or Laravel Hijri: facts side by side
PHP HijriLaravel Hijri
Choose it whenYou are not on Laravel, or you only need conversions and Carbon methods.You are on Laravel and want casts, validation, Blade output and config. It installs PHP Hijri for you.
What it isHijri dates for any PHP code, as a Carbon mixin (HijriCarbon) and a Gregorian/Hijri converter. Sourcefor What it is (opens in a new tab)The Laravel integration of PHP Hijri: it registers the Carbon mixin and the day adjustment for you. Sourcefor What it is (opens in a new tab)
Laravel featuresNone. Call it from any framework or plain PHP. Sourcefor Laravel features (opens in a new tab)@hijri Blade directive, <x-hijri-date> component, AsHijri Eloquent cast, HijriDateRule validation rule, config and translations. Sourcefor Laravel features (opens in a new tab)
Day adjustmentSet in code: globally with HijriAdjustment::set(), or per call (the $adjustment argument of Hijri::fromGregorian()). Sourcefor Day adjustment (opens in a new tab)From config: pharaonic.hijri.adjustment (HIJRI_ADJUSTMENT), -1 by default. Sourcefor Day adjustment (opens in a new tab)
Installcomposer require pharaonic/php-hijricomposer require pharaonic/laravel-hijri
Latest releasev8.5.6v13.1.0
Released on2026-10-082026-10-08
RequiresPHP 8.5PHP 8.3 – 8.5, Laravel 13
Maintained linesv8.5.x, v8.4.x, v8.3.x, v8.2.x, v8.1.x, v8.0.xv13.x, v12.x, v11.x, v10.x, v9.x, v8.x, v7.x, v6.x
Other dependenciesnesbot/carbonpharaonic/php-hijri
LicenseMITMIT

Limitations

  • Both use a tabular Hijri calendar. Local moon sighting can differ by a day or two, which is what the adjustment is for.

This comparison only covers Pharaonic packages and states what their code does. It doesn't rate them or measure performance. Spotted something out of date? Report it.