You might be doing Secret Santa wrong
My family has done Secret Santa for more than 25 years, and it took four versions of the draw until everyone trusted it. Along the way we ran into problems familiar from software development: randomness that doesn't feel random, a swap rule that secretly favours some outcomes, and side channels through wrapping paper and handwriting.
Our Secret Santa group has more than ten people from several families; the exact number varies. Everyone draws a name and buys a present for that person. Before the gift-giving, everybody secretly puts their present into an opaque sack, and whoever unwraps a present has to guess who it is from. For us, the guessing is the actual game.
Version 1: Dad does the draw
In the first version, Dad did the draw on his own beforehand and told each person only who they were buying for. To this day I assume he was honest about it. But nobody except him could know that.
Accusations came up quickly, like “Why does X always get Y?” or “I always end up with the same people.”
Yet patterns like these are perfectly normal with true randomness; it just rarely feels random to us. Spotify rebuilt its shuffle mode for the same reason: it is deliberately less random and in exchange spreads an artist’s songs more evenly.
So it probably wasn’t the randomness that was the problem for us. Nobody could check it, that’s all.
Version 2: Slips of paper in surprise eggs
The next idea was Kinder Surprise eggs, or more precisely the yellow capsules inside them. From then on, Dad wrote the names on slips of paper, put each one into a capsule, and everyone drew an egg from a sack. That way even he no longer knew who had whom.
Things still didn’t calm down. Dad had filled the eggs and drew somewhere in the middle, and right away the question came up whether he might have marked eggs for himself or his loved ones. Then there was a problem that anyone who has ever done Secret Santa knows: you can draw yourself. At first there was no fixed rule for that.
Version 3: If you draw yourself, swap
So later a rule was added that actually sounded very reasonable: if you draw yourself, you put your egg back and simply take another one from the sack. Unfortunately, this swap rule has several weaknesses.
For one, it doesn’t always work out. If the only name left in the sack for the last person is their own, there is nothing left to swap. Statistically, with ten people this happens in just under 8 percent of cases. Then the whole draw was redone.
It also gives something away. Whoever puts their egg back knows that their own name is still in the sack and will be drawn by someone whose turn comes later. If the eighth of ten puts their egg back, only two people remain who can be their Secret Santa. For them, the guessing game is over.
And on top of that the procedure isn’t even fair, even though it feels that way. The easiest way to see this is with just three people: Anna, Ben and Clara each draw an egg in turn. With three people there are only two valid outcomes. In outcome 1, everyone draws the person whose turn comes after them: Anna draws Ben, Ben draws Clara, Clara draws Anna. In outcome 2, everyone draws the person whose turn came before them: Anna draws Clara, Ben draws Anna, Clara draws Ben.
The diagram shows how it actually plays out with the swap rule.

At the top, Anna drew Clara first. “Anna” and “Ben” are left in the sack. If Ben picks “Anna”, everything is settled. If he picks himself, he puts the egg back and takes “Anna” instead. So both green strands end at “Anna”, “Ben” is left over for Clara, and the result is outcome 2.
At the bottom, Anna drew Ben. “Anna” and “Clara” are left in the sack, and Ben doesn’t have to swap, whatever he picks. If he draws “Clara”, “Anna” is left for Clara: outcome 1, the blue strand. If he draws “Anna”, only her own name is left for Clara. That is the red strand: everything goes back into the sack and the draw starts over.
All four strands are equally likely. The red one doesn’t count, because after it the draw simply starts again. Of the remaining three, two lead to outcome 2 and only one to outcome 1. So outcome 2 comes up twice as often as outcome 1, even though everyone drew completely honestly.
The bigger the group, the more skewed it gets: with four people, the most frequent assignment is three times as likely as the rarest, and with ten people as much as nine times. So if you use a swap rule like this too, your procedure is unfair, no matter how honestly everyone draws.
When every egg said “Dad”
At some point during the egg era, Dad ran a test. He wanted to know whether everyone really kept quiet about who they had drawn. So he wrote his own name into every egg. Everyone was supposed to believe they had drawn Dad until he revealed it and had everyone draw again. If two people had told each other beforehand who they had, they would have noticed that both had drawn “Dad”.
It never got that far. The test was blown during the draw itself, because someone had “gelunscht”, that is, sneaked a look into their neighbour’s egg. So the test found a completely different gap from the one Dad had been looking for.
Everyone laughed, because the idea of Dad getting all the presents was wonderful.
Version 4: Everything back into the sack
Today we draw like this: everyone draws in turn and looks into their egg. If someone has drawn themselves, they call it out loud and show their slip, and all the eggs go back into the sack. Showing the slip has been mandatory ever since someone was accused of calling out just to get rid of a name they didn’t like. Dad draws last and gets whatever is left. That way he can no longer pick an egg.
This procedure is fair because every valid assignment is equally likely. With four people, each of the nine comes up about 11 percent of the time. It also gives nothing away, because an aborted round says nothing about the next one. The technical term for this is rejection sampling: you keep drawing until the result meets the condition and throw away all the other attempts completely.
The downside is that it takes time. It would be faster if everyone opened their egg at the same time, but we don’t actually want that.
How long it takes on average is easy to work out. The chance that nobody draws themselves in a round is about 37 percent, almost regardless of how many people take part. So on average you need about 2.7 rounds.
For us it is actually a bit of a letdown when it works in the first round. The funniest moment is when almost everyone is through and someone shouts just before the end: “I’ve got myself!” Add to that the thrill in every round: will I have to give up my great name again? Or will I be stuck with the person I don’t really know what to get for?
What the wrapping gives away
The draw is only one half of the secret. The other half is in the gift sack, and at first the presents in it gave away more than they should have. Often each family had its own wrapping paper, so when unwrapping, many people knew immediately which family a present came from. Since then, everyone gets the same paper in advance.
You can recognise handwriting, too. That’s why the eggs now contain a sticky label with the name, printed by Dad, instead of a slip of paper. You stick it straight onto the present, and nobody has to write a name on it themselves anymore. Of course this means nobody is allowed to lose their label before Christmas, or there will be trouble.
In IT security, leaks like these are called side channels. The procedure itself is watertight, but something incidental like paper or handwriting still lets a piece of information slip through unintentionally.
Who we trust today
Two gaps remain open to this day. The first is Dad, who still fills the eggs himself. Everyone knows it, and nobody wants to change it, because he would never deliberately ruin Secret Santa. So we trust him again, just like at the very beginning. He just has much less in his hands: a few labels and yellow capsules instead of the complete assignment.
The second gap is us. No procedure helps against blabbing in the family.
Version 1 was actually fair already, but only the current version is trusted by everyone in my family. It’s the same with algorithms and systems: trust comes above all from being able to follow what happens. My colleague Philipp writes about reporting: “I don’t trust a report that uses magic and coincidence to determine which data it contains.”


