PHPackages                             postscripton/laravel-money - 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. postscripton/laravel-money

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

postscripton/laravel-money
==========================

Laravel Money is an open source package that provides you a convinient way to work with numbers from database with high precision and use them as monetary objects. With this package, you can easily operate, compare, format, and even convert monetary objects to other currencies using external API providers.

v4.2.0(10mo ago)2019.6k—0%4[2 issues](https://github.com/PostScripton/laravel-money/issues)[1 PRs](https://github.com/PostScripton/laravel-money/pulls)MITPHPPHP ^8.1CI passing

Since Mar 26Pushed 10mo ago2 watchersCompare

[ Source](https://github.com/PostScripton/laravel-money)[ Packagist](https://packagist.org/packages/postscripton/laravel-money)[ RSS](/packages/postscripton-laravel-money/feed)WikiDiscussions 4.x Synced 1mo ago

READMEChangelog (10)Dependencies (5)Versions (23)Used By (0)

 [![Banner Logo](./.github/banner-logo.png)](./.github/banner-logo.png)

[ ![Release version](https://camo.githubusercontent.com/0a859487ff15a0e7444273f8df9b7398e62c096d55d169938ff1017ab88053b9/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f762f72656c656173652f506f73745363726970746f6e2f6c61726176656c2d6d6f6e65793f7374796c653d666f722d7468652d6261646765)](https://packagist.org/packages/postscripton/laravel-money)[ ![Total downloads](https://camo.githubusercontent.com/b783340e5438f880b2b35abf4c9f9c8cf362d456ae0e242a14ea530f898bbadb/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f706f73747363726970746f6e2f6c61726176656c2d6d6f6e65792e7376673f7374796c653d666f722d7468652d6261646765)](https://packagist.org/packages/postscripton/laravel-money)[ ![Downloads per month](https://camo.githubusercontent.com/9659ec8a83bde4d9dcbf7f5854ffd22a63225235302df7f3ce8442ae8b16f5bf/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f646d2f706f73747363726970746f6e2f6c61726176656c2d6d6f6e65793f7374796c653d666f722d7468652d6261646765)](https://packagist.org/packages/postscripton/laravel-money)[ ![License](https://camo.githubusercontent.com/c60e6db704aab23d6e09c4d7e692ab032177a8b0961c16c93d5a7734bea2052f/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6963656e73652f506f73745363726970746f6e2f6c61726176656c2d6d6f6e65793f7374796c653d666f722d7468652d6261646765)](./LICENSE.txt)

[ ![GitHub Workflow Status (branch)](https://camo.githubusercontent.com/154eb89d44c5ee954dcc8d8311399156c3c5008760a23474bd77b0dc0ec08217/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f616374696f6e732f776f726b666c6f772f7374617475732f506f73745363726970746f6e2f6c61726176656c2d6d6f6e65792f63692e796d6c3f6272616e63683d342e78266c6f676f3d676974687562267374796c653d666f722d7468652d6261646765) ](https://github.com/PostScripton/laravel-money/actions/workflows/ci.yml?query=branch%3A4.x)[ ![Coverage percent](https://camo.githubusercontent.com/29e86a0579219154eb813bf8a12a86e0769d2891329e49694d82f4b508fee2f0/68747470733a2f2f696d672e736869656c64732e696f2f636f6465636f762f632f67682f506f73745363726970746f6e2f6c61726176656c2d6d6f6e65792f342e783f746f6b656e3d563141434a52314e4d35266c6f676f3d636f6465636f76267374796c653d666f722d7468652d6261646765) ](https://codecov.io/gh/PostScripton/laravel-money)

Introduction
------------

[](#introduction)

💵 **Laravel Money** is an open source package that provides you a convinient way to work with numbers from database with high precision and use them as monetary objects. With this package, you can easily operate, compare, format, and even convert monetary objects to other currencies using external API providers.

Upgrade guide
-------------

[](#upgrade-guide)

- [`3.x` to `4.x`](/docs/upgrade/3.x_to_4.x.md)

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

[](#requirements)

- PHP: `^8.1`
- `guzzlehttp/guzzle`: `^7.5`
- `bcmath` extension

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

[](#installation)

```
composer require postscripton/laravel-money
```

### Publishing

[](#publishing)

Publish the config file through:

```
php artisan vendor:publish --provider=PostScription\Money\MoneyServiceProvider
```

or

```
php artisan vendor:publish --tag=money
```

After all, the config file at `config/money.php` should be modified for your own purposes.

Table of Contents
-----------------

[](#table-of-contents)

1. [⏰ Quick start](/docs/quick_start.md)
2. ✅ Usage
    - [🧰 Creating](/docs/01_usage/creating.md)
    - [🖨️ Output](/docs/01_usage/output.md)
    - [📄 Cloning](/docs/01_usage/cloning.md)
    - [🎯 Casting](/docs/01_usage/casting.md)
    - [🚨 Validation rule](/docs/01_usage/validation_rule.md)
3. [🎨️ Formatting](/docs/02_formatting/README.md)
4. [💲 Currencies](/docs/03_currencies/README.md)
    - [Default currency](/docs/03_currencies/default_currency.md)
    - [Information](/docs/03_currencies/information.md)
    - [Position](/docs/03_currencies/position.md)
    - [Display](/docs/03_currencies/display.md)
    - [Preferred symbol](/docs/03_currencies/preferred_symbol.md)
    - [Collection methods](/docs/03_currencies/collection_methods.md)
5. [💵 Money](/docs/04_money/README.md)
    - [💲 Currency](/docs/04_money/currency.md)
    - Static methods
        - [`Money::setFormatter()`](/docs/04_money/static/setFormatter.md)
        - [`Money::of()`](/docs/04_money/static/of.md)
        - [`Money::zero()`](/docs/04_money/static/zero.md)
        - [`Money::parse()`](/docs/04_money/static/parse.md)
        - [`Money::min()`](/docs/04_money/static/min.md)
        - [`Money::max()`](/docs/04_money/static/max.md)
        - [`Money::avg()`](/docs/04_money/static/avg.md)
        - [`Money::sum()`](/docs/04_money/static/sum.md)
    - Object methods
        - Getters
            - [`getAmount()`](/docs/04_money/object/getAmount.md)
        - Calculations
            - [`add()`](/docs/04_money/object/add.md)
            - [`subtract()`](/docs/04_money/object/subtract.md)
            - [`multiply()`](/docs/04_money/object/multiply.md)
            - [`divide()`](/docs/04_money/object/divide.md)
            - [`rebase()`](/docs/04_money/object/rebase.md)
        - Object manipulations
            - [`floor()`](/docs/04_money/object/floor.md)
            - [`ceil()`](/docs/04_money/object/ceil.md)
            - [`absolute()`](/docs/04_money/object/absolute.md)
            - [`negate()`](/docs/04_money/object/negate.md)
            - [`clone()`](/docs/04_money/object/clone.md)
        - Logical operations
            - [Comparing currencies](/docs/04_money/object/comparing_currencies.md)
            - [`isNegative()`](/docs/04_money/object/isNegative.md)
            - [`isPositive()`](/docs/04_money/object/isPositive.md)
            - [`isZero()`](/docs/04_money/object/isZero.md)
            - [`lessThan()`](/docs/04_money/object/lessThan.md)
            - [`lessThanOrEqual()`](/docs/04_money/object/lessThanOrEqual.md)
            - [`greaterThan()`](/docs/04_money/object/greaterThan.md)
            - [`greaterThanOrEqual()`](/docs/04_money/object/greaterThanOrEqual.md)
            - [`equals()`](/docs/04_money/object/equals.md)
        - [Converting to string](/docs/02_formatting/README.md#other-to-string-methods)
        - [Converting currencies](/docs/04_money/object/converting_currencies.md)
6. [API rate exchangers](/docs/05_rate_exchangers/README.md)
    - [Add your own](/docs/05_rate_exchangers/add.md)

License
-------

[](#license)

Laravel-money is an open-source library under the [MIT license](/LICENSE.txt).

###  Health Score

46

—

FairBetter than 93% of packages

Maintenance52

Moderate activity, may be stable

Popularity35

Limited adoption so far

Community12

Small or concentrated contributor base

Maturity70

Established project with proven stability

 Bus Factor1

Top contributor holds 99.3% 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 ~71 days

Recently: every ~226 days

Total

23

Last Release

306d ago

Major Versions

1.1.0 → 2.0.02021-04-28

2.2.1 → 3.02021-08-22

v3.2.4 → v4.0.02023-01-22

3.x-dev → v4.1.02023-03-07

PHP version history (5 changes)1.0.0PHP &gt;=7.1

1.0.2PHP ^7.1

2.0.0PHP ^7.4

3.0PHP ^7.4|^8.0

v4.0.0PHP ^8.1

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/68855126?v=4)[Sergey Podzemelnykh](/maintainers/PostScripton)[@PostScripton](https://github.com/PostScripton)

---

Top Contributors

[![PostScripton](https://avatars.githubusercontent.com/u/68855126?v=4)](https://github.com/PostScripton "PostScripton (293 commits)")[![AndreyDemenenko](https://avatars.githubusercontent.com/u/14270217?v=4)](https://github.com/AndreyDemenenko "AndreyDemenenko (2 commits)")

---

Tags

convert-numberscurrencydatabaseexchage-ratesformattinglaravelmoneymoney-converterphprate-exchange

###  Code Quality

Code StylePHP\_CodeSniffer

### Embed Badge

![Health badge](/badges/postscripton-laravel-money/health.svg)

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

###  Alternatives

[kreait/firebase-php

Firebase Admin SDK

2.4k39.7M72](/packages/kreait-firebase-php)[spatie/laravel-model-flags

Add flags to Eloquent models

4301.1M1](/packages/spatie-laravel-model-flags)[clickbar/laravel-magellan

This package provides functionality for working with the postgis extension in Laravel.

423715.4k1](/packages/clickbar-laravel-magellan)[wnx/laravel-backup-restore

A package to restore database backups made with spatie/laravel-backup.

203330.1k2](/packages/wnx-laravel-backup-restore)[tpetry/laravel-mysql-explain

Get Visual MySQL EXPLAIN for Laravel.

264154.2k](/packages/tpetry-laravel-mysql-explain)[lacodix/laravel-model-filter

A Laravel package to filter, search and sort models with ease while fetching from database.

17649.9k](/packages/lacodix-laravel-model-filter)

PHPackages © 2026

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