Creating a credential you will store in a password manager
Maximise length and alphabet; you never type it. Twenty or more characters with all classes enabled puts an offline attack far beyond feasibility even against fast hashes.
Generates cryptographically strong random passwords.
—Generates cryptographically strong random passwords.
Length 20, all character classes
7$kQp2!vRz9@mXc4#Lw5
Generated with the browser's crypto API.
Entropy estimates how many guesses an attacker needs; more is better.
Your input is processed entirely in your browser and never sent to a YAS server.
curl -X POST "https://yas.sh/api/v1/tools/password-generator" \
-H "Content-Type: application/json" \
-d '{"length":24,"count":1}'const res = await fetch("https://yas.sh/api/v1/tools/password-generator", {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify({
"length": 24,
"count": 1
}),
});
const data = await res.json();import requests
r = requests.post("https://yas.sh/api/v1/tools/password-generator", json={"length":24,"count":1})
data = r.json()| Field | Type | Required | Description |
|---|---|---|---|
| length | integer | No (default 20) | 8–128 |
| count | integer | No (default 1) | 1–10 passwords |
| mode | "full" | "alnum" | No (default "full") | Charset (full includes symbols, unambiguous alnum) |
{ "slug": "password-generator", "length": 24, "result": "<password>" }CSPRNG passwords, 8–128 chars, optional alnum-only sets.
400 VALIDATION_ERROR — invalid input or unsupported option.413 PAYLOAD_TOO_LARGE — input exceeds the 64 KB limit.429 RATE_LIMIT_EXCEEDED — rate limit exceeded (60 req/min).Randomness comes from crypto.getRandomValues(), the browser's cryptographically secure pseudorandom number generator, which is seeded from the operating system entropy pool. Math.random() is never used: it is a fast non-cryptographic PRNG whose internal state can be recovered from a handful of outputs, which would make every generated password predictable.
Characters are drawn from the selected alphabet using rejection sampling rather than a modulo reduction. Taking a random byte modulo an alphabet size that does not divide 256 makes the first few characters of the alphabet slightly more likely; rejecting out-of-range values and drawing again keeps the distribution uniform, which is what the entropy calculation assumes.
Strength is measured in bits of entropy: length × log2(alphabet size). A 16-character password from the 94 printable ASCII characters is about 105 bits. Entropy describes the generator, not the string — 'aaaaaaaa' drawn from a 94-character alphabet still carries the same entropy as any other 8-character draw, because the attacker cannot know which one you got.
Maximise length and alphabet; you never type it. Twenty or more characters with all classes enabled puts an offline attack far beyond feasibility even against fast hashes.
Machine credentials should be long and rotated. Disable ambiguous characters if the value passes through shell scripts, connection strings or YAML, where quoting mistakes cause outages more often than weak passwords cause breaches.
Use the Passphrase Generator instead. Four or five random words carry 50–65 bits of entropy and can be entered on a D-pad without transcription errors.
Some systems demand at least one character from each class and cap the length. Enable the classes, set the maximum allowed length, and accept that the policy — not the generator — is the limiting factor.
What this tool deliberately does not do, and where it will disagree with other implementations.