Skip to main content

Secret Santa Generator

New

Randomly assign gift-giving pairs for a group, guaranteeing nobody draws their own name, with optional exclusion pairs for couples or family members.

secret santagift exchangerandom assignmentholidayderangement
Read the guide
Shortcuts:⌘ KSearch

Generates a random derangement — an assignment where no one draws their own name, and (if you list exclusion pairs) excluded pairs never draw each other either. Everything runs in your browser; nothing is sent anywhere, so you can safely generate real assignments here.

Continue with:

Frequently Asked Questions

How does the tool guarantee nobody draws their own name?

It generates what mathematicians call a "derangement" — a random permutation with the specific property that no element maps to itself — by repeatedly shuffling the assignment and checking the constraint until a valid one is found, which for any reasonable group size happens almost immediately.

What are exclusion pairs for?

They let you prevent specific people from drawing each other's names — commonly used for couples or immediate family members who already know what gifts they're getting each other, so the "mystery" of Secret Santa stays intact for everyone else.

Is this actually random, or could I influence the outcome?

It uses standard JavaScript randomness (a Fisher-Yates shuffle) to generate assignments, so results are unpredictable and not influenced by name order — though for cryptographically sensitive draws you may prefer a physical drawing method instead.

What happens if my exclusion rules make a valid assignment impossible?

The tool tries several hundred random assignments before giving up and telling you to relax some exclusion rules — this only happens with very restrictive exclusion lists relative to your group size.

Does this tool save or share the assignment anywhere?

No — everything runs locally in your browser and nothing is transmitted or stored, so you'll want to note down or screenshot the results yourself, or share them individually with participants.

Related Tools