Crypto & Hash

RSA Key Pair Generator

Generate 2048, 3072, or 4096-bit RSA key pairs in the browser and export them as SPKI and PKCS#8 PEM blocks.

Free to use No sign-up Runs in your browser

Tool workspace

What Is an RSA Key Pair Generator?

An RSA key pair generator creates a new public and private key pair for testing, demos, and development workflows that need PEM-encoded key material. This implementation uses the browser Web Crypto API to generate RSASSA-PKCS1-v1_5 keys with SHA-256 at 2048, 3072, or 4096 bits, then exports the public key as SPKI PEM and the private key as PKCS#8 PEM. It does not encrypt the private key with a passphrase, create certificates or CSRs, or store the keys anywhere for you.

How to Use the RSA Key Pair Generator

  1. 1Choose 2048 bits, 3072 bits, or 4096 bits from the Key size dropdown.
  2. 2Click Generate RSA Key Pair and wait for the page to produce both PEM outputs.
  3. 3Copy the Public key and Private key blocks into your test fixture, signing demo, or local configuration, and handle the private key carefully because it is shown in plain text.

Common RSA Key Generation Use Cases

Creating signing test fixtures

Generate disposable RSA keys for automated tests, example payload signing, or local verification workflows without leaving the browser.

Bootstrapping development integrations

Produce PEM material for prototypes that need a quick public and private key pair before you move to a managed key service or HSM.

Teaching PEM and key formats

Show teammates what SPKI public keys and PKCS#8 private keys look like when explaining how browser or server crypto tooling exports RSA material.

Frequently asked questions

Does this tool create encrypted private keys or certificates?

No. It outputs an unencrypted PKCS#8 private key and an SPKI public key only. If you need passphrase protection, certificates, or CSRs, use a dedicated PKI workflow afterward.

Does my private key leave the browser during generation?

The key pair is generated with the browser crypto API and displayed on the page. The tool does not need a remote key-generation service, but you should still treat the visible private key as sensitive material.