Security & Utilities

Password & API Key Generator

Generate high-entropy cryptographic passwords, prefixed API keys, and hex secrets locally.

Runs 100% locally in your browser
24
5
Cryptographic Entropy0 bits (Cryptographic)
Unbiased CSPRNG via Web Crypto API (crypto.getRandomValues) — zero network transmission0 bits

What Does the Password & API Key Generator Do?

The Password & API Key Generator produces high-entropy credentials using your browser's native CSPRNG (crypto.getRandomValues) with rejection sampling to eliminate modulo bias.

Switch between customizable Passwords (8–128 characters with ambiguous character exclusion), Prefixed API Keys (e.g., sk_live_...), Hexadecimal Secrets (ideal for JWT_SECRET / NextAuth secrets), and URL-safe Base64url tokens.

Every generated credential displays its exact cryptographic entropy in bits (length × log2(charsetSize)) so you can verify compliance with 128-bit or 256-bit security policies.

How to Use This Tool

  1. Select your output format (Password, Prefixed API Key, Hex Secret, or Base64url Token).
  2. Adjust length, quantity, and character groups, then inspect the calculated entropy bar.
  3. Copy individual credentials, copy the full batch, or download as a .txt file.

Common Engineering Use Cases

  • Generating NEXTAUTH_SECRET, JWT_SECRET, webhook signing keys, or database passwords for production environments.
  • Creating batches of unique, non-ambiguous passwords or API credentials for staging and CI pipelines.

Practical Developer Examples

256-Bit Hex Signing Secret for Environment Variables

A 64-character hexadecimal string provides 256 bits of cryptographic entropy.

Input
Format: Hex Secret, Length: 64
Output
9f86d081884c7d659a2feaa0c55ad015a3bf4f1b2b0b822cd15d6c15b0f00a08

Common Mistakes & Pitfalls to Avoid

  • Generating API secrets or session keys with Math.random(), which is deterministic and unsafe for security credentials.
  • Using short 8-character passwords when modern GPU cracking rigs evaluate billions of guesses per second.

Frequently Asked Questions

Are generated passwords or API keys ever logged or sent to a server?

Never. Every random byte is produced locally inside your browser tab via window.crypto.getRandomValues() and cleared when you close or refresh the tab.