dimesum

Home / Blog / Engineering

Engineering

Why your split bills never seem to add up right

· 9 min read · · reviewed by Jagadeep Sai

A shared balance that won't add up almost always comes down to one of four things: a rounded cent, a second currency, an edited bill, or a member who left, and only the first is arithmetic.

You are looking at a group balance, and it is off. Maybe by a few cents. Maybe by a whole bill. The question underneath is quiet but real: is the app wrong, or are you?

Here is the calm answer. When you split bills with other people, a balance that does not add up almost always has one of four causes, and only one of them is arithmetic. The other three are a currency, an edit, and somebody who left. Name which one you have, and the fix stops being mysterious.

The four causes

Start with the shape of the problem. A shared balance is a running total of who paid and who owes. It should sum to zero across the group: every euro someone is owed is a euro someone else owes. When it does not, something entered the total that the total could not hold.

So why do split bills not add up? Usually one of four reasons. A cent went somewhere unexpected when a bill would not divide evenly. Two currencies got added as if they were one.

An old bill changed after people had already paid against it. Or a person left the group while still owing money. Three of those four have nothing to do with your maths. For the wider picture on how a group actually clears its debts, read our teardown on settling up a group.

The table names each cause once, how it shows up, and what fixes it. Everything after it is the long version.

Four reasons a shared balance does not add up

Four reasons a shared balance does not add up
CauseHow it shows upWhat fixes it
RoundingThe balance is off by a cent or two, never moreA deterministic rule that always sends the odd cent to the same place
A currencyThe total is off by a whole amount, or reads as one strange numberKeep a separate balance per currency and never add across them
An editThe balance jumped after an old bill changedRestate the bill's split and post the difference to history
Someone leftThe balance will not reach zero no matter whatDecide who absorbs or forgives the departed share, then record it

Rounding: the odd cent, and why it must be deterministic

Here is the example, and every figure in it is yours to recompute. Lucas, Aiko and Sofia go out. The dinner is €100.00, and they split it equally. €100.00 divided by three is €33.3333 and on forever, which no currency can pay. So the split becomes €33.33, €33.33 and €33.34.

Add those back: €33.33 plus €33.33 plus €33.34 is exactly €100.00. The three shares are honest. One of them is a cent larger.

That extra cent is the whole problem in miniature. Someone has to carry it. This is shared expense rounding, and it has one job: put the odd cent somewhere fixed rather than somewhere random. If the app assigns it fresh each time, the same dinner can produce €33.34 for Aiko today and €33.34 for Sofia tomorrow, and the balance wobbles by a cent for no visible reason.

So we make the rule deterministic. The extra cent goes to the payer every time. Lucas paid, so Lucas carries €33.34 and the other two carry €33.33 each. Lucas is owed €100.00 minus his own €33.34, which is €66.66.

Aiko owes €33.33. Sofia owes €33.33. €33.33 plus €33.33 is €66.66. The group sums to zero. The rounding used the euro's two decimal places, the minor unit fixed for it in the international currency standard ISO 4217; the choice to hand the cent to the payer is ours, and its only virtue is that it never changes.

A split bills online calculator can do this division for one dinner. The harder part is doing it the same way for the hundredth, which is also the difference we care about in splitting a restaurant bill fairly. Accountants have argued for a long time about which rule is fairest; the common default in computing, round half to even, is set out in the IEEE 754 standard. We do not need it here, because our cent is not a half.

Three shares of a whole leave exactly one cent over, and the only question is who holds it.

Two currencies in one group, and why they cannot be added

Now a second bill enters the group. Aiko pays for a taxi, and it costs ¥6,000. The temptation, for a tired total, is to add ¥6,000 to €100.00 and show one figure.

That figure means nothing. €100.00 and ¥6,000 are not the same kind of thing, and adding them is like adding a distance to a weight. The yen has zero decimal places as its minor unit, the euro has two, again per ISO 4217. They do not even round the same way.

So we keep a balance per currency. In euros, nothing changed: Aiko owes Lucas €33.33, and Sofia owes Lucas €33.33. In yen, the taxi splits three ways at ¥2,000 each. Aiko paid ¥6,000, so Aiko is owed ¥6,000 minus ¥2,000, which is ¥4,000.

Lucas owes ¥2,000. Sofia owes ¥2,000. ¥2,000 plus ¥2,000 is ¥4,000. Two balances, each summing to zero, neither pretending to be the other. If you want the deeper failure modes here, we wrote them up in money bugs across currencies.

An edit to an old bill, and what has to happen to history

Month three. Someone realises the dinner was recorded wrong: it was €120.00, not €100.00. They edit it. This is where balances that looked settled suddenly move, and where a lot of apps quietly go wrong.

The naive fix is to overwrite the old number and recompute from scratch. But people have already paid against the old split. If history is silently rewritten, nobody can see why they now owe more. So the edit has to restate the split and post the difference, not erase the past. €120.00 divided by three is €40.00 exactly, no odd cent this time.

Each share becomes €40.00. Lucas paid €120.00, so Lucas is owed €120.00 minus €40.00, which is €80.00. Aiko owes €40.00. Sofia owes €40.00. €40.00 plus €40.00 is €80.00.

The euro balance moved from €66.66 owed to €80.00 owed, and the difference, €13.34, is exactly traceable to the €20.00 the dinner grew by: the two other shares each rose €6.67, and €6.67 plus €6.67 is €13.34. We keep the old entry and add the correction on top. Why an edit must restate its split, rather than pretend the dinner was always €120.00, is its own story in an edit must restate its split.

Somebody left, and what happens to what they owed

The fourth cause is a person, not a number. Say Sofia leaves the group while still owing €40.00 in euros and ¥2,000 in yen. Now the balance cannot reach zero on its own, because one of the people it depends on is gone.

This is not an arithmetic error; the arithmetic is fine. The group has a hole the size of Sofia's share.

There are only a few honest things to do, and all of them are decisions, not calculations. The group can forgive the amount, and record that it was forgiven. Someone can absorb it, and record who. Or Sofia can settle before leaving.

What matters is that the choice is written down as an entry, so the balance reads zero because something happened, not because a debt was quietly deleted. We never decide this for you; we record the choice you make. The same logic governs a flatmate moving out partway through a lease, which we cover in splitting rent with roommates.

How to check a balance yourself when you split bills

You can audit any of this by hand, and it is worth knowing how. Take one currency at a time, and never mix them. For that currency, add up everything each person paid. Add up everything each person owed, share by share.

A person's balance is what they paid minus what they owed. Do this for everyone, then add all the balances together. The sum has to be zero. If it is not, the gap tells you which cause you have.

A gap of one or two cents is rounding; look at where the odd cent landed and check it landed in the same place every time. A gap the size of a whole bill, or a total that looks impossible, is usually a second currency that got folded in. A balance that changed since you last looked points at an edit, so open the bill's history.

A balance that will not close at all points at someone who left. When you split bills between friends, the balance is only ever arithmetic, so a stubborn gap is information, not bad luck. If you would rather see the numbers than take our word, our statistics on splitting bills piece shows how often each of these actually happens.

What an append-only ledger does about all four

Underneath Dimesum is an append-only, double-entry ledger, and it is public, so none of this has to be taken on faith. Double-entry means every amount is recorded twice, once as something owed and once as something owed to, so the two sides always balance; the principle is older than software and is described plainly in the entry on double-entry bookkeeping. Append-only means we never overwrite. We only add.

That single design handles all four causes. Rounding is deterministic because the cent's destination is written into the posting rule, not decided in the moment. Currencies stay separate because each entry carries its own currency and the ledger refuses to add across them. An edit becomes a new correcting entry that restates the split, so the old truth and the new one both survive; we describe that machinery in an append-only ledger for split expenses.

And a person who leaves becomes a recorded decision, an entry like any other, rather than a missing row. We record all of it. We never hold or move your money; the ledger is a record, and settling happens directly between you, in the fewest transfers we can compute. If you are comparing tools, our notes on apps for splitting bills compared and rent split apps compared stick to what each one does and does not do.

A balance that does not add up is not a verdict on your friendship or your maths. It is one of four small facts about your group. Open Dimesum and the ledger will tell you which.

Common questions

Q: Why does my shared expense balance not add up?

Almost always for one of four reasons: a cent that rounded, a second currency added by mistake, an old bill that was edited, or a member who left owing money. Only the first is arithmetic. Pick one currency, add each person's payments minus their shares, and the size of the gap tells you which cause you have.

Who gets the odd cent when a bill does not divide evenly?

Whoever the app's rule says, as long as it says the same thing every time. A €100.00 dinner split three ways is €33.33, €33.33 and €33.34, and that extra cent has to land somewhere fixed. Dimesum sends it to the payer, so the same dinner never produces a different balance twice. The rule matters more than the choice.

Can you add balances in two different currencies?

No, and no honest app should. €100.00 and ¥6,000 are different kinds of thing, with different minor units, so adding them gives a number that means nothing. Dimesum keeps a separate balance per currency and never folds one into the other. You settle each currency on its own, which is why a group can owe in euros and in yen at once.

What happens to a balance when an old bill is edited?

The split is restated and the difference is posted as a new correction, rather than the past being overwritten. Edit a €100.00 dinner to €120.00 and each equal share moves from €33.33 to €40.00, so the amount owed grows by €13.34. The old entry stays visible, the correction sits on top, and anyone can trace exactly why the balance changed.

What happens when someone leaves a group owing money?

The arithmetic is still fine; the group just has a hole the size of their unpaid share. The balance cannot reach zero until someone decides what to do. The amount can be forgiven, absorbed by another member, or settled before they go, and whichever it is gets recorded as an entry. Dimesum records the decision you make; it never makes it for you.