Network security

Encryption Algorithms Explained: AES, RSA, ECC and Post-Quantum

Most systems use both kinds of encryption at once: asymmetric crypto agrees on a key, then symmetric crypto encrypts the data. Here is how each algorithm fits.

Cysoro Security TeamPublished · 7 min read
AES • RSA • ECCML-KEM • ML-DSA NETWORK SECURITY Encryption algorithms One key locks it. One key opens it.
Quick answer

Encryption algorithms are the math that turns readable data into ciphertext. Symmetric algorithms such as AES use one shared secret key and are fast, so they encrypt bulk data. Asymmetric algorithms such as RSA and ECC use a public and private key pair to agree on keys and sign data. Real systems combine both, and NIST's post-quantum standards ML-KEM and ML-DSA now provide the migration path for the asymmetric half.

Key takeaways

  • Symmetric encryption (AES, ChaCha20) is fast and encrypts bulk data; asymmetric encryption (RSA, ECC) agrees on keys and signs data.
  • Use AES-256-GCM or ChaCha20-Poly1305 for data, TLS 1.3 for transit, and RSA-3072 or ECC P-256 for certificates and signatures.
  • DES, 3DES, RC4 and MD5 belong in history, and NIST's ML-KEM and ML-DSA are the post-quantum standards to plan for.

Every HTTPS page, every encrypted message and every locked disk uses encryption algorithms. You do not need to be a cryptographer to choose well — but you do need to know which family does what, and which names are current in 2026.

What are encryption algorithms?

An encryption algorithm is a mathematical procedure that turns plaintext into ciphertext using a key. Only someone with the right key can reverse it and read the original data.

Per NIST's glossary, encryption is the cryptographic transformation of data into a form that conceals its original meaning so it cannot be known or used without authorization. When the transform is reversible, decryption restores the original plaintext.

Algorithms fall into families. Symmetric algorithms use one shared key. Asymmetric algorithms use a key pair. Hash functions are related but different: they make a one-way fingerprint you cannot decrypt. Most real systems use all three together. NIST explains its role in developing cryptographic standards used worldwide.

How does symmetric encryption work?

Symmetric encryption uses the same secret key to encrypt and decrypt. It is like a house key: the same piece of metal locks and unlocks the door, and anyone who holds it can open the door.

Because the math is comparatively simple, symmetric ciphers are extremely fast. That makes them the only sensible choice for large amounts of data: full disks, database contents, video streams and the payload of every HTTPS connection.

The hard part is key distribution. Both sides need the same secret key, and you cannot safely email it. Production systems therefore establish keys with authenticated key exchange rather than sending secrets directly. You can test a hash of a file with our free hash generator.

Hybrid encryption: how real systems combine both families 1. Agree on a keyRSA, ECDH or ML-KEM 2. Encrypt the dataAES-GCM or ChaCha20 3. Check integritySHA-256 or SHA-3 hash Asymmetric crypto is slow, so it only handles the key. Symmetric crypto is fast, so it handles the bulk data. TLS 1.3, Signal, PGP and most VPNs all follow this pattern.
Hybrid encryption in three steps. Illustration by Cysoro.

What are the main symmetric encryption algorithms?

The main symmetric algorithms in 2026 are AES and ChaCha20-Poly1305. AES is the standard for most systems, while ChaCha20 suits devices without AES hardware acceleration. A 2026 guide to common encryption methods covers the same defaults.

AES and AES-GCM

The Advanced Encryption Standard, specified in FIPS 197, is the dominant symmetric block cipher. It uses 128-bit blocks and keys of 128, 192 or 256 bits, with 10, 12 or 14 rounds depending on key size.

What matters as much as the cipher is the mode. AES-GCM, defined in NIST SP 800-38D, is an authenticated mode: it encrypts and authenticates in one construction, so tampering is detected. Prefer AES-GCM over raw ECB or unauthenticated CBC unless you have a carefully reviewed, specialized design.

ChaCha20-Poly1305

ChaCha20-Poly1305 is a stream-cipher AEAD standardized in RFC 8439. It pairs the ChaCha20 stream cipher with the Poly1305 authenticator, and TLS 1.3 supports it alongside AES-GCM.

It is especially useful on platforms without AES hardware acceleration, where it often outperforms AES-GCM in software. Use a maintained library rather than wiring ChaCha and Poly1305 together yourself.

AES-XTS for disk encryption

AES-XTS is a mode designed for storage encryption, defined in NIST SP 800-38E. It is used by full-disk encryption tools, but it is not authenticated, so it is for storage only, not for general-purpose data.

How does asymmetric encryption work?

Asymmetric encryption uses two mathematically linked keys: a public key you can share with anyone, and a private key you never share. Anyone can encrypt with your public key, but only you can decrypt with your private key.

Think of it as a mail slot: anyone can drop a letter through the slot, but only you have the key to the box. The same pair also signs data: you sign with the private key, and anyone can verify with the public key.

Public-key operations are slower than symmetric ones, so real protocols use them to bootstrap a symmetric session key rather than to encrypt whole files. NIST notes that a hybrid approach is often used, with asymmetric algorithms for signatures and key establishment and symmetric algorithms for everything else.

RSA

RSA, publicly described in 1977, remains widely used for certificates, signatures and some key-transport designs. Key length and padding matter: follow current guidance from your PKI and browser roots, and avoid outdated padding and short moduli.

RSA is comparatively slow and is a priority target for post-quantum transition, especially for long-lived certificates and archived ciphertext. For new RSA deployments, RSA-3072 is the recommended minimum, giving about 128-bit security.

Elliptic-curve cryptography: ECDH, ECDSA and EdDSA

Elliptic-curve cryptography provides public-key operations with smaller keys than RSA at comparable security. A 3072-bit RSA key and a 256-bit elliptic-curve key both give about 128-bit security, per NIST SP 800-57 Part 1 Rev. 5, while RSA-2048 sits at 112 bits.

Common uses are ECDHE for forward-secret key exchange in TLS, and ECDSA or EdDSA for digital signatures. ECC is the workhorse of many 2026 internet protocols, and it is the default in TLS 1.3, SSH and most messaging apps.

Diffie-Hellman key agreement

Diffie-Hellman, introduced publicly in 1976, lets two parties agree on a shared secret over a public channel. Its elliptic-curve form, ECDHE, is the modern default. Diffie-Hellman is a key-agreement primitive, not a bulk data cipher: pair it with an AEAD mode for the actual traffic.

How do encryption algorithms compare?

The table below compares the algorithms you will actually meet. Use it to pick by use case, not by name recognition.

AlgorithmTypeKey sizeSecurityUse for
AES-128-GCMSymmetric AEAD128 bits128-bitData at rest, TLS sessions
AES-256-GCMSymmetric AEAD256 bits256-bitHighest-sensitivity data, TLS
ChaCha20-Poly1305Symmetric AEAD256 bits256-bitTLS, mobile and IoT
RSA-2048Asymmetric2048-bit modulus112-bitLegacy certificates
RSA-3072Asymmetric3072-bit modulus128-bitNew RSA certificates
ECDSA P-256Asymmetric (ECC)256-bit curve128-bitTLS certificates, signatures
Ed25519Asymmetric (ECC)256-bit curve128-bitSSH keys, signatures
ML-KEM-768Post-quantum KEM1184-byte public key192-bitPost-quantum key exchange
SHA-256Hash (not encryption)256-bit digest128-bitIntegrity, signatures

Smaller keys mean less data on the wire and faster signing, which is why ECC is the default in TLS 1.3. RSA is still common in older certificates and hardware.

Which encryption algorithm should you use?

Pick by use case. There is no single best algorithm, because data at rest, data in transit and signatures need different tools.

  • Data at rest: AES-256-GCM for disks, databases and backups.
  • Data in transit: TLS 1.3 with AES-256-GCM or ChaCha20-Poly1305 and ECDHE key exchange for forward secrecy.
  • Certificates and signatures: ECDSA P-256 or Ed25519 for new designs, or RSA-3072 where RSA is required.
  • Passwords: a password-hashing function such as Argon2 or bcrypt, not bare SHA-256 and never plain encryption.
  • Files you send: encrypt with AES-256 in a maintained tool, and share the password through a separate channel.

Check your own site's TLS setup with our free SSL checker, which shows the protocol and cipher your server actually negotiates.

Same security, very different key sizes RSA-30723072-bit key ECC P-256256-bit key Both give about 128-bit security (NIST SP 800-57). RSA-2048 gives only 112-bit security. Smaller keys: less data on the wire, faster signing, easier storage.
RSA vs ECC key sizes for the same security level. Illustration by Cysoro.

What is post-quantum encryption?

Post-quantum cryptography uses algorithms believed to resist attacks from a future quantum computer. Today's RSA and ECC rely on hard problems that a large quantum computer could solve, so NIST ran a multi-year competition to find replacements.

In August 2024, NIST finalized its first three post-quantum standards: ML-KEM (FIPS 203) for key encapsulation, ML-DSA (FIPS 204) for digital signatures, and SLH-DSA (FIPS 205) as a hash-based backup signature algorithm. NIST also selected HQC as an additional key-encapsulation algorithm in March 2025.

Migration is already under way. The most common real-world use is hybrid key exchange in TLS, which pairs X25519 with ML-KEM-768 so a connection stays safe if either one holds. Inventory where you use RSA and ECC, prioritize long-lived secrets, and prefer stacks that advertise crypto agility and ML-KEM support.

Which encryption algorithms should you avoid?

Some algorithms still appear in old lists, but they belong in history, not in new systems. Avoid them unless you are decrypting legacy data that has no other path.

  • DES: a 56-bit key, obsolete for decades; FIPS 46-3 was withdrawn in 2005.
  • 3DES: NIST deprecated it through 2023 and disallowed new encryption with it after December 31, 2023, withdrawing SP 800-67 Rev. 2 on January 1, 2024.
  • RC4: removed from TLS 1.3 and broken in practice; never use it for new traffic.
  • MD5 and SHA-1: hash functions with known collisions; do not use them for signatures or integrity of new data.
  • AES-ECB: a mode that leaks patterns in the plaintext; use AES-GCM instead.

TLS 1.3, defined in RFC 8446, redesigned record protection so its remaining cipher suites are AEAD-only, and legacy options such as 3DES and RC4 are gone. Prefer TLS 1.3 end to end and disable obsolete protocol versions in your configuration.

Is hashing the same as encryption?

No. Hashing is not encryption, and the difference matters when you store passwords. A hash produces a fixed-length digest that is designed to be one-way: you cannot decrypt a hash back to the input.

Hashes support integrity checks, digital signatures and key derivation. For passwords, use a proper password-hashing function such as Argon2 or bcrypt, with a salt, rather than bare SHA-256 alone. Encryption, by contrast, is reversible with the right key, which is what you want for files and messages you need to read again.

If you only remember one rule, make it this: encrypt data you need back, hash data you only need to verify. Mixing them up is one of the most common crypto mistakes in small teams.

The bottom line

Use AES-256-GCM for bulk data, TLS 1.3 for transit, and ECC P-256 or RSA-3072 for certificates and signatures. Avoid DES, 3DES, RC4 and MD5, and start inventorying RSA and ECC use for a post-quantum migration to ML-KEM and ML-DSA.

Good crypto is mostly good defaults: a maintained library, a current TLS version and strong keys. Check your own site's TLS in seconds with the free SSL checker.

Frequently asked questions

What are encryption algorithms?

Encryption algorithms are mathematical procedures that turn plaintext into ciphertext using a key, so only someone with the right key can read the original data. AES, RSA and ChaCha20 are common examples.

What is the difference between symmetric and asymmetric encryption?

Symmetric encryption uses one shared secret key to encrypt and decrypt, and it is fast. Asymmetric encryption uses a public key and a private key, and it is used to agree on keys and to sign data.

What is the most secure encryption algorithm?

For bulk data, AES-256-GCM is the standard secure choice. For key exchange and signatures, ECC P-256 or RSA-3072 are current defaults. Security also depends on key management and using a maintained library.

Is AES-256 unbreakable?

No algorithm is proven unbreakable, but AES-256 with a random 256-bit key is considered secure against known classical and quantum attacks when used correctly in an authenticated mode such as GCM.

What is post-quantum encryption?

Post-quantum encryption uses algorithms that are believed to resist attacks from a future quantum computer. NIST finalized ML-KEM for key establishment and ML-DSA for signatures in August 2024.

Is hashing the same as encryption?

No. Hashing is a one-way fingerprint: you cannot decrypt a hash back to the input. Encryption is reversible with the right key. Hashes are used for integrity checks and password storage.

Should I use RSA or ECC?

For new designs, ECC is often preferred because a 256-bit ECC key gives about the same 128-bit security as a 3072-bit RSA key, with smaller keys and faster signing. RSA remains common for compatibility with existing certificates.

Sources

  1. NIST — Cryptography
  2. CyberExperts — Common Encryption Methods in 2026
  3. Encryption Consulting — Secure Organization's Data With These Encryption Algorithms
  4. Daily Debian — Symmetric vs Asymmetric Encryption Explained
  5. Review42 — Types of Encryption: The Complete Guide (2026)
Written & fact-checked byCysoro Security Team

The engineers and analysts who build Cysoro's domain scanner, email-authentication checks and free security tools. We test what we write about every day — SPF, DKIM, DMARC, certificates, look-alike domains and phishing — and check each guide against the relevant standards, government guidance and vendor documentation.

  • Email authentication
  • Phishing & BEC
  • Domain & DNS security
  • Small-business security

Checked against NIST cryptography standards, FIPS 197, FIPS 203-205 and IETF RFCs for TLS 1.3 and ChaCha20-Poly1305.

How we write and fact-check →

Free tools for this topic

No account needed.

See where your domain stands

Free for up to 3 domains. No card, no installs.

Start free