Password Generator

This generator draws a password in your browser with the Web Cryptography API (crypto.getRandomValues). It does not use Math.random(), and it does not send the result to a server. Choose a length from 8 to 128 and a character set — letters only, letters and digits, or letters, digits and symbols — then use Generate again for a new draw. The page also reports the Shannon entropy of a uniform draw, which is length × log₂ of the alphabet size, not a claim that a particular string is unguessable.

By Rashid MehmoodLast updated and reviewed Free, no sign-up

Password generator

–

How to use the password generator – random passwords in your browser

  1. Choose a length. From 8 to 128 characters. The default is 16.
  2. Choose a character set. Letters; letters and digits; or letters, digits and symbols.
  3. Read the draw. A new password is drawn when the length or set changes, and when you press Generate again. Precision changes do not redraw it.
  4. Copy or print. Copy result copies the string. The page does not store it on a server. Save tool only bookmarks this page in this browser.
Embed this calculator

Paste this iframe on your own site. The embed view already includes a visible “Calculator by CalcTen” credit, which must stay visible. See the developers page for the conditions.

How the draw works

A cryptographically suitable generator needs an unpredictable source of bits and an unbiased way to map those bits onto a character set. This page asks the browser for 32-bit values via crypto.getRandomValues. It then keeps a value only when it is strictly less than the largest multiple of the alphabet size that fits in 2³², and maps the remainder onto a character. That rejection step avoids the small bias you get from a naive n % alphabetLength when the alphabet size does not divide 2³².

Math.random() is a different tool. The random-number generator on this site uses it for everyday draws (dice, raffles, classroom lists) and the page says so. Do not use that page to pick a password.

The entropy line is arithmetic, not a score. A 16-character password from a 62-character alphabet (letters and digits) has 16 × log₂(62) ≈ 95.3 bits in the uniform model. Adding symbols enlarges the alphabet and the figure. The bar on the diagram is that number on a 0–128 scale. It does not know whether you will reuse the string, write it down, or pick a memorable variant.

Generate again draws a new string with the same settings. Changing the Decimals control does not redraw, so a copied password is not silently replaced when you tidy a display. Copy link writes only the inputs to the URL hash; opening that link produces a new draw, which is the safe behaviour.

This is not a substitute for a password manager, two-factor authentication, or a service’s own generator. It is a transparent, testable draw you can run offline once the page has loaded. Store the result in a manager; do not paste it into a search box or a shared document.

Print / Save PDF will include the current draw on the paper or file you keep. Treat that file as a secret if you print one. The about box on this page has a report-a-mistake link if the entropy arithmetic or the alphabet listing looks wrong.

Frequently asked questions

Is this the same as the random number generator?

No. The random-number page uses Math.random() and says so. This page uses crypto.getRandomValues and rejection sampling so the modulo of the alphabet does not bias the last characters.

What does the entropy figure mean?

It is length × log₂(alphabet size), the Shannon entropy of a uniform independent draw from that alphabet. It is not a strength meter and it does not model reused passwords or keyboard patterns.

Does CalcTen save the password?

No. The draw happens in your browser. Copy link stores only the length and character-set choices in the URL hash, not the password itself (a new draw happens when the page is opened).

Which symbols are included?

A fixed set: !@#$%^&*()-_=+[]{};:,.? when you choose the letters-digits-and-symbols option. Ambiguous look-alikes are not stripped automatically.

Why is the minimum length 8?

Shorter strings are easy to try online even when the alphabet is large. Many services require at least 8 characters; longer is usually better. This page is not a review of any site’s policy.

Can I use this for a site login?

You can copy the result into a password manager. Do not email it or paste it into a chat. This page is not an account manager and does not check whether a password has appeared in a breach list.

What if crypto.getRandomValues is missing?

The generator refuses to draw rather than falling back to Math.random(). Modern browsers provide the API.

Sources and references

About this calculator

Written and maintained by Rashid Mehmood, founder of CalcTen. The formulas are unit-tested against hand-worked examples, and the content is reviewed whenever product sizes or guidance change. Last updated and reviewed 15 November 2026. See our editorial policy. If you spot a mistake, report it.

Results are calculated from the numbers you enter and shown with the working. Rounding is applied only when displaying results. Grade and GPA scales, and weighting rules, vary by school, so confirm with your institution. Read the disclaimer.

Calculator by CalcTen — free online calculators.