PHPackages                             fridzema/laravel-date-format-converter - 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. fridzema/laravel-date-format-converter

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

fridzema/laravel-date-format-converter
======================================

Converts date format from js to php and the other way around

0.0.3(3mo ago)11.0kMITPHPPHP ^8.2CI failing

Since Mar 21Pushed 3mo ago1 watchersCompare

[ Source](https://github.com/fridzema/laravel-date-format-converter)[ Packagist](https://packagist.org/packages/fridzema/laravel-date-format-converter)[ Docs](https://github.com/fridzema/laravel-date-format-converter)[ GitHub Sponsors]()[ RSS](/packages/fridzema-laravel-date-format-converter/feed)WikiDiscussions main Synced today

READMEChangelog (2)Dependencies (24)Versions (5)Used By (0)

Converts date format from js to php and the other way around
============================================================

[](#converts-date-format-from-js-to-php-and-the-other-way-around)

[![Latest Version on Packagist](https://camo.githubusercontent.com/e2427853a04f011d38d8ae22c91e00ef26aedcbd5faf3154d1f399e67aa5bee0/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f667269647a656d612f6c61726176656c2d646174652d666f726d61742d636f6e7665727465722e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/fridzema/laravel-date-format-converter)[![GitHub Tests Action Status](https://camo.githubusercontent.com/ca28bd28038098e4690b5099453f6b51343aeb1272c3b403b5595e0c6b45cc08/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f667269647a656d612f6c61726176656c2d646174652d666f726d61742d636f6e7665727465722f72756e2d74657374732e796d6c3f6272616e63683d6d61696e266c6162656c3d7465737473267374796c653d666c61742d737175617265)](https://github.com/fridzema/laravel-date-format-converter/actions?query=workflow%3Arun-tests+branch%3Amain)[![GitHub Code Style Action Status](https://camo.githubusercontent.com/7a676c2d471589629727b19ad71e232c578d4fe3762b70ff80b2abe3ab92dca5/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f667269647a656d612f6c61726176656c2d646174652d666f726d61742d636f6e7665727465722f6669782d7068702d636f64652d7374796c652d6973737565732e796d6c3f6272616e63683d6d61696e266c6162656c3d636f64652532307374796c65267374796c653d666c61742d737175617265)](https://github.com/fridzema/laravel-date-format-converter/actions?query=workflow%3A%22Fix+PHP+code+style+issues%22+branch%3Amain)[![Total Downloads](https://camo.githubusercontent.com/7f9073b27c30da8c0b81c9088ddcce97bcdfd7b72bc7586721eb81321307a4ae/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f667269647a656d612f6c61726176656c2d646174652d666f726d61742d636f6e7665727465722e7376673f7374796c653d666c61742d737175617265)](https://packagist.org/packages/fridzema/laravel-date-format-converter)

Really simple package to convert js date format to php date format and the other way around.

```
    use Fridzema\DateFormatConverter\DateFormatConverter;

    it('converts JavaScript date formats to PHP date formats', function () {
        expect(DateFormatConverter::convertJsFormatToPhp('YYYY-MM-DD'))->toEqual('Y-m-d');
    });

    it('converts PHP date formats to JavaScript date formats', function () {
        expect(DateFormatConverter::convertPhpFormatToJs('Y-m-d'))->toEqual('YYYY-MM-DD');
    });
```

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

[](#installation)

You can install the package via composer:

```
composer require fridzema/laravel-date-format-converter
```

You can publish the config file with:

```
php artisan vendor:publish --tag="laravel-date-format-converter-config"
```

Usage
-----

[](#usage)

```
$dateFormatConverter = new Fridzema\DateFormatConverter();

echo DateFormatConverter::convertPhpFormatToJs('Y-m-d');
echo DateFormatConverter::convertJsFormatToPhp('YYYY-MM-DD');
```

Testing
-------

[](#testing)

```
composer test
```

Changelog
---------

[](#changelog)

Please see [CHANGELOG](CHANGELOG.md) for more information on what has changed recently.

Contributing
------------

[](#contributing)

Please see [CONTRIBUTING](CONTRIBUTING.md) for details.

Security Vulnerabilities
------------------------

[](#security-vulnerabilities)

Please review [our security policy](../../security/policy) on how to report security vulnerabilities.

Credits
-------

[](#credits)

- [Robert Fridzema](https://github.com/fridzema)
- [All Contributors](../../contributors)

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.

###  Health Score

41

—

FairBetter than 87% of packages

Maintenance80

Actively maintained with recent releases

Popularity20

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity47

Maturing project, gaining track record

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

Total

3

Last Release

107d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/8180660?v=4)[Robert Fridzema](/maintainers/fridzema)[@fridzema](https://github.com/fridzema)

---

Top Contributors

[![fridzema](https://avatars.githubusercontent.com/u/8180660?v=4)](https://github.com/fridzema "fridzema (11 commits)")

---

Tags

laravelformatdateRobert Fridzemalaravel-date-format-converter

###  Code Quality

TestsPest

Static AnalysisPHPStan

Code StyleLaravel Pint

### Embed Badge

![Health badge](/badges/fridzema-laravel-date-format-converter/health.svg)

```
[![Health](https://phpackages.com/badges/fridzema-laravel-date-format-converter/health.svg)](https://phpackages.com/packages/fridzema-laravel-date-format-converter)
```

###  Alternatives

[spatie/laravel-pdf

Create PDFs in Laravel apps

1.0k4.8M47](/packages/spatie-laravel-pdf)[codewithdennis/filament-select-tree

The multi-level select field enables you to make single selections from a predefined list of options that are organized into multiple levels or depths.

329530.5k29](/packages/codewithdennis-filament-select-tree)[rawilk/profile-filament-plugin

Profile &amp; MFA starter kit for filament.

3914.6k](/packages/rawilk-profile-filament-plugin)[worksome/exchange

Check Exchange Rates for any currency in Laravel.

124603.0k](/packages/worksome-exchange)[tarfin-labs/event-machine

Event-driven state machines for Laravel with event sourcing, type-safe context, and full audit trail.

199.4k](/packages/tarfin-labs-event-machine)

PHPackages © 2026

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