Elestia Open Source Ratings
7.2

Dinero.js

A strong pick. 3rd of 8 numbers and money.

Dinero.js is a money library for JavaScript and TypeScript. It stores amounts as integers in minor units with a currency, and it reached a stable v2 (a full TypeScript rewrite with standalone functions) in March 2026. Of the maintained libraries built for money rather than for general decimal math, it is the best designed. It still rests mostly on one maintainer and has little independent validation.

Best for: TypeScript teams that build billing, checkout or accounting features and want currency-safe money values and lossless allocation, not raw decimal math.

WebsiteGitHubnpm

Scores

Overall7.2

How strongly do we recommend it for a new project today?

Claude Opus 5.5: 7.0, likely 6.0 to 8.0

For money logic in TypeScript, it is the clearest choice among the peers. currency.js is unmaintained, and decimal.js, big.js and bignumber.js give no currency model or allocation. It is held back by one main maintainer, thin independent validation, a v2 that is only months old, and reach that is not growing faster than the market. Use decimal.js or bignumber.js when you need general decimal math instead.

GPT-6.2 Sol: 7.3, likely 6.2 to 8.5

Dinero.js is a stronger choice than currency.js for projects that need typed currencies and BigInt. Decimal.js is a better fit for general decimal arithmetic. For new money code, the BigInt entry point makes Dinero.js a strong pick, with the default backend’s allocation bug and the gap since the last release limiting the recommendation.

Needed by many4.4

How many developers need a tool for this job?

Claude Opus 5.5: 4.5, likely 3.5 to 5.5

Only projects that handle money need it, such as e-commerce, billing and fintech. That is a clear but sizeable subset of the category. It does no general decimal math or number formatting, which most other peers cover.

GPT-6.2 Sol: 4.3, likely 3.2 to 5.5

Checkout, billing, and finance apps benefit from amounts that carry their currency and scale. Dinero.js works across frameworks, while general decimal arithmetic and display-only formatting call for different tools. The share of JavaScript projects that need this money model is hard to measure.

Helps a lot7.5

How well does it do the job for those who need it?

Claude Opus 5.5: 7.5, likely 6.5 to 8.5

v2 has a careful design: immutable values, structured currencies, compile-time currency safety, lossless allocate, and BigInt or custom calculators. Its stricter model (minor units, scaled multipliers, no divide) has a learning curve. Open issues report edge cases in allocate and toDecimal, and docs examples that the code does not support.

GPT-6.2 Sol: 7.5, likely 6.4 to 8.6

Version 2.0.2 offers typed currencies, automatic scale tracking, and several rounding modes. Ducat’s comparison found a small bundle and stronger correctness results with BigInt, though some operations were slower in its benchmarks. An independent audit reproduced silent misallocation in the default backend. Version-specific guidance is available for coding agents, but reported mistakes in the rounding examples make copied code less reliable.

Holds up over time6.5

Will it still be a good choice in two years?

Claude Opus 5.5: 6.5, likely 5.0 to 7.5

The repository is active, with 207 commits and 6 releases last year. v2 finally became stable after years in alpha, and releases now run through CI. It depends heavily on one maintainer who works on it unpaid, beside a full-time job. Only 4 issues are open, but 33 pull requests are waiting.

GPT-6.2 Sol: 6.5, likely 5.2 to 7.8

The repository recorded 207 commits in the past year, and the March v2 launch was followed by two quick fixes. The npm release cadence then slowed, and the allocation fix was still open in November. The v1 migration is substantial, and the public record shows one lead maintainer with limited visibility into backup release access or funding.

Used widely4.3

How many use it, and is that growing?

Claude Opus 5.5: 5.0, likely 4.0 to 6.0

About 3.9M downloads in 4 weeks, up 3.7x in a year. That is just below the 4.1x median, so it is not quite gaining ground. It has 408 dependent repositories, fewer than currency.js (707) and far fewer than the general decimal libraries. Part of the downloads still comes from v1 installs in older projects.

  • npm downloadsLast4Weeks: 3,876,234, against 1,045,317 a year ago (ratio 3.7)
  • dependents: 408 repos and 65 packages
  • peers currency.js: Similar downloads (3.8M) and more dependent repositories (707)
  • bluesky posts: Only 2 posts, both low-engagement star notices

GPT-6.2 Sol: 3.5, likely 2.2 to 4.8

Four-week npm installs rose from 1.05 million to 3.88 million, or 3.71×, below the catalog’s 4.1× median. The package grew faster than currency.js, which still has more tracked dependent repositories. With 408 repositories and 65 packages tracked, plus two Bluesky posts, direct reach looks modest and remains hard to estimate from installs across both major versions.

  • npm.downloadsLast4Weeks, npm.downloadsSame4WeeksYearAgo, medianDownloadsRatio: Install growth trailed the catalog baseline.
  • dependents, peers: 408 tracked repositories versus 707 for currency.js and far more for decimal.js.
  • bluesky.posts, github.stars: Two recent posts alongside 6,817 accumulated stars.
Vouched for5.1

Who stands behind it being good?

Claude Opus 5.5: 4.0, likely 2.5 to 5.5

It is often recommended in independent money-handling articles and comparison sites, and it has 6.8k stars. I found no named production users, survey data or independent benchmarks, and there are no Hacker News stories. Most endorsements predate v2.

GPT-6.2 Sol: 6.1, likely 4.9 to 7.3

WooCommerce ships its Blocks package with a v2 dependency, and Cypress uses v2 in its example payment app. External testing found that BigInt handled more cases correctly than the number backend. Current developer satisfaction data and further confirmed production use are sparse.

Safe7.3

How safe is it to depend on?

Claude Opus 5.5: 7.5, likely 6.5 to 8.5

It has no advisories ever, zero dependencies and an MIT licence. Releases are published from GitHub Actions. The Scorecard is weak at 4, with 0 on code review, token permissions, security policy and SAST. Maintained also scores 0, although the repository is active.

  • advisories total: 0 advisories
  • npm dependencies: 0 runtime dependencies
  • scorecard score: 4/10; Code-Review, Security-Policy, Token-Permissions and SAST all 0
  • github.com/dinerojs/dinero.js/releases: v2 releases published by the github-actions bot

GPT-6.2 Sol: 7.1, likely 5.9 to 8.3

Dinero.js has an MIT licence, zero runtime dependencies, and no recorded OSV advisories. GitHub Actions gates releases on tests, and the release job is configured for identity-based publishing. The 4/10 Scorecard flags weak code-review, token-permission, and action-pinning checks. The repository has no published security policy, and the number of people with publish access could not be verified.

Good

  • Typed currencies make mixing currencies in add or subtract a compile-time error.
  • allocate splits amounts by ratios without losing cents, and BigInt and custom calculators handle very large amounts.
  • Zero runtime dependencies, MIT licence, tree-shakeable functions and types shipped in the package.
  • Releases come from a CI pipeline, and the project ships agent skills that teach coding agents to use v2 correctly.

Bad

  • v2 broke most of the v1 API: divide, percentage and toFormat are gone, and v1 tutorials and AI-generated code often no longer apply.
  • Integer minor units and scaled multipliers take more thought than currency.js's float-friendly API.
  • Formatting is left to Intl.NumberFormat, so it does not replace a number-formatting library.
  • Development rests mostly on one maintainer, and 33 pull requests are open.

The numbers

npm downloads, 4 weeks
3.9M ×3.7 in a year
GitHub stars
6.8k
Commits, 12 months
207
npm version
2.0.2 Mar 2026
Versions, 12 months
3
Advisories, 24 months
0 of 0 ever
OpenSSF Scorecard
4.0 out of 10, Nov 2026
Licence
MIT

Read on 21 November 2026 from GitHub (dinerojs/dinero.js), npm (dinero.js), OSV and the OpenSSF Scorecard.

Numbers and money

  1. 7.5decimal.js
  2. 7.3bignumber.js
  3. 7.2Dinero.js
  4. 6.5big.js
  5. 5.8Math.js
  6. 4.4currency.js
  7. 3.8Numbro
  8. 3.2Numeral.js
Compare all 8 on six scores