A measure of unpredictability, expressed in bits. Higher entropy means more possible values, making the output harder to guess or reproduce.
Bit Strength
The number of binary digits needed to encode all possible values in a password's search space. Each extra bit doubles the difficulty of guessing.
Brute-Force Attack
An attack that systematically tries every possible password combination until the correct one is found. Longer, more complex passwords make this computationally infeasible.
CSPRNG
Cryptographically Secure Pseudo-Random Number Generator. Produces random values that are statistically unpredictable, suitable for generating keys, tokens, and passwords. window.crypto is a CSPRNG.
Character Set (Pool)
The set of unique symbols from which each character in a password is drawn. A larger pool raises the base of the entropy exponent, increasing strength rapidly.
Password Hash
A one-way mathematical transformation of a password into a fixed-length digest. Servers store hashes, not plaintext passwords, so a breach does not immediately expose credentials.
Rejection Sampling
A technique used in this tool to avoid modulo bias. Random bytes that fall outside an even multiple of the pool size are discarded and resampled, preserving uniform distribution.
Modulo Bias
A statistical skew that occurs when mapping a random number range onto a character set whose size does not evenly divide the source range. Rejection sampling eliminates this skew.
The Complete Guide to Cryptographically Secure Password Generation
Most password generators rely on Math.random(), a pseudo-random function designed for game logic and statistical simulations, not security. When your login credentials depend on unpredictability, the underlying random number generator matters enormously. This tool uses window.crypto.getRandomValues(), the browser's CSPRNG, which draws entropy from your operating system's hardware noise pool. The result: a password whose generation process cannot be reverse-engineered, predicted, or replayed.
How to Use This Fabricator
Drag the length slider to set your target password length. Check or uncheck the four character sets (uppercase, lowercase, numeric, symbols) to define the pool of characters the fabricator will draw from. Toggle "Exclude Ambiguous Characters" to remove visually similar symbols if you will be typing the password by hand. The output field, strength badge, and entropy telemetry update instantly with every configuration change. Copy the result with one click or download a session log as a plain text file.
Understanding the Entropy Formula
Password entropy in bits is calculated as E = L x log2(R), where L is the password length in characters and R is the number of unique symbols in the character pool. With all four sets active (95 printable ASCII symbols), a 20-character password yields roughly 131 bits. At 72 bits or above, a password is considered computationally unbreakable against offline brute-force attacks using current hardware. The entropy bar and bit readout update live so you can tune length and character sets to hit your target security threshold.
Why Character Set Size Matters More Than Rules
Legacy password policies requiring capital letters, numbers, and symbols on short 8-character passwords were designed before modern brute-force benchmarks. A GPU cluster running bcrypt can test tens of millions of 8-character permutations per second. The actual defense is entropy: a purely lowercase 18-character random string (entropy 84 bits) is statistically stronger than an 8-character string satisfying every complexity rule (entropy 52 bits). Pool size and length compound each other exponentially, not linearly.
Rejection Sampling: Why This Tool Avoids Modulo Bias
A naive implementation might take a random byte (0-255) and compute byte % poolSize to pick a character. If poolSize is not a power of two, characters with lower index values appear slightly more often. This tool uses rejection sampling: random bytes that fall outside the largest even multiple of the pool size are discarded and replaced, ensuring every character in the pool is chosen with exactly equal probability. The cost is a small number of extra getRandomValues() calls, which are negligible given the CSPRNG's speed.
FAQ: Secure Password Generation
Math.random() is a pseudo-random number generator (PRNG) seeded by a predictable value and designed for speed, not security. Its output can be reverse-engineered by an attacker who observes enough values, allowing them to predict every future output. window.crypto.getRandomValues() pulls entropy from your operating system's cryptographically secure pool, which is seeded by genuinely unpredictable physical sources such as hardware interrupts, mouse timing, and CPU jitter. That seed cannot be observed or reconstructed, making the output computationally infeasible to predict.
Entropy, measured in bits, expresses how many equally likely passwords an attacker must try on average before guessing correctly. Each additional bit doubles the search space. A 40-bit password requires about 1 trillion guesses, which a modern GPU can exhaust in hours. A 72-bit password pushes that estimate past billions of years at current hardware speeds. The formula is E = L x log2(R), where L is password length and R is the size of the character pool. Increasing either variable grows the search space exponentially.
Characters such as uppercase I (eye), lowercase l (el), the digit 1 (one), uppercase O (oh), and the digit 0 (zero) look nearly identical in many fonts and on printed labels. When you type a password into a mobile device, a printed card, or a terminal with a small font, these characters cause transcription errors. Excluding them reduces your effective character set by a small amount, but the reduction in typos and lockouts is usually worth the trade-off, especially for passwords that must also be entered manually.
NIST SP 800-63B (the current US federal password standard) prioritizes length over complexity rules. A random 15-character password drawn from a large character set is stronger than an 8-character password with forced substitutions. Security researchers generally consider passwords with 60 or more bits of entropy to be strong against offline attacks with current hardware. At 128 bits, a password is considered computationally unbreakable for any foreseeable future. This tool shows your live entropy score so you can tune length and character sets until you reach your target threshold.
The main risk with browser-based password generators is that a malicious or compromised page could read the generated string before you copy it. This tool eliminates that risk: all generation uses window.crypto.getRandomValues() locally, no network requests are made, and the page contains no analytics, trackers, or external scripts other than the site-chrome layout injector. You can verify this by opening your browser developer tools and watching the Network tab while generating passwords - you will see zero outbound requests. For maximum assurance, use the tool offline by loading the page once and then disconnecting from the internet before generating passwords you intend to use.