HomeGeneratorsEverydaySecret Santa Generator

Secret Santa Generator

Everyday

Randomly assign Secret Santa gift pairs from a list of names. No sign-up, no app — paste your names and get instant, fair assignments in seconds.

What is a Secret Santa?

A Secret Santa Generator automates the name-drawing step of a gift exchange — the moment when names go into a hat, get shuffled, and each participant pulls out the name of the person they will buy a gift for. The generator replaces the hat entirely: paste in the list of participant names, click Generate, and receive a complete, randomised set of assignments instantly.

The tool enforces two rules that a physical hat draw sometimes fails: every person gives exactly one gift, every person receives exactly one gift, and no one draws their own name. This last condition — called a derangement — is easy to forget when shuffling manually, especially in small groups. The generator guarantees it on every run.

Secret Santa exchanges are common in Indian workplaces during the office Christmas party or year-end celebration, in college hostel groups, in extended families during Diwali or Christmas gatherings, and in online friend groups that want to exchange gifts across cities. The generator works for any of these contexts — the names can be in any language or script as long as they appear one per line.

Once you have the assignments, share each person's line privately — via WhatsApp message, email, or a quick DM — so the draw stays secret. The organiser sees the full list while distributing it, but each participant only needs to know their own assignment.

For groups that want a fully blind draw where even the organiser does not know the pairings, each participant can open the tool, paste the same full list, and note only their own assignment. Since the draw is random each time, this only works if you agree on a single canonical draw in advance. The simplest approach remains the organiser distributing assignments individually.

Use the Team Generator if you need to split your group into balanced teams rather than one-to-one pairs. Use the Random Name Generator if you need a list of placeholder names to test the draw format before committing to real participant names.

How to use this Secret Santa calculator

  1. Enter participant names — type or paste one name per line into the Participants field. Names can include full names, nicknames, or any identifier the group uses — the tool treats each line as one participant.
  2. Remove any blank lines — the generator skips blank lines automatically, but cleaning up the list avoids confusion in the output.
  3. Click Generate — the tool shuffles the list and produces a deranged pairing instantly. The result appears as a list of Giver → Recipient assignments.
  4. Copy individual assignments — use the copy button next to each line or select and copy the text. Send each participant only their own line.
  5. Re-run if needed — if a participant drops out or is added at the last minute, update the names list and click Generate again to produce a fresh draw for the updated group.
  6. Distribute privately — share each person's assignment via a private message so the draw remains secret until the exchange event.

Formula & Methodology

The generator uses a Fisher-Yates (Knuth) shuffle with derangement rejection sampling:

1. Copy the input list into a working array.
2. Shuffle the array in-place: starting from the last element, swap each element with a randomly chosen element at or before its current position. This produces a uniformly random permutation.
3. Check the derangement condition: if any index i has shuffled[i] === original[i], the shuffle is invalid (someone drew their own name).
4. If invalid, repeat the shuffle. Repeat until a valid derangement is found, up to 200 attempts.

For any group of n ≥ 2 participants, the probability that a random permutation is a valid derangement is approximately 1/e ≈ 36.8%. This means the average number of shuffle attempts needed is e ≈ 2.72, so the loop almost always terminates in 1–3 iterations. The 200-attempt limit is a safety ceiling that will never be reached in practice.

Example with 4 participants:

- Input: Alice, Bob, Charlie, Diana
- After shuffle: Bob, Diana, Alice, Charlie
- Derangement check: Bob ≠ Alice ✓, Diana ≠ Bob ✓, Alice ≠ Charlie ✓, Charlie ≠ Diana ✓
- Valid — output: Alice → Bob, Bob → Diana, Charlie → Alice, Diana → Charlie
Frequently Asked Questions
What is a Secret Santa gift exchange?
Secret Santa is a gift-giving tradition where each participant is randomly assigned one other person in the group to buy a present for. The assignment is kept secret until the exchange event — hence the name. It is widely used in offices, families, college friend groups, and online communities to make group gift-giving manageable by ensuring each person gives exactly one gift and receives exactly one gift.
How does the Secret Santa Generator assign names?
The generator takes your list of participants, shuffles it randomly, and pairs each person with one other — ensuring no one is assigned their own name (a constraint called a derangement in combinatorics). The shuffle uses a Fisher-Yates algorithm with rejection sampling: if the random shuffle accidentally assigns someone to themselves, the shuffle is repeated until every assignment is valid. For groups of 2 or more, this converges in one or two attempts.
Can I run the draw again to get different assignments?
Yes. Click the Generate button again and the tool produces a completely new random draw. Each run is independent — the previous assignment is not stored anywhere, so if you want to keep a particular draw, copy it before running again. If a participant is unhappy with their assignment, re-running the draw gives everyone a fresh pairing.
What is a derangement and why does it matter for Secret Santa?
A derangement is a permutation where no element appears in its original position — in Secret Santa terms, no one draws their own name. Without this constraint, a naive shuffle could assign 'Alice → Alice', which is not a valid gift exchange. The generator enforces the derangement property so every assignment is between two different people, regardless of group size.
What is the minimum number of participants?
You need at least 2 participants for a valid draw — one person gives and one receives. In practice, Secret Santa works best with 4 or more participants so the assignments are non-obvious. The generator accepts any number from 2 upwards, though for very small groups (2–3 people) the assignment is predictable: with 2 people, each person must give to the other.
Does the generator support exclusions — e.g. couples should not be assigned to each other?
The current generator does not support exclusion pairs. It assigns names purely at random with the only constraint being no self-assignment. For groups where certain pairs should not be matched (partners, close family members who want more variety), the simplest workaround is to run the draw and re-run it if an unwanted pair appears — for small exclusion lists, a valid draw typically comes up within a few attempts.
Is the draw result stored or visible to anyone else?
No. The entire draw runs in your browser — no names, no assignments, and no results are transmitted to any server or stored anywhere. The assignments exist only in the browser tab while you are viewing them. Each participant should receive their own assignment directly; the organiser should not share the full list unless the format requires it.
How should I share assignments without revealing who gave to whom?
Copy each line individually and share it only with the relevant person — via WhatsApp, email, or direct message. Do not share the full assignments list in a group chat, as that would reveal everyone's assignment at once. For a fully private draw where even the organiser does not know the assignments, use the tool on a device each participant can briefly access privately to see only their own line.
Can I use this for Kris Kringle, White Elephant, or Yankee Swap?
The name-pairing logic works for any one-to-one gift exchange by whatever name — Kris Kringle (common in Australia and Ireland), Secret Santa, or any personalised exchange. White Elephant and Yankee Swap are different formats where participants pick and steal wrapped gifts rather than buying for a specific person, so the pairing draw is not needed for those formats.
What happens if I have an odd number of participants?
The generator handles any group size, odd or even. With an odd number, every person still gives exactly one gift and receives exactly one gift — the derangement works for any n ≥ 2. There is no 'leftover' participant. The pairs form a single cyclic loop (or multiple loops) through the shuffled list, so everyone is included regardless of parity.
Is it fair — does everyone have an equal chance of receiving any participant?
Yes. The Fisher-Yates shuffle produces a uniformly random permutation, so every valid derangement has an equal probability of being selected. No participant is systematically more or less likely to be assigned to any other participant. The only constraint is the derangement rule (no self-assignment), which slightly reduces the probability of each person giving to themselves — from 1/n to 0 — while keeping all other pairings equally likely.