Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Money Laravel Package

brick/money

Immutable money & currency library for PHP with exact arithmetic, explicit rounding control, and support for any-sized amounts. Built on brick/math to avoid floating-point errors; works with ISO currencies and integrates well with GMP/BCMath for speed.

View on GitHub
Deep Wiki
Context7

Product Decisions This Supports

  • Financial precision requirements: Eliminates floating-point rounding errors in monetary calculations (e.g., e-commerce, fintech, accounting systems).
  • Multi-currency support: Enables seamless handling of ISO 4217-compliant currencies with exact arithmetic (e.g., global payment platforms, FX services).
  • Context-aware operations: Supports cash rounding (e.g., Swiss Franc increments), custom scales (e.g., cryptocurrencies), or auto-scaling for intermediate calculations.
  • Allocation/splitting logic: Facilitates profit-sharing, tax distribution, or invoice splitting (e.g., SaaS billing, revenue-sharing models).
  • Immutable design: Safeguards against unintended state changes in concurrent systems (e.g., microservices, distributed ledgers).
  • Roadmap acceleration: Reduces dev time for financial features (e.g., "Build vs. Buy" decision for core monetary logic).
  • Compliance/auditability: Ensures reproducible calculations for regulatory reporting (e.g., GDPR, financial audits).

When to Consider This Package

  • Avoid if:
    • Your use case requires only basic arithmetic (e.g., simple price tags) and floating-point precision is acceptable.
    • You’re using non-ISO currencies (e.g., internal tokens) without extension plans.
    • Your team lacks PHP expertise or prefers type-safe alternatives (e.g., Rust’s rust_decimal).
    • You need blockchain-specific features (e.g., satoshis, gas calculations) beyond generic monetary ops.
  • Look elsewhere if:
    • You require real-time FX conversion (integrate with a service like ExchangeRate-API).
    • Your stack is non-PHP (e.g., Python’s decimal module, Java’s BigDecimal).
    • You need graphical UI components (pair with a frontend library like react-money-format).

How to Pitch It (Stakeholders)

Executives: "Brick\Money solves a critical technical debt risk: floating-point errors in financial calculations can silently corrupt transactions, leading to compliance violations or revenue loss. This MIT-licensed library provides battle-tested, immutable monetary operations—used by 1.9K+ devs—so we can ship features like multi-currency checkout or profit allocation faster and safer than building from scratch. It’s a strategic ‘buy’ to avoid rework in high-stakes areas like payments or accounting."

Engineering: *"This replaces ad-hoc float math with exact arithmetic for money, supporting:

  • Immutable objects (thread-safe, predictable).
  • Contexts for cash rounding (e.g., CHF), custom scales (e.g., crypto), or auto-scaling.
  • Allocation/splitting for complex distributions (e.g., revenue share).
  • Zero floating-point surprises—ever seen 0.1 + 0.2 !== 0.3 in production? Tradeoff: ~50KB overhead vs. weeks of dev time. Docs are solid, and the team maintains it actively (last release: 2026)."*
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
davejamesmiller/laravel-breadcrumbs
artisanry/parsedown
christhompsontldr/phpsdk
enqueue/dsn
bunny/bunny
enqueue/test
enqueue/null
enqueue/amqp-tools
bower-asset/punycode
bower-asset/inputmask
bower-asset/jquery
bower-asset/yii2-pjax
laravel/nova
spatie/laravel-mailcoach
spatie/laravel-superseeder
laravel/liferaft
nst/json-test-suite
danielmiessler/sec-lists
jackalope/jackalope-transport
twbs/bootstrap4