A tip pool splitter on AWS for a few dollars a month
Tips are the only part of somebody’s pay they cannot check. The card machine total is not visible, the cash is counted by somebody else, the split is done in a back office on a Sunday, and what arrives is a number. Almost nobody is being cheated and almost everybody wonders. This post walks through a small system whose entire purpose is to make the arithmetic visible.

Key takeaways
- The rule lives outside the system. It is a decision for the people it affects.
- Three inputs: card tips, cash tips, and the hours worked in the period.
- Every share is published with its working: hours, weight, pool total, and the division.
- The rounding remainder is distributed in a rotating order, never retained.
- Designed on AWS for about $2 a month.
The whole system on one page
Before any code, here is the shape of what we are designing.
The rule stays outside
It would be easy, and wrong, to build the rule into the system. Tip sharing is subject to law in many places, it is frequently the subject of a written policy, and it is always the subject of strong feelings. A system that encodes a rule invites the question “who decided that?”, and the answer must never be “the software”.
So the rule is a sheet: which roles are in the pool, what weight each carries, whether the basis is hours worked or shifts worked, and what happens to the rounding remainder. Changing it is a conversation and then an edit, in that order.
What runs each period (the inside)
- The collector. Takes the card tips from the till or card report, the cash tips from a declared figure, and the hours from the rota or the timesheets. Three numbers per period plus a row per person. Part 2 covers where each comes from and which of them is genuinely hard.
- The splitter. Applies the rule. Multiply each person’s hours by their role’s weight, sum the weighted hours, divide the pool by the sum to get a rate, multiply back. It is four lines of arithmetic and the only interesting part is what happens to the pennies.
- The publisher. Shows each person their share and the arithmetic that produced it, plus the pool total and the total weighted hours, so the numbers can be checked against each other. That transparency is the entire product.
One period, end to end
In plain words
A week ends. Card tips came to £642.30 and declared cash tips to £188.00, so the pool is £830.30. Eleven people worked, and the agreed rule weights front of house at 1.0, kitchen at 0.8 and supervisors at 1.2. Total weighted hours come to 318.4. That gives a rate of £2.6077 per weighted hour.
Everybody gets a message on Monday: your share is £71.16, from 27.3 hours at weight 1.0, at £2.6077 a weighted hour. The pool was £830.30 across 318.4 weighted hours. Two pence of rounding remainder went to the next two people in the rotation, and here is who. Nobody has to trust anybody, because every number in that message can be checked against every other one, and eleven people checking the same arithmetic is a much stronger control than one person doing it carefully.
Design rules that shaped every decision
- The rule is not the system’s. It lives in a sheet, it is somebody’s decision, and the system applies it identically.
- Publish the working, always. A share without its arithmetic is a number you are asked to trust.
- Never round in the house’s favour. The remainder is distributed, in a recorded rotation.
- The same rule for the whole period. A rule change takes effect next period, never retroactively.
- Cash is declared, not inferred. The system records what somebody said went in, and who said it.
- It never moves money. It produces a figure that payroll pays.
Why this shape
Almost every tip dispute is an information problem rather than an honesty problem. People cannot see the pool total, cannot see other people’s hours, and cannot see the rule being applied, so a share that is lower than last week has no explanation and the mind supplies one.
Publishing the arithmetic costs nothing and removes the whole category. It also has a second effect that is worth more than the first: when eleven people can see the pool total and the weighted hours, arithmetic errors get found within a day, by the people with the strongest incentive to find them.
The next four posts walk through each piece: how the pool and hours are collected, how the split is computed, what happens to the rounding, and what publishing actually looks like. One diagram per post, a cost breakdown, and an engineering reference at the end.
All posts