Skip to content
BEAD

NanoID Generator

Short, URL-safe random IDs with custom alphabets and collision probability estimates.

Collision probability across 1,000,000,000 IDs: < 1 in 10^18 (≈ 126.0 bits)
ZoHlX5PuMUbLHisigm6lE
xWLH_eoLSbMydYTQfd7M7
zYsqqsH-TBrxN1edJpsrw
tnHJSZdqMzWSjSJrQJLV6
3zLJky5u_B_PMxnOrbq6k
</>Use this tool programmaticallycurl · JavaScript · MCP

Same tool, callable from any HTTP client or from Claude (via MCP). Anonymous: 100 req/day per IP. Sign up for 1,000 req/day.

curl
curl https://api.b-e-a-d.com/tools/nanoid-generator/run \
  -H "Content-Type: application/json" \
  -d '{
  "preset": "default",
  "length": 21,
  "count": 1
}'
JavaScript (fetch)
const res = await fetch("https://api.b-e-a-d.com/tools/nanoid-generator/run", {
  method: "POST",
  headers: { "Content-Type": "application/json" },
  body: JSON.stringify({
  "preset": "default",
  "length": 21,
  "count": 1
}),
});
const data = await res.json();
console.log(data.result);
MCP (Claude Desktop / Claude Code)
# In Claude Desktop / Claude Code, add to your MCP config:
{
  "mcpServers": {
    "bead": {
      "command": "npx",
      "args": ["-y", "mcp-remote", "https://mcp.b-e-a-d.com"]
    }
  }
}

# Then ask Claude to call:
mcp__bead__bead_nanoid_generator

Full reference: developer docs · OpenAPI spec

What is NanoID?

A short, URL-safe random ID. The default alphabet has 64 symbols (A-Za-z0-9_-) and the default length is 21 — that's ≈126 bits of entropy, comparable to a UUIDv4 in less space and without dashes.

Picking a length

Use the collision-probability estimate to size the ID for your volume. For 1 billion IDs at the default alphabet, 21 characters keeps collision risk below one in a trillion.

You might also like