AnyTool
Your files never leave your device. All processing happens locally in your browser.

How do I generate random numbers online?

Open AnyTool Random Number Generator, set a minimum and maximum, choose how many numbers you want, and they appear instantly using your browser’s cryptographically-secure randomness. Pick integers or decimals, turn on “unique” for a lottery-style draw where no number repeats, and sort the results if you like. There are one-tap presets for dice, coin flips, 1–100 and lottery draws, plus a reproducible seeded mode. Everything runs in your browser — nothing is uploaded.

  • Crypto-secure randomness (Web Crypto, no modulo bias) — never Math.random
  • Any range, integers or fixed-precision decimals, one number or thousands
  • Unique / no-repeat draws (sampling without replacement) and sorting
  • Reproducible seeded mode (Mulberry32) replays the same sequence from a seed
  • Presets: dice, coin, 1–100, lottery · copy-all · download .txt · 100% private

What is

Pseudorandom vs Cryptographically-Secure Random

A pseudorandom number generator (PRNG) produces numbers from a deterministic algorithm and a starting seed, so the sequence is repeatable and ultimately predictable. A cryptographically-secure RNG (CSPRNG) — in the browser, crypto.getRandomValues — draws from the operating system’s secure entropy source and is designed to be unpredictable, making it the right default for fair draws. AnyTool defaults to the CSPRNG and offers a seeded PRNG (Mulberry32) only when reproducibility is wanted.

Generators

Related terms

Rejection samplingModulo biasMulberry32Sampling without replacement

Frequently Asked Questions

Turn on the “unique” option. AnyTool then samples without replacement, so every number in the result is different — just like a lottery draw.

To get unique, non-repeating numbers, enable the “unique numbers” option. The generator then performs sampling without replacement over your range using a partial Fisher–Yates shuffle, so each value appears at most once and every possible combination is equally likely. The only rule is that you cannot draw more unique numbers than the range contains — you can’t pick 10 unique numbers from 1 to 5, for example. Picking 6 unique numbers from 1 to 49 simulates a classic lottery draw.

By default it uses your browser’s cryptographically-secure RNG, which is far better than Math.random, though not a certified physical true-random source.

The default mode draws from the Web Crypto API (crypto.getRandomValues) using rejection sampling to remove modulo bias, so every number in the range is exactly equally likely and the output is cryptographically unpredictable — excellent for fair everyday draws, raffles and giveaways. It is the browser’s CSPRNG rather than a certified true-random service seeded from physical noise such as atmospheric radio, so for regulated lotteries or gambling you should still use a certified source. AnyTool never uses the predictable Math.random for the crypto mode.

Yes. Switch to seeded mode and enter a seed — the same seed and settings always replay the exact same sequence.

Seeded mode runs a deterministic Mulberry32 pseudo-random generator initialised from your seed text. Because it is fully determined by that seed, the same seed plus the same range, count and options always produce the identical sequence of numbers, which is ideal for unit tests, demos, procedural game content and sharing a result others can verify. This mode is reproducible but predictable, so it is not suitable for security-sensitive use — for that, keep the default crypto-secure mode.

No. Every number is generated locally in your browser and is never uploaded, logged or stored.

AnyTool Random Number Generator runs entirely in your browser using JavaScript and the Web Crypto API. No range, option or generated number is sent to a server, saved, or tracked — close the tab and the numbers are gone. The page even works offline after the first load, so your randomness never leaves your device.

Detailed Explanation

Methodology

How the Random Number Generator Works

AnyTool Random Number Generator produces every value in the browser. By default it draws from the Web Crypto API: random 32-bit integers come from crypto.getRandomValues and are mapped onto the chosen range with rejection sampling — values that would fall outside an even multiple of the range size are discarded — so there is no modulo bias and every integer is exactly equally likely. Math.random is never used in this default crypto mode. You set any minimum and maximum, choose integers or fixed-precision decimals, and generate a single number or thousands at once over that inclusive range.

  • Default randomness from crypto.getRandomValues (CSPRNG), not Math.random
  • Rejection sampling removes modulo bias — uniform over the range
  • Inclusive [min, max] range; integers or fixed-precision decimals
  • Generate one value or thousands in a single click
  • All generation is client-side JavaScript — no server round-trip
How It Works

Unique Draws, Sorting and Reproducible Seeds

A unique (no-repeat) option performs sampling without replacement using a partial Fisher–Yates shuffle over the integer range, so every drawn number is distinct and every combination is equally likely — exactly the model for a lottery draw such as six unique numbers from one to forty-nine. Results can be left in draw order or sorted ascending or descending, with a convenience line showing the sum, mean, minimum and maximum. A separate reproducible mode runs a deterministic Mulberry32 pseudo-random generator seeded from your text, so the same seed and settings always replay the identical sequence — useful for tests, demos and shareable results — and is clearly labelled as predictable, not cryptographic.

  • Unique option = sampling without replacement (lottery-style), via Fisher–Yates
  • Cannot draw more unique numbers than the range contains
  • Sort ascending, descending or keep draw order; sum/mean/min/max shown
  • Seeded mode uses Mulberry32 — same seed replays the same sequence
  • Seeded mode is reproducible but predictable — not for security use
Privacy & Security

Privacy, Presets and Honest Limits

Because everything happens in the browser, no range, option or generated number is sent to a server, logged or stored — closing the tab discards it and the page works offline once cached. One-tap presets cover rolling configurable dice (with the total), flipping a coin, picking 1–100 and running a lottery draw of k unique numbers from n. The tool is honest that even its default crypto source is the browser’s CSPRNG, not a certified true-random service seeded from physical noise, so for regulated lotteries, gambling or anything with legal or financial stakes a certified random source should be used instead.

Random numbers: in-browser (AnyTool) vs typical online generators
CapabilityAnyToolTypical online generators
RandomnessWeb Crypto CSPRNG, rejection samplingOften Math.random or server-side
ProcessingRuns in your browserOften server-side
Unique / no-repeatYes, sampling without replacement (Fisher–Yates)Sometimes, quality varies
Integers & decimalsBoth, with chosen precisionOften integers only
Reproducible seedYes, Mulberry32 (clearly labelled non-crypto)Rare
PresetsDice, coin, 1–100, lottery + statsUsually a bare range
PrivacyNever uploaded, not stored, works offlineMay transmit or log
Cost / signupFree, no signupOften ad-heavy or gated

AnyTool generates every number locally with crypto-secure randomness and uploads nothing.