Random Number Generator

Statistics demos, load-test IDs, and teaching samples need many numbers, not one raffle ticket. This page draws a CSPRNG list in a range and can show simple stats and a CSV so you can drop the sample into a spreadsheet. It is not a PIN or a lottery ticket printer.

What the random number generator is for

Random numbers underpin draws, sampling, and testing. Human-chosen numbers are heavily biased — people avoid repeats and edges, and gravitate to certain digits.

Cryptographic randomness matters wherever the outcome could be challenged or has value attached.

Common uses

  • Running a prize draw from numbered entries
  • Selecting a random sample for auditing
  • Generating test values across a range
  • Assigning random identifiers

What the output means in the real world

The list and optional CSV are your sample. Import them into analysis software or a test fixture, then delete the download if it left your Downloads folder. If any number will become a live identifier in production, check uniqueness constraints; a short range will collide. Do not publish a CSV of random OTPs.

How this fits into real work

Classroom mean-and-variance lessons need a fresh sample so students cannot memorise last year's list. Export the CSV, plot it, and keep the range notes with the assignment.

Load tests that use incrementing IDs hide hot-spot bugs. A random ID column surfaces them. Keep the range inside what the schema allows.

For a single fair winner, use the range tool or the lottery tool so you are not accused of cherry-picking a row. This page is the bulk sampler.

How to use this tool

  1. Set the minimum and maximum, both inclusive.
  2. Choose how many numbers you need and whether repeats are allowed.
  3. Generate and record the result if it needs to be auditable.

Tips

  • Disable repeats when drawing multiple winners from one pool.
  • Announce the range and method before drawing so the outcome is defensible.

Privacy & how it works

Everything happens inside your browser. The values you type are held in page memory only, are never sent to a server, and disappear when you close the tab. You can confirm this in your browser's network tab: the only request a tool makes is one that names the tool for a usage count, with nothing you typed in it. The tools also work with the internet disconnected. Randomness comes from crypto.getRandomValues(), the browser's cryptographically secure generator, not Math.random(). Math.random() is seeded predictably and must never be used for anything security-related, because an attacker who learns part of the sequence can reconstruct the rest.

Frequently asked questions

Is this suitable for a prize draw?
The randomness is sound — it uses the same generator as cryptographic operations. For a regulated or high-value draw, follow whatever auditing and witnessing your rules require.

Browse other tools

All tools run entirely in your browser — nothing you type is sent to a server, except the optional HIBP 5-character hash prefix.