Public Key Encryption
Public key encryption uses a pair of linked keys: a public key that can be shared with anyone, and a private key the owner keeps secret. Data encrypted with the public key can only be decrypted with the private key.
Also called: public key cryptography, asymmetric encryption, private key, public key, key pair, RSA, post-quantum cryptography
What is public key encryption?
Public key (asymmetric) cryptography, as NIST describes it, uses two mathematically related keys. The public key can be published openly. The private key stays secret with its owner. What one key locks, only the other can unlock, and you can't work out the private key from the public one.
How public and private keys work
- Encryption: anyone can encrypt a message with your public key; only your private key can decrypt it.
- Digital signatures: you sign data with your private key; anyone can check the signature with your public key, proving it came from you and wasn't changed.
- Key exchange: two parties use public key methods to agree on a shared secret, then switch to faster symmetric encryption. This is how TLS works.
Public key cryptography underpins HTTPS, digital certificates, passkeys, code signing, secure email and end-to-end encryption.
Protecting private keys
If a private key leaks, an attacker can impersonate its owner, decrypt data or sign malicious software. Store private keys in hardware where possible (security keys, TPM chips, hardware security modules or cloud key services), never in code or shared folders, and revoke and replace them immediately if exposed.
Post-quantum cryptography
Large quantum computers could one day break today's common public key algorithms such as RSA and elliptic curve. In 2024 NIST published its first post-quantum standards, including FIPS 203, and vendors are beginning to roll them out. For most businesses, the action now is to keep systems updated and ask vendors about their post-quantum plans.
Related terms
Sources
Drafted with AI assistance, then edited and fact-checked by a person. How we use AI.
