100% Client-Side Privacy: Your files and data stay in your browser. Nothing is uploaded to our servers.

Random Number Generator

Unbiased CSPRNG

Generate single or multiple random integers within any custom minimum and maximum range using unbiased cryptographic sampling and unique draw mode.

Optional Below-Tool Ad Placement (Disabled by Default)

How to Use Random Number Generator

  1. 1Enter your Minimum Value and Maximum Value (integers up to ±1,000,000,000).
  2. 2Choose to generate a Single Number or Multiple Numbers (specify count up to 1,000).
  3. 3Toggle 'Unique Numbers Only (No Repeats)' if drawing lottery/raffle numbers without replacement.
  4. 4Click 'Generate Numbers' and copy the results to your clipboard.

Key Features & Privacy

  • ✦Uses `crypto.getRandomValues()` with 32-bit rejection sampling so every integer in `[Min, Max]` has an identical mathematical probability.
  • ✦Validates that `Min <= Max` and checks that `Count <= (Max - Min + 1)` when Unique Numbers mode is active.
  • ✦Displays summary stats (Count, Sum, Average, Min, Max) alongside the generated numbers.
  • ✦Optional ascending sort toggle for multi-number draws.

Frequently Asked Questions

What happens if I ask for 10 unique numbers between 1 and 5?
Because there are only 5 distinct integers in the range `[1, 5]`, requesting 10 unique numbers is impossible. The tool validates this upfront and displays a helpful error message.
How does unbiased range sampling work?
Instead of using `randomUint32 % range` (which slightly favors smaller numbers when `range` does not divide `2^32`), rejection sampling discards values above the largest multiple of `range`, guaranteeing a uniform distribution.
Optional Before-Related-Tools Ad Placement (Disabled by Default)

Related Security & Generator Tools

Explore more 100% browser-based utilities in this category.

View All 30 Tools →
Web Crypto

Password Generator

Generate cryptographically secure random passwords using crypto.getRandomValues() with length slider, character set toggles, and entropy strength meter.

RFC 4122 v4

UUID Generator

Generate single or bulk RFC 4122 Version 4 UUIDs using native crypto.randomUUID() with formatting options and TXT export.

100% Offline

QR Code Generator

Generate scannable QR codes locally in your browser from any URL or text with custom pixel size, foreground/background colors, error correction, and PNG download.

SubtleCrypto

SHA-256 Hash Generator

Compute cryptographic SHA-256 hex and Base64 digests locally using the browser's Web Crypto API (crypto.subtle.digest) with hash verification.

Optional Ad Placement Area (Disabled by Default)