Embeddable Calculator Engine

Commercial licence · the arithmetic runs in your reader’s browser

By · Last updated

What this is. The calculation engine behind every calculator on this site, licensed for use inside a finance publisher’s own product. It is not a widget service and not a hosted calculator — it is the arithmetic itself, packaged so your team can ship a tool that computes on the reader’s device and sends nothing to you or to us.

You can verify the engine before you buy it

This is the part most licensing conversations skip, so it is stated first: the engine is not a capability claim, it is running on the page you are reading. Every calculator on this site calls the same public interface this licence covers. If you want to check the arithmetic yourself, use the loan calculator, the mortgage calculator and the ROI calculator and reproduce the outputs in a spreadsheet.

The public interface is one global object, window.CalculatorLib. It currently carries 37 functions and two data tables, and it loads with no DOM present at all — the arithmetic never touches the page it happens to be running on, which is what makes it embeddable rather than merely iframe-able.

What is in the interface

The functions group into the areas a finance product actually needs. This is the current surface, not a category list:

  • Borrowing. monthlyPayment, totalInterest, buildAmortization, mortgagePayment, carLoan, creditCardPayoff, annuityPayment, homeAffordability, loan-affordability inputs via dscrAnalysis, and the payoffRace avalanche/snowball comparison.
  • Business performance. roi, annualizedROI, breakEven, breakEvenRevenue, grossMargin, netMargin, markupPct, sellingPrice, workingCapital, currentRatio.
  • Savings and retirement. compoundInterest, futureValue, pastValue, monthlySavingsNeeded, retirementProjection, retirement401k, dca, cdEarnings.
  • Position and affordability. dti, netWorth, and the debt-service coverage ratio in dscrAnalysis.
  • Currency. convert, with 18 currencies carrying their own display symbols and 30 exchange-rate entries.
  • Presentation. fmtMoney, fmtPct, toNum, resultHTML, barChart and pieChart — the last three need a DOM and are the only three of the 37 that do.

The behaviours that decide whether it is useful

An engine is only as good as its edge cases, so these are the ones worth testing. All were measured against the current build rather than described from memory:

  • A zero interest rate does not divide by zero. monthlyPayment(1200, 0, 12) returns 100 — straight-line division, not NaN.
  • A zero term returns zero rather than an undefined payment. monthlyPayment(1200, 6, 0) returns 0.
  • Agreement with the closed form. monthlyPayment(300000, 6.5, 360) returns 1896.20, which matches P·r / (1 − (1+r)−n) to two decimal places, and totalInterest on the same inputs agrees with payment × n − P to the cent.
  • Repeatable. The same inputs produce a byte-identical result across calls, which is what makes a published figure reproducible.
  • Deterministic currency conversion. Rates are a versioned table, not a live feed, so a figure you publish today still reconciles tomorrow. That is a deliberate trade: see the methodology page.

You can run every one of these checks yourself in a browser console — the object is public on this site as well as in the licensed build.

What you get

  • 1
    The engine. The same CalculatorLib this site runs, licensed for your domain or product, with no per-page call to us and no runtime dependency on this site remaining once integrated.
  • 2
    Reference test vectors. Published inputs and their exact outputs — including the edge cases above — so your implementation can be checked against a known-good baseline instead of trusted.
  • 3
    The calculation specification. Formulas, rounding order and boundary conditions, so the engine is auditable rather than a binary. Available with the separate methodology licence and included here at the standard tier.
  • 4
    Update path. Engine changes are versioned and dated, so a reader can see what moved between two publications.

What this is deliberately not

  • Not hosted for you. There is no iframe, no script tag that phones home, and no server that holds your readers’ figures. If you need a server-side rendering path, say so in the enquiry — it is a different shape and priced differently.
  • Not advice. The engine computes. It does not recommend a product, a lender or a course of action, and a licensed implementation must not be presented as doing so.
  • Not a regulated permission. Nothing here authorises anyone to operate under any regulator’s rules. Those permissions come from the regulator.
  • Not the site’s data. The banking dataset is licensed separately as the data and calculation API. This licence covers the arithmetic only.
  • Not the trust promise. “Nothing leaves the reader’s device” is a property of the reference implementation. If you add a server call, an analytics tag or a third-party script, you own that decision and its disclosure.

Compliance note. Embedding a finance calculator in a product that also recommends products is exactly the perimeter this licence is scoped to stay outside. Any arrangement is subject to your own legal review, and the licensee remains responsible for how the tool is presented to its users.

Licensing tiers

  • Single product — $400 / month. One domain, one product, monthly terms, updates included.
  • Organisation — $1,200 / month. Unlimited properties in one legal entity, with a named technical contact.
  • White-label — quoted. Removal of AINext Growth attribution, plus redistribution inside a network of third-party sites.

How to start

Enquiries are handled directly. Describe the product, the audience and the jurisdictions you cover, and a working reference build plus the test vectors are shared before any commercial discussion — so you can confirm the arithmetic suits your use before there is anything to buy.

Contact AINext Growth