Money calculators are the most duplicated code on the web — and the least verifiable. You type a salary into a box, get a number, and have no idea what produced it. So I did the opposite on MoneyCalcs: one shared formula engine, and a public open formula dataset listing the exact math and default inputs behind all 30 calculators.
One engine, not thirty copies
Every calculator on the site mounts the same calcs.js. A page is just a config:
CalcsMount({
fn: "mortgage",
fields: [
{id: "price", label: "Home price ($)", def: 400000},
{id: "rate", label: "Interest rate (% APR)", def: 6.5},
// ...
]
});
The engine exports pure functions (pmt, payoff, fvLump, fvAnnuity, fedTax, fica, ibanCheck) and a self-test runs against them in CI-style fashion:
// $300k @ 6.5% / 30y = $1,896.20 (standard mortgage tables)
near(pmt(300000, 6.5, 360), 1896.20, 0.05, "mortgage pmt");
// 2026 federal tax: taxable $63,900 single -> $8,770
near(fedTax(63900, "single"), 8770, 1, "fed tax 2026");
The scenario tables are computed, not written
The "worked examples" tables on each page (what $500/mo becomes at 7% over 30 years, etc.) are generated by running the same calcs.js through Node at build time. No hand-copied numbers, no drift between the calculator and its examples:
node make_examples.js # writes data/examples.json via the real engine
python build.py # renders static HTML with the tables baked in
node test.js # asserts the math
The dataset
/data.html is a plain static table: calculator, category, formula/method, default inputs. Mortgage amortization M = P·r / (1 − (1+r)^−n), the 28/36 affordability rule, snowball vs avalanche payoff ordering, 2026 US federal brackets and the FICA cap — all in one place, machine-readable copies at /llms-full.txt and /ai/faq.json.
It's licensed CC BY 4.0: steal the formulas for your own tools, attribution is enough.
Why static
The whole site is generated to static HTML — every table and formula is readable without JavaScript. That matters for accessibility, for AI crawlers, and because a calculator that can't show its math is just a horoscope with input fields.
If you build finance tools and want a reference table of standard formulas with tested defaults, the dataset is yours to reuse.
Top comments (0)