Generate cryptographically secure random tokens and API keys (hex or base64url) online, in your browser.
Generate a cryptographically secure random token — perfect for API keys, session secrets and reset links. Choose how many bytes of entropy and whether you want hex or URL-safe Base64 output.
32 bytes (256 bits) is a strong default for secrets and API keys. 16 bytes is fine for less sensitive identifiers.
hex is unambiguous and easy to log; base64url is shorter and URL-safe. Both come from the same secure random bytes.