RSA Key Generator
Generate RSA public and private key pairs in PEM format securely in your browser
Related Developer Tools
What Is RSA Key Generator?
The RSA Key Generator creates asymmetric RSA key pairs (public + private) in PEM format directly in your browser. Choose key sizes of 1024, 2048, or 4096 bits. RSA keys are widely used for secure communication, SSH access, JWT signing, TLS certificates, and more.
How to Use
- Select the desired key size (2048-bit recommended for general use)
- Click "Generate Key Pair"
- Copy or download the public key (share this with others)
- Copy or download the private key (keep this secret!)
Features
- Supports 1024, 2048, and 4096-bit key sizes
- Uses the browser Web Crypto API (SubtleCrypto) for secure generation
- Outputs standard PEM-encoded PKCS#8 private key and SPKI public key
- One-click copy and download for each key
- 100% client-side — keys are never sent to any server
Frequently Asked Questions
What key size should I use?
2048-bit is the current industry standard and recommended for most use cases. 4096-bit provides stronger security but is slower. 1024-bit is considered weak and should only be used for testing.
Are these keys safe to use?
Keys are generated using the browser's built-in Web Crypto API (window.crypto.subtle), which provides cryptographically secure random number generation. They are never transmitted or stored.
What is the difference between public and private keys?
The public key can be shared freely — others use it to encrypt data or verify signatures. The private key must be kept secret — you use it to decrypt data or create signatures. Data encrypted with the public key can only be decrypted with the matching private key.
What format are the keys in?
The public key is exported in SPKI (SubjectPublicKeyInfo) format and the private key in PKCS#8 format, both encoded as Base64 PEM. These are the standard formats accepted by OpenSSL, Node.js, Python, and most other tools.