Skip to content
Secret Santa Generator
Guides

How to draw names for Secret Santa fairly: hats, odd numbers, couples

Write the names on slips, fold them, pull them from a hat, and about two times in three someone unfolds their own name. That is not bad luck; it is maths, and the usual fix makes it worse.

Why the hat fails so often

A draw where nobody gets themselves is called a derangement. For four people there are 24 ways to hand out the slips and only 9 of them work. From about six people up, the share of good draws settles at 36.8 % (1 divided by e), whatever the size of the group. The SAS blog worked this out by listing every outcome, and UTS adds a neat fact: on average exactly one person draws their own name, in a group of four or of four hundred.

Chance that a plain hat draw works first time
PeopleWays to hand out slipsNobody gets themselvesWorks first timeTries needed on average
36233.3 %3
424937.5 %2.7
51204436.7 %2.7
672026536.8 %2.7
103 628 8001 334 96136.8 %2.7

The last column is 1 divided by the success rate: 24 / 9 = 2.67 for four people. Two or three rounds of folding and unfolding is annoying but survivable. The trouble starts when people try to save time.

The flaw in "put your own name back"

The usual shortcut: if you pull your own name, put it back and draw again. It feels fair. It has two problems.

First, the last person can be left holding only their own slip, and then the whole round is wasted anyway. I computed this exactly for each group size by following every branch of the draw:

Put-back hat: chance the last person is stuck with their own name
PeopleLast person stuck
325.0 %
413.9 %
513.2 %
611.3 %
89.0 %

Second, and worse, the finished draws are not equally likely. With three people there are two possible draws (the circle one way or the other), and the put-back method picks one of them twice as often as the other. With four people a fair draw would give each of the 9 outcomes 11.1 %; the put-back hat gives some 6.5 % and others 19.4 %, three times as much. Nobody at the party will notice, but it is not the fair draw people think it is.

Bar chart: chance the last person is stuck with their own name in a put-back hat draw, from 25 percent for 3 people to 9 percent for 8
The put-back hat strands the last person surprisingly often in small groups.

A fair draw on paper

The fair version is simple: if anything goes wrong, everybody puts their slip back and the whole hat is drawn again.

  1. Write each name on an identical slip, fold it the same way and mix them well.
  2. Everyone draws one slip and reads it privately.
  3. Ask: "Anyone got themselves?" Anyone who has says "redraw", without saying anything else.
  4. If anyone said it, all slips go back in, mix, and start again from step 2. No partial redraws.
  5. When a round passes with no "redraw", the draw stands.

With exclusions the same method works, but it gets slow: six people in three couples have 80 good draws out of 720, so you need 9 rounds on average, and 15 if you also ban swaps. A Secret Santa generator does the same full redraw thousands of times in a blink and stops only when every rule is met.

Odd numbers are fine

People often ask how to pair up seven people. You don't pair them. As Elfster explains, Secret Santa is a loop: Anna gives to Ben, Ben to Chloe, and so on until the last person gives back to Anna. Everyone gives once and receives once, and a loop of seven closes as neatly as a loop of six.

Left: five people in one chain A to B to C to D to E and back to A. Right: two separate swaps A and B, C and D
Secret Santa is a chain, not pairs, so odd numbers work. Swaps are allowed but usually avoided.

Couples, households and last year

The usual exclusions, as Elfster lists them, are couples, siblings and children, and last year's pairs. In the tool, Add exclusion makes a two-way rule: Anna ⇄ Ben stops both directions. Avoid last draw's pairs is one-way: if Chloe bought for Dev last time, she won't get Dev again, but Dev can still draw Chloe.

How many exclusions can a group take?

Every person needs at least one person they could buy for and at least one person who could buy for them. That is necessary but not enough. Three people with one couple pass that test, yet no draw exists: Anna and Ben can each only give to Chloe, and Chloe receives one gift.

Exact number of valid draws (counted by listing every possibility)
GroupValid drawsWith Avoid swaps
3 people, one couple00
4 people, one couple42
4 people, two couples42
4 people, Anna excluded with everyone00
5 people, Anna excluded with Ben and Chloe104
6 people, three couples8048

My rule of thumb: after exclusions, everyone should still have at least two people they could draw. With only two valid draws, as in four people with two couples and swaps banned, the draw is technically secret but easy to guess. When a set of rules can't be met, the generator says so plainly, and names the person who is boxed in when there is one, instead of quietly breaking a rule.

Swaps or one big circle?

A swap is when Anna buys for Ben and Ben buys for Anna. It is allowed, but it feels like a private exchange rather than a group game, so Avoid swaps is on by default. One big circle goes further: everyone sits in a single chain, which is perfect for opening presents in turn. For six people without exclusions that leaves 120 draws out of 265, still plenty to keep the secret.

Frequently asked

What happens if someone draws their own name?

With paper slips, put all slips back and redraw the whole hat; redrawing just one slip makes some outcomes more likely and can strand the last person. A generator never gives anyone their own name.

How do you do Secret Santa with an odd number of people?

Exactly as with an even number. Secret Santa is one chain where everyone gives once and receives once, so the group size doesn't matter.

Can couples be excluded from drawing each other?

Yes. Add each couple as an exclusion; it works both ways. In a group of three, one couple exclusion makes the draw impossible, so you need at least four people.

Is drawing from a hat random enough?

A full redraw whenever anyone gets themselves is fair. Putting only your own slip back is not: with four people some outcomes come up three times as often as others.

Try the Secret Santa Generator

Keep reading