Skip to content
Sad Subscription Analytics
Menu

Zero-decimal currencies

Most currencies have a smallest unit worth one hundredth of the major unit, like a cent of a dollar. A handful do not, and SadAnalytics scales those differently so the figures on screen stay correct.

What a zero-decimal currency is

A zero-decimal currency has no fractional subunit worth using: its smallest unit already is one whole unit, unlike a currency such as USD where the smallest unit is a cent, one hundredth of a dollar. SadAnalytics recognizes sixteen of them:

  • JPY (Japanese yen)
  • KRW (South Korean won)
  • VND (Vietnamese dong)
  • BIF (Burundian franc)
  • CLP (Chilean peso)
  • DJF (Djiboutian franc)
  • GNF (Guinean franc)
  • KMF (Comorian franc)
  • MGA (Malagasy ariary)
  • PYG (Paraguayan guarani)
  • RWF (Rwandan franc)
  • UGX (Ugandan shilling)
  • VUV (Vanuatu vatu)
  • XAF (Central African CFA franc)
  • XOF (West African CFA franc)
  • XPF (CFP franc)

How SadAnalytics scales them

Internally, SadAnalytics stores every amount as a whole number in the currency's smallest unit, the same way Stripe does. For an ordinary currency that number is divided by 100 before it is shown, since 100 cents make a dollar (or euro, or pound). For a zero-decimal currency, SadAnalytics divides by 1 instead: the stored number already is the amount in whole units, so nothing is scaled down and no decimal point is added.

This matters mainly if a figure ever looks off by a factor of 100. If a figure in one of these sixteen currencies looks 100 times too big or too small, email me at [email protected]. That is a bug, and I will fix it.

Where this shows up

The clearest place to see it is Target MRR in Settings, then General: on a JPY site, typing 500 sets a target of five hundred yen, not five hundred yen's worth of cents. Every other currency field behaves the same way: for a zero-decimal currency, the number you type or read is already the whole amount.

Currency conversion is unaffected by any of this: a zero-decimal currency still converts to your primary currency at the current exchange rate exactly like any other currency; only the scaling of its own smallest unit is different.