AES Encrypt & Decrypt

Encrypt or decrypt text using AES-256 with a password. 100% client-side — your data never leaves your browser.

🔒 100% private: All encryption happens in your browser using AES-256 + PBKDF2 (100,000 iterations). Your plaintext and password are never transmitted.
CBC mode — widely compatible, requires padding.
🔒 100% private: AES-256 + PBKDF2 (100k iterations, SHA-256). Your data never leaves your device. Not recommended for long-term storage of secrets — use a dedicated tool like age, GPG, or a password manager.

About AES Encrypt & Decrypt

AES (Advanced Encryption Standard) is a symmetric encryption algorithm adopted by NIST in 2001. It is used everywhere: TLS/HTTPS, file encryption, VPNs, database encryption, and messaging apps. AES-256 is the strongest common variant (256-bit key). Because AES requires a fixed-size binary key, when you encrypt with a password, the password must be transformed into a key using a Key Derivation Function (KDF) — usually PBKDF2 or scrypt with a random salt. This tool uses AES-256 with PBKDF2 to derive the key from your password, and a random salt + IV for each encryption. The result is a compact, base64- or hex-encoded ciphertext that includes everything needed for decryption (given the password).

How It Works

  1. Encrypt mode: enter your plaintext, enter a strong password, choose a mode, and click Encrypt.
  2. The tool derives an AES-256 key from the password using PBKDF2 (with a random salt).
  3. The ciphertext (with salt + IV) is encoded as base64 or hex.
  4. Decrypt mode: paste the encoded ciphertext and the same password to get the original text.

✨ Key Features

  • ✓AES-256 encryption (strongest common variant)
  • ✓PBKDF2 key derivation (100,000 iterations)
  • ✓Random salt (16 bytes) per encryption
  • ✓Random IV (16 bytes for CBC/CTR, 12 bytes for GCM) per encryption
  • ✓GCM mode (authenticated encryption — recommended)
  • ✓CBC mode (widely compatible)
  • ✓CTR mode (stream cipher)
  • ✓Base64 and hex output formats
  • ✓Password strength indicator
  • ✓100% client-side — your data never leaves your browser

🎯 Common Use Cases

  • →Encrypting sensitive text before sharing over insecure channels
  • →Learning how AES encryption works
  • →Testing AES encryption/decryption in your app
  • →Storing small encrypted secrets locally
  • →Encrypting configuration values
  • →Generating AES test vectors
  • →Comparing AES modes (GCM vs CBC vs CTR)
  • →Quick one-off encryption of a message

💡 Advanced Tips & Pro Insights

  • ▸Use GCM mode (recommended). It is an "authenticated encryption" mode — it detects tampering and prevents a whole class of attacks. CBC and CTR do not authenticate (they are vulnerable to padding-oracle and bit-flipping attacks if used without a MAC).
  • ▸NEVER reuse an IV with the same key. This tool generates a random IV for each encryption automatically.
  • ▸Use a strong password. AES-256 is unbreakable, but PBKDF2 of a weak password is brute-forceable. Combine with a long passphrase (4+ random words).
  • ▸The output ciphertext contains: salt + IV + ciphertext (with authentication tag for GCM). Everything needed to decrypt — given the password.
  • ▸For long-term storage, consider a dedicated tool (age, GPG, 1Password). This browser tool is for learning and quick tasks.
  • ▸Do not use ECB mode — it reveals patterns in the plaintext. This tool does not offer ECB.

Frequently Asked Questions

Is this AES encryption tool free?▾
Yes, this AES encrypt/decrypt tool is completely free with no signup, email, or usage limits.
Is my data safe?▾
Yes, 100% safe. All encryption and decryption happens in your browser using the crypto-js library. Your plaintext and password are never transmitted. However, avoid using this tool for highly sensitive production data — use dedicated tools with audited code paths.
What is AES?▾
AES (Advanced Encryption Standard) is a symmetric block cipher standardized by NIST in 2001. AES-256 uses a 256-bit key. It is used in TLS/HTTPS, VPNs, file encryption, and messaging apps worldwide.
What is the difference between AES modes?▾
CBC (Cipher Block Chaining) is widely compatible but does not authenticate. CTR (Counter) is a stream mode. GCM (Galois/Counter Mode) is authenticated encryption — it detects tampering. Use GCM when possible.
What is PBKDF2?▾
PBKDF2 (Password-Based Key Derivation Function 2) converts a password into a cryptographic key by iterating a hash function many times. It makes brute-force attacks slower by adding computational cost. This tool uses 100,000 iterations.
Why does encryption add random data?▾
AES requires a fixed-size key (256 bits) and a unique IV (initialization vector) per message. This tool derives the key from your password using PBKDF2 with a random salt, and generates a fresh IV. This ensures the same plaintext + password produces different ciphertext every time.
Can I decrypt data encrypted by another tool?▾
Only if the tool uses the same algorithm (AES), the same mode (GCM/CBC/CTR), the same KDF (PBKDF2), and the same encoding scheme. Encryption formats are not standardized across tools. This tool is self-consistent — encrypt and decrypt within it.
Is AES-256 really unbreakable?▾
AES-256 has never been practically broken. A brute-force attack would take longer than the age of the universe with all current computers combined. However, weak passwords, poor key management, and implementation bugs can still compromise security.