PHPackages                             terdelyi/laravel-localedate - 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. [Localization &amp; i18n](/categories/localization)
4. /
5. terdelyi/laravel-localedate

Abandoned → [carbonnesbot/carbon](/?search=carbonnesbot%2Fcarbon)ArchivedLibrary[Localization &amp; i18n](/categories/localization)

terdelyi/laravel-localedate
===========================

Simple date localization for Laravel.

v1.0.1(8y ago)263062MITPHPPHP &gt;=5.6

Since May 1Pushed 6y ago1 watchersCompare

[ Source](https://github.com/terdelyi/laravel-localedate)[ Packagist](https://packagist.org/packages/terdelyi/laravel-localedate)[ RSS](/packages/terdelyi-laravel-localedate/feed)WikiDiscussions master Synced 1w ago

READMEChangelog (1)Dependencies (5)Versions (3)Used By (0)

LocaleDate for Laravel 5.\*
===========================

[](#localedate-for-laravel-5)

[![Build Status](https://camo.githubusercontent.com/c7600f6ecd87de0f4051b2c2c25c3adea247c4a1b88ab99620cd373e9e0abbf4/68747470733a2f2f7472617669732d63692e6f72672f74657264656c79692f6c61726176656c2d6c6f63616c65646174652e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/terdelyi/laravel-localedate)

> IMPORTANT! From Laravel 5.8 the framework is supporting Carbon 2 by default which has a [better and nicer solution](https://carbon.nesbot.com/docs/#api-localization) for localising dates therefor this package lost its purpose and is no longer supported.

### What's this?

[](#whats-this)

Simple date localization for Laravel.

### Why?

[](#why)

As you probably know Laravel has a built-in support for translations. It's very good if you want to display text in different languages. But what about dates?

Laravel uses [Carbon](http://carbon.nesbot.com/) for dates, but when you change the `locale` setting in `config/app.php` it won't affect the textual representation of dates, like `diffForHumans` or `formatLocalized` methods in Carbon. With this package you can synchronize your locale setting with Carbon and [PHP's setlocale method](http://php.net/manual/en/function.setlocale.php).

### Ok, I got it, now what?

[](#ok-i-got-it-now-what)

Firstly you need to install the package with Composer:

```
composer require terdelyi/laravel-localedate
```

or add it to your `composer.json` file:

```
"require": {
    "terdelyi/laravel-localedate": "1.*"
}
```

After `composer update` add `Terdelyi\LocaleDate\LocaleDateServiceProvider::class` to the providers array in `config/app.php`.

### Is there anything more what I should know?

[](#is-there-anything-more-what-i-should-know)

Because different systems (MacOs, Windows, Linux) have different naming schemes for locales, date formatting uses a `locales.php` config file to override them. You can easily publish this config file into your application:

```
php artisan vendor:publish --provider="Terdelyi\LocaleDate\LocaleDateServiceProvider"
```

Now set up the correct locale value in `config/app.php` and check that you have a valid reference to the key in `locales.php`. If everything goes well you'll get localized dates with:

```
Carbon::now()->diffForHumans(Carbon::now()->subYear()) // this gives back '1 year later'
```

And so:

```
Carbon::createFromDate(2016,6,9)->formatLocalized('%A') // this gives back 'thursday'
```

### Change locale on runtime

[](#change-locale-on-runtime)

If you want to change locale setting on runtime, you can use:

```
App::setlocale()
```

Because the package is watching the event what is fired with this method and does what is necessary.

###  Health Score

31

—

LowBetter than 65% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity22

Limited adoption so far

Community13

Small or concentrated contributor base

Maturity59

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 66.7% 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 ~289 days

Total

2

Last Release

3103d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/623128?v=4)[Tamas Erdelyi](/maintainers/terdelyi)[@terdelyi](https://github.com/terdelyi)

---

Top Contributors

[![terdelyi](https://avatars.githubusercontent.com/u/623128?v=4)](https://github.com/terdelyi "terdelyi (6 commits)")[![fridzema](https://avatars.githubusercontent.com/u/8180660?v=4)](https://github.com/fridzema "fridzema (1 commits)")[![imliam](https://avatars.githubusercontent.com/u/4326337?v=4)](https://github.com/imliam "imliam (1 commits)")[![lex111](https://avatars.githubusercontent.com/u/4408379?v=4)](https://github.com/lex111 "lex111 (1 commits)")

---

Tags

laravellocalizationdate

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/terdelyi-laravel-localedate/health.svg)

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

###  Alternatives

[laravel/horizon

Dashboard and code-driven configuration for Laravel queues.

4.2k99.8M351](/packages/laravel-horizon)[laravel/cashier

Laravel Cashier provides an expressive, fluent interface to Stripe's subscription billing services.

2.6k31.8M158](/packages/laravel-cashier)[psalm/plugin-laravel

Psalm plugin for Laravel

3345.4M354](/packages/psalm-plugin-laravel)[laravel/ai

The official AI SDK for Laravel.

1.1k4.6M307](/packages/laravel-ai)[moonshine/moonshine

Laravel administration panel

1.3k268.2k88](/packages/moonshine-moonshine)[illuminate/translation

The Illuminate Translation package.

6938.5M618](/packages/illuminate-translation)

PHPackages © 2026

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