Random Password Generator

Free, browser-based generator for passwords, passphrases, AES encryption keys, UUIDs, and API tokens, built on the Web Crypto API. Nothing you generate here ever leaves your device.

100% client-side No account, no sign-up No data stored or logged

Generator tool

NIST SP 800-63B-4 recommends 15+ characters when a password is your only login factor.

Character password options
Guarantee at least this many (optional)

Pure random selection can occasionally under-represent a category. Set a minimum to guarantee it appears, useful for sites with "must include a symbol" rules. Leave at 0 for maximum randomness (recommended by most security teams).

Generate multiple
Click Generate to create one.

Not sure whether to use the password or passphrase mode? See Password vs Passphrase.

Generating a WiFi password specifically? The dedicated WiFi Password Generator stays within the WPA2/WPA3 8-63 character limit and avoids ambiguous characters by default.

Generating a master password for a password manager? Use passphrase mode at 6+ words, or character-password mode at 20+ characters. It's the one password you'll actually type and remember, so passphrase mode is usually the easier choice, and it doesn't need to change from what's already here.

How this tool works

Every value this page generates comes from your browser's own Web Crypto API, specifically crypto.getRandomValues() for passwords, passphrases, encryption keys, API keys, and hex strings, and crypto.randomUUID() for UUIDs/GUIDs. Both are specified to return cryptographically strong random output, unlike Math.random(), which is not suitable for security purposes. That's the same class of mechanism described in NIST's recommendations for deterministic random bit generators. See What Is a CSPRNG? for the full explanation, including a live side-by-side demo and a real recent example of what goes wrong when this distinction gets ignored.

One nuance worth being upfront about: MDN's own documentation notes that for values you'll use directly as a non-extractable cryptographic key inside the Web Crypto API, SubtleCrypto.generateKey() is the preferred method, partly because it's guaranteed to run in a secure context. This tool exports plain hex/Base64 text you can paste into another system's config or codebase, the common real-world reason to use a browser key generator, so getRandomValues() is the right tool for that job. If you're generating a key to use directly inside a Web Crypto application, use generateKey() instead.

On the topic of secure contexts: crypto.getRandomValues(), which powers the Password, Passphrase, Encryption Key, API Key, and Random String/Hex panels, doesn't actually require HTTPS. It's the one member of the Crypto interface specified to work in both secure and insecure contexts. crypto.randomUUID() and crypto.subtle (used for hashing, TOTP/JWT signing, and UUID v5) are the parts that genuinely require a secure context and won't work without HTTPS. This site is served over HTTPS throughout, so none of this affects anything here. It's just worth knowing precisely which piece needs what, rather than treating "HTTPS required" as a blanket rule for the whole API.

Sources:
  • NIST SP 800-90A Rev. 1, Recommendation for Random Number Generation Using Deterministic Random Bit Generators, csrc.nist.gov
  • MDN Web Docs, Crypto: getRandomValues() method, developer.mozilla.org
  • MDN Web Docs, Crypto: randomUUID() method, developer.mozilla.org
  • MDN Web Docs, Crypto interface, secure-context requirements per member, developer.mozilla.org
  • NIST SP 800-63B Revision 4, Digital Identity Guidelines: Authentication and Authenticator Management (password length guidance used in the Password/Passphrase panel), csrc.nist.gov

Frequently asked questions

Does RandomKeyGenerator.com store or transmit anything I generate?

No. Every value is generated by JavaScript running in your own browser. Nothing is sent to a server, logged, or saved after you leave or refresh the page. Read more about how and why we built it this way.

Is this actually cryptographically secure, or just "random-looking"?

The Web Crypto API's getRandomValues() method is specified to return cryptographically strong random values, a different category from Math.random(), which is not cryptographically secure. See the sources linked above.

Should I use an online generator for production encryption keys?

For personal and development use, a client-side generator like this is fine, since the key never leaves your browser. For production secrets protecting real systems, many security teams still prefer generating keys locally (e.g. with OpenSSL or a language's built-in secrets module) simply to avoid depending on any third-party page at all. This tool is built so you can verify nothing leaves your browser. That verification is still worth doing yourself for anything mission-critical.