Badminton Pairing
A small, honest project: turning a real social friction into a well-scoped tool.
Setting up a session: adding players and their skill levels
Balanced matchups, rotating partners, hard constraints respected — all in a mobile browser.
The problem
You show up to play badminton with eight people. Someone has to figure out who plays with whom. You look around. Two people are beginners. Three are clearly stronger than everyone else. One person really doesn't want to be paired with their spouse again. Fifteen minutes of negotiating later — "okay fine, let's just rotate" — you start.
Every. Single. Session.
What would you actually want?
A way to tap in the players, set rough skill levels, and get a fair pairing in seconds. One that remembers who played together last round. One where you can say "never put these two on the same team" and it's hard-blocked — not a suggestion. And if two people want to play together occasionally — a parent and their kid, a couple who actually likes it — a way to make that happen without it becoming every single game.
So, what is Badminton Pairing?
A mobile-first web app for generating fair doubles pairings during a casual session. No login. No backend. Everything lives in the browser.
I built this for my own games — though anyone with the link can use it, and I suspect the fifteen-minute negotiation is not unique to my group. The scope was small, so it was worth building properly.
How it works
Add players, set skill levels (1–5), mark anyone who's resting. The engine evaluates all possible pairings — with 8 players across 2 courts, that's 315 combinations per round — and scores each one on skill balance, partner history, recent pairings, and how long anyone's been sitting out. Lower score wins.
The repeat-pairing penalty is deliberately larger than the skill-imbalance penalty. After Round 1, a repeated partnership will almost always lose to a slightly less balanced but fresh pairing. Partners rotate naturally without anyone having to ask.
Two constraint types go into every round:
"Never partner" is a hard block — the pair is filtered out before scoring. No penalty to be outweighed, no workaround. They can still face each other across the net.
"Try to pair together" is a scoring bonus. In "every other game" mode, the bonus overrides the repeat penalty, so the pair appears roughly every second round indefinitely. In "occasionally" mode, the bonus fades as the pair plays together more — they show up 2–3 times early in the session, then rotate out as the repeat penalty naturally accumulates.
After each round, "Try another" shows a genuinely different set of partners — not a minor reshuffle, but an alternative drawn from the ranked candidate list, reordered so each option differs as much as possible from the last.
The engine works for larger groups too. I've tested up to 12 players and was happy with what it produced. If a round comes out in a way that doesn't feel right, pressing "Try another" gets you a genuinely different arrangement — not the same thing reshuffled.
Where it stands
It's a small project. If a bug comes up, I can fix it quickly. Everyone's happy with it now, so I don't really work on this anymore. The pairing logic is more carefully thought through than it might look — and sessions actually go smoother.