DevTools Logo

API Key Generator

API Key Generator

Prefixed, bulk, checksum — for test fixtures only

Runs in your browserRuns in your browser

Configuration

Config: 10 keys × 24 chars

Generated Keys

No keys generated

Configure and generate API keys

Keys are test fixtures only — never use as real credentials

0 keys0.0 bits (weak)
Try an example

About this tool

Generates production-shaped API keys with custom prefixes (sk_, pk_), lengths, alphabets, optional checksum digits, and bulk export — seeded for dev teams wiring auth systems who need realistic, entropy-honest keys. The mechanism is crypto.getRandomValues rejection-sampled over a chosen alphabet with prefix/format composition, plus a mod-47-style checksum option and .env/CSV export templates.

How to use this tool

  1. Choose preset or configure

    Pick a preset (Stripe, GitHub, Hex) or set custom prefix, body length (8–128), and count (1–100).

  2. Select alphabet

    Base62 (default), Base58 (no lookalikes), Hex lower/upper, Alphanumeric+dash, or Custom (≥16 unique chars).

  3. Enable options

    Add mod-47 checksum digit for Stripe-like realism. Add expiry suffix (YYYY-MM). Set seed for reproducible fixtures (NOT secure).

  4. Generate

    Click Generate. Keys appear in the output panel with entropy readout.

  5. Export

    Choose Plain, .env, CSV, or JSON format. Copy or download.

Frequently asked questions

Are these real API keys?

No. These are fixture keys for testing and development only. They have the shape of real keys (prefix, checksum) but are randomly generated. Never use them as real credentials.

How much entropy do the keys have?

Entropy = bodyLength × log2(alphabetSize). For 24-char Base62: ~190 bits. For 8-char Base62: ~48 bits (warning shown). Always shown per configuration.

What is a checksum digit for?

Adds Stripe-like realism. The last character is computed from the key body (mod-47 over alphabet indices). A verifier can detect typos. It does not make the key cryptographically stronger.

Can I use these in production?

Absolutely not. They are test fixtures. For production, use your provider's key generation (OpenAI, Stripe, GitHub, etc.) or a proper secret management system.

Which alphabet should I pick?

Base62 for general IDs. Base58 if you need human-safe transcription (excludes 0/O/I/l). Hex for webhook secrets. Custom for your own character set.