Random Number Generator

Fair random numbers in any range, with or without repeats

Result
–

Embed this tool on your website

Free for blogs, schools and businesses. Paste this HTML where the tool should appear; it runs in your visitors' browsers and stores nothing. The last line only resizes the frame to fit, so you can leave it out if your site removes scripts.

How to generate random numbers

  1. Enter the smallest and largest number you want. Both are included.
  2. Choose how many numbers to draw, and whether repeats are allowed.
  3. Click Generate (or press Enter). Tick Sort results to list them in order, and copy them with one click.

Fair, unpredictable randomness

Numbers come from your browser's cryptographic random generator (crypto.getRandomValues), the same source used to create encryption keys, rather than the predictable Math.random. Rejection sampling removes the small bias that a simple remainder would introduce, so every value in the range is exactly equally likely.

With No repeats ticked, the tool draws without replacement, like pulling numbered balls from a bag: ideal for raffles, lotteries, picking winners, assigning seats or sampling survey participants. With repeats allowed, each draw is independent, like rolling a die many times.

Ideas

Pick a raffle winner from ticket numbers 1–250; draw six lottery-style numbers from 1–49 with no repeats; choose a random page of a book; generate test data with decimal places; or settle who goes first. For picking names rather than numbers, use the random name picker. The draw happens on your device and nothing is logged.

Is this random number generator truly random?

It uses a cryptographically secure generator seeded by your operating system, which is unpredictable for all practical purposes and suitable for fair draws.

Are the minimum and maximum included?

Yes. A range of 1 to 10 can produce both 1 and 10.

Can I generate random decimals?

Yes. Choose 1–3 decimal places; values are drawn evenly on that grid, for example 0.00, 0.01 … 1.00.

Made by BufferMint. We also design and build software products for founders. See our services →

Your files and inputs never leave your device; we only count anonymous visits.