Are online password generators safe?
· 3 min read
Key takeaways
- An online generator is safe when the password is created in your browser with a cryptographically secure random number generator and never sent anywhere.
- Red flags: passwords generated on a server, ad or session-recording scripts on the page, analytics that capture what you click or type, or passwords that appear in the URL.
- You can check by opening your browser's Network tab, or by going offline and confirming generation still works.
- No website can protect you from malware or a malicious browser extension on your own device.
Last reviewed
It's a fair question: you're asking a website to create the secret that protects your accounts. The answer depends entirely on where the password is created and what else runs on the page — and you can check both yourself.
What makes a generator safe
- It runs in your browser. The password should be created by JavaScript on your device and never sent to a server. If a server generates it, you have to trust that server not to log it.
- It uses a cryptographically secure random source. In browsers that means the Web Crypto API (
crypto.getRandomValues). The everydayMath.random()is not designed for secrets. - It picks characters without bias. A common shortcut (
random % n) makes some characters slightly more likely. Good generators use rejection sampling instead. - Nothing else on the page can read it. Third-party scripts — ads, analytics, session recording, chat widgets — run with the same access to the page as the generator itself.
Red flags
- The password appears in the address bar or in a shareable link.
- The page loads ads, session recording, or analytics that record your clicks and form activity from other companies' servers.
- Generating a password triggers a network request (visible in developer tools).
- The site asks you to sign in, or offers to "save" generated passwords for you.
- No explanation of how passwords are generated.
Check it yourself in under a minute
- Watch the network. Open your browser's developer tools (F12 or ⌥⌘I), select the Network tab, and click Generate a few times. A safe generator makes no requests when you generate or copy.
- Go offline. Load the generator, then turn off Wi-Fi or mobile data. If it still generates passwords, it isn't relying on a server to do it.
- Look at the address bar. The password should never appear in the URL — URLs end up in browser history, logs and analytics.
How Password Generator Lab handles this
Every tool here runs in your browser using the Web Crypto API with rejection sampling. Google Analytics counts page views — in Europe only if you allow it, elsewhere unless you decline. It's set up only to measure page traffic (page views, scrolling, links followed) and never receives what you generate or type, but like any third-party script it runs on the page, so choose Decline if that matters to you. Generated passwords stay out of URLs, cookies and storage. It works offline after your first visit, and a strict Content Security Policy limits which code can run. Our automated tests check that generating, copying and downloading never trigger a request containing a password. The methodology and threat model explain the details — and you can verify all of it with the checks above.
What no website can protect you from
If your device has malware or a malicious browser extension, it can read anything on screen — including a password generated locally. Keep your system and browser updated, install extensions sparingly, and use the Hide button when others can see your screen. Your password manager's built-in generator is also a fine choice; the same principles apply.
Bottom line
A well-built online generator is as safe as an offline one, because the password never leaves your device. Choose one that runs locally, keeps third-party scripts to a minimum (and lets you turn them off), and lets you verify both.
Generate a password · How to create a strong password
Sources
Keep reading
- How are passwords cracked?How attackers really get passwords: phishing, credential stuffing, online guessing and offline cracking of stolen hashes, and what length and randomness change.
- Do you need a password manager?Why password reuse is the real risk, how password managers protect your vault, the honest tradeoffs, and how to choose one and set it up safely.
- Two-factor authentication (2FA) explainedWhat 2FA is, which methods resist phishing, whether SMS codes are safe, how to handle MFA fatigue and recovery codes, and where to turn it on first.
- Strong password examples (2026)What strong passwords and passphrases look like, why you should never reuse a published example, and fresh ones generated privately on your device right now.