finds.dev

Rhymond/go-money

Go implementation of Fowler's Money pattern

View on GitHub

★ 1,894GoMITupdated Apr 2026

// the take

Go implementation of Fowler's Money pattern — stores monetary values as integers (smallest currency unit) to avoid float rounding errors. Covers arithmetic, comparison, and allocation (split/allocate with penny distribution). Targeted at Go developers building anything that touches money: billing, invoicing, e-commerce.

Integer-based storage is the right call and the library commits to it correctly. The Split/Allocate penny distribution via round-robin is a real solution to a real problem that most homegrown money types get wrong. Full ISO 4217 currency coverage with constants means you're not stringing currency codes everywhere. Test coverage is solid and the API surface is small enough to read in 20 minutes.

No support for currency conversion — you can't add GBP to USD, which means the library hits a wall the moment you have a multi-currency system and have to bolt on exchange rates yourself. The formatter is baked in and not easily overridable, so if your locale needs differ from what's in db.go you're patching the library. Mutator types in mutator.go suggest some mutable-state patterns that contradict the otherwise value-type design. Last meaningful feature work appears to have stopped years ago — issues and PRs pile up with minimal maintainer engagement.

We read the README, the directory tree and a key source file in June 2026. Nobody pays to be listed. How we judge →

// at a glance

Stars
1,894
Forks
164
Language
Go
License
MIT
Last commit
29 Apr 2026

// nearby

If go-money isn't quite it.

All repos →