ToolboxHub

🗝️RSA Key Pair Generator

Generate RSA public/private key pairs for encryption.

Share:
Generates RSA-2048 key pair using SubtleCrypto. These are SPKI/PKCS8 format keys, not PGP format — for educational use only.

About RSA Key Pair Generator

RSA Key Pair Generator creates public and private RSA key pairs at 2048-bit or 4096-bit strength entirely within your browser using the Web Crypto API. Use the generated keys for asymmetric encryption, digital signatures, SSH authentication, or learning how public-key cryptography works.

How to Use RSA Key Pair Generator

  1. 1

    Choose key size

    Select 2048-bit for standard use or 4096-bit for higher security applications.

  2. 2

    Generate the key pair

    Click 'Generate Keys' and wait a moment while the key pair is created using the Web Crypto API.

  3. 3

    Copy and save your keys

    Copy the public key and private key from their respective panels. Store the private key securely — never share it.

Common Use Cases

  • Generating RSA keys for use in SSH server authentication
  • Creating key pairs for asymmetric encryption in custom applications
  • Learning how RSA public/private key cryptography works
  • Producing test keys for development and staging environments

Frequently Asked Questions

What is the difference between 2048-bit and 4096-bit RSA keys?
4096-bit keys provide a higher security margin than 2048-bit keys but are slower to generate and use. 2048-bit is considered secure for most uses through 2030+; 4096-bit is recommended for long-lived keys or high-security applications.
In what format are the generated keys?
Keys are generated and exported in PEM format (the standard BEGIN RSA PRIVATE KEY / BEGIN PUBLIC KEY format), making them compatible with OpenSSL, SSH, TLS, and most cryptographic libraries.
Is it safe to generate RSA keys in the browser?
Yes — key generation uses the browser's Web Crypto API, which calls the operating system's cryptographically secure random number generator. The keys are generated locally and never transmitted anywhere.

Related Tools