Ad space (728×90)

Password Generator

Generate strong, cryptographically random passwords in your browser using crypto.getRandomValues. Free, private password generator with no tracking.

← Back to all tools

Why length matters more than complexity

A password's resistance to brute-forcing is a function of how many possible passwords an attacker has to try, which is (pool size) raised to the power of (length). Adding one more character set to the pool — say, going from letters-only to letters-plus-symbols — barely moves that exponent. Adding characters to the length moves it directly. A 24-character password using only lowercase letters has a larger search space than a 12-character password using all four character sets. This is why the strongest lever in this tool is the length field, not the checkboxes.

That said, some systems still enforce character-class requirements ("must contain a symbol"), so the checkboxes exist to satisfy those policies when you can't avoid them.

Why this uses crypto.getRandomValues instead of Math.random

JavaScript's Math.random() is not cryptographically secure — its output can, in principle, be predicted from enough prior outputs, because it's backed by a fast, non-cryptographic PRNG. crypto.getRandomValues(), by contrast, is backed by the operating system's cryptographic random number source (the same class of source used to generate encryption keys). This tool uses it exclusively, with rejection sampling on top so that every character in the selected pool has a perfectly uniform chance of being picked — without rejection sampling, a naive modulo operation would very slightly favor some characters over others.

What this tool doesn't do

It doesn't store, log, or transmit anything — the whole thing runs in this tab and the password never leaves your browser. It also doesn't remember passwords for you across sites; for that, a dedicated password manager is a better fit, since it can also autofill and detect phishing sites that a generator alone can't.