User Rating 0.0
Total Usage 0 times
Categories
1 – 100
Quick Presets
Is this tool helpful?

Your feedback helps us improve.

About

Uniform random selection is harder than it appears. A naive Math.random call produces pseudo-random numbers from a linear congruential generator with a period of roughly 232 states. This tool replaces it with crypto.getRandomValues, drawing from the operating system's entropy pool to produce unbiased indices across a corpus of over 500 items in 15 categories. Each draw applies rejection sampling to eliminate modulo bias when the pool size is not a power of two. The practical consequence: every item in a selected category has an equal probability p = 1n of appearing, where n is the active pool size.

The generator supports a no-repeat mode that removes drawn items from the pool until it is exhausted, then resets. This is equivalent to a Fisher-Yates shuffle drawn one card at a time. Note: with all 15 categories active the pool exceeds 500 items, so collisions are rare even without no-repeat mode. With a single small category (e.g., Emotions at 30 items), exhaustion occurs quickly. The tool tracks generation history per session so you can review or export previous results.

random things random generator random picker random item random object generator idea generator random list

Formulas

Each random index is generated using cryptographic entropy with rejection sampling to eliminate modulo bias:

limit = maxUint32 (maxUint32 mod n)
do r crypto.getRandomValues(1) while r limit
index = r mod n

Where n is the total number of items in the active pool, maxUint32 = 4294967296 (232), and r is a uniformly distributed unsigned 32-bit integer. The rejection loop discards values in the incomplete final bucket so that every index 0 through n 1 has exactly equal probability.

The probability of selecting any single item is:

P(item) = 1n

In no-repeat mode, after k draws, the pool shrinks to n k items. The conditional probability for the next draw becomes 1n k. This is mathematically equivalent to revealing one card at a time from a pre-shuffled deck (Fisher-Yates).

Reference Data

CategoryItems CountExample ItemsUse Cases
Animals40Axolotl, Pangolin, QuokkaDrawing prompts, trivia
Foods40Kimchi, Croissant, Pad ThaiMeal planning, challenges
Countries50Bhutan, Iceland, PeruGeography games, travel
Colors30Cerulean, Mauve, VermilionArt projects, design
Activities35Rock climbing, Origami, StargazingBoredom busters, dates
Objects40Kaleidoscope, Sundial, CompassWriting prompts, improv
Professions35Cartographer, Sommelier, ArboristCareer exploration, games
Sports30Curling, Fencing, KabaddiFitness challenges, trivia
Musical Instruments25Theremin, Sitar, DidgeridooMusic discovery
Inventions30Printing Press, Telescope, VelcroHistory lessons, trivia
Historical Events30Moon Landing, Fall of RomeEducation, writing
Plants30Venus Flytrap, Baobab, SequoiaGardening, botany
Emotions30Nostalgia, Euphoria, MelancholyActing, creative writing
Movies35Inception, Amélie, Spirited AwayMovie night picker
Books35Dune, 1984, SapiensReading lists, clubs

Frequently Asked Questions

When selecting a random index from n items using a 32-bit random value, if 232 is not evenly divisible by n, the lower indices have a slightly higher probability. The generator uses rejection sampling: it computes a threshold and discards any random value above it, then retries. This guarantees each index has exactly equal probability P = 1n. The expected number of retries is less than 2 in the worst case.
When every item in the active pool has been drawn, the generator automatically resets the pool and displays a notification. If you are drawing from a small category like Emotions (30 items) and request 10 items at a time, the pool exhausts after 3 draws. The history log preserves all previously generated items across resets.
Yes. Activating multiple category toggles merges their item arrays into a single flat pool. The selection probability for each item remains 1N where N is the total count of all active items. With all 15 categories active, N exceeds 500.
Math.random uses a pseudo-random number generator (typically xorshift128+) seeded from a low-entropy source. Its output is deterministic given the seed and fails statistical randomness tests for certain patterns. crypto.getRandomValues draws from the OS entropy pool (e.g., /dev/urandom on Linux, CryptGenRandom on Windows), providing cryptographic-grade randomness suitable for unbiased selection.
If you request k items with no-repeat enabled and the pool has n remaining items where k > n, the generator produces only n items and warns that the pool is exhausted. It never pads the result with duplicates. Increase the active categories or disable no-repeat mode to resolve this.
No. Each item selection involves one crypto.getRandomValues call (a few microseconds) and an array splice for no-repeat mode. Even 100 items complete in under 1 millisecond on modern hardware. The DOM update uses a document fragment to batch-render all results in a single repaint.