A random number is not automatically a strong password
Unpredictable selection and a large enough set of possible outputs are separate requirements. A tiny range remains easy to guess even with a strong random source.
Random number →Compare possible outputs
A four-digit code allowing 0000 through 9999 has 10,000 possibilities. A six-digit code has 1,000,000 possibilities, one hundred times as many. This integer generator does not preserve leading zeros, so generating 0 through 9999 and displaying 42 is not the same presentation as a four-character code 0042. Decide whether you need an integer or a fixed-length string.
Source quality does not enlarge the range
The random tool uses the browser’s cryptographic random source, but that does not turn a six-sided result into a high-entropy secret. With equally likely outcomes, the best one-try guess still succeeds with probability 1 divided by the number of possible outputs. For an arbitrary four-digit code that is 1/10,000 before considering any retry limits or information leaks.
Use the dedicated tool for passwords
For an account password, use the password generator and follow the service’s length and character requirements; a password manager can store unique credentials. Do not reuse classroom random draws or public lottery outputs as secrets. Security also depends on storage, transmission, phishing resistance and the application’s design. This page explains output spaces and does not certify a homemade authentication or cryptographic system.
Try the calculators
- Random number
Generate a random integer in an inclusive range.
- Permutation and combination calculator
Count ordered and unordered selections of r objects from n distinct objects.
- Password generator
Generate a random password on your device.