Elliptic-curve keys are shorter than RSA equivalents at any given security level and generate faster — a P-256 key pair takes milliseconds in a browser tab versus a second or more for a 4096-bit RSA pair. ECDSA / Ed25519 Key Pair Generator produces ECDSA signing pairs on P-256, P-384, or P-521, plus ECDH key-agreement pairs on P-256 and P-384, using the browser’s built-in SubtleCrypto API. No library is loaded. No key material leaves the tab.
Choose an algorithm, pick PEM or JWK output, and click Generate Key Pair. The private key is blurred by default — click the eye icon to reveal it and the Copy button to capture it. Closing the tab or generating again discards the current pair permanently, so copy before you navigate away.
Getting Your First Key Pair
- Select an algorithm. ECDSA P-256 is the right default for most uses: it is the curve behind JWT ES256, TLS certificates on virtually every CDN, and code-signing in many CI pipelines.
- Choose PEM for server configs, OpenSSL, and anything that expects a
-----BEGIN … KEY----- block. Choose JWK for JWT libraries, JWKS endpoints, and browsercrypto.subtle.importKey calls. - Click Generate Key Pair. The public key appears immediately. The private key panel shows a row of dots until you click the eye icon.
- Copy the private key with the Copy button on its panel. The non-obvious feature: clicking Copy on the private key panel works even when the key is still blurred — you never have to reveal it on screen to copy it safely to a clipboard manager.
When to Use Each Algorithm
- ECDSA P-256 (ES256): the broadest compatibility. Every modern TLS stack, JWT library and WebCrypto implementation supports it. Start here unless a spec or compliance requirement names a different curve.
- ECDSA P-384 (ES384): required by some government and financial standards (e.g. CNSA Suite). Slower than P-256 by roughly 2x but offers a substantially larger security margin.
- ECDSA P-521 (ES512): the largest NIST curve. Use only when P-521 is explicitly required; it is not the most common JWT algorithm despite the name ES512.
- ECDH P-256 / P-384: key agreement, not signing. These pairs establish a shared secret between two parties without either side revealing their private key. They cannot sign or verify and produce no useful JWTs on their own.
Edge Cases Worth Knowing
- Keys are not stored anywhere. SubtleCrypto returns the key material directly to JavaScript memory. When you navigate away or generate a new pair the previous private key is gone. There is no recovery. Copy it before you close the tab.
- PEM output uses SPKI for the public key and PKCS#8 for the private key. Some older tools expect SEC1 format for EC private keys instead of PKCS#8. If a tool rejects the private key, run it through
openssl pkcs8 -nocrypt -in key.pem -out ec.pemto convert. SPKI public keys are universally accepted. - JWK private keys include the public components. A JWK private key contains both
x/y (public) and d (private). Strip d to get a JWK public key, or use the separate public key panel which exports without d already.