AES key generator
Generate a cryptographically secure random AES key (128, 192, or 256-bit) and a fresh IV, shown in hex and Base64. Created locally with WebCrypto.
How to use the aes key generator
- Choose a key size (128, 192, or 256-bit).
- Press Generate.
- Copy the key (hex or Base64) and the IV into your encryption tool.
Using these values
An AES key is raw random bytes, not a password, so it must be generated by a secure random source, which is exactly what your browser's WebCrypto does here, locally and without sending anything. AES-256 is the common default; AES-128 is also genuinely strong. The IV/nonce makes each encryption unique: use a fresh one for every message under the same key, and never reuse it (especially with AES-GCM). The hex and Base64 forms are the same key in two notations: use whichever your library expects. Store the key in a secrets manager or keychain, never in source control.
Code & API examples
Use this from the command line or your code.
openssl rand -hex 32
openssl rand -hex 12
See all endpoints at /api/tools/.
Frequently asked questions
vpn.golf is a no-logs WireGuard VPN. Pick a hole, take the shot.
Step up to the tee for free