How-to
AES-256 Encryption for Files and Text Before Sending
This guide shows how to encrypt either a sensitive text note (up to 1 MB, or 1,048,576 bytes) or a binary file (up to 100 MB as a .enc file) in your browser before sending it by email or chat. The AES Encrypt tool runs AES-256-GCM with 310,000 PBKDF2-SHA-256 iterations locally, producing either pasted ciphertext or a downloadable .enc attachment. Share the passphrase separately from the encrypted payload.
AES-256 Encryption for Files and Text Before Sending
Step by step
- Open the Password Generator, set the length to at least 20 characters with every character class enabled, and generate a passphrase. Copy it somewhere temporary; you will share it with your recipient through a different channel than the one carrying the encrypted content, for example a phone call or a separate messaging app.
- Open the AES Encrypt tool and choose Text (<= 1 MB) for pasted notes and API keys, or File (<= 100 MB) to drop any binary document, image, or archive. Paste the passphrase from step 1 and click Encrypt. The tool derives a key with PBKDF2-SHA-256 (310,000 iterations) and encrypts with AES-256-GCM in your browser, returning Base64URL/Hex text or downloading a binary .enc file.
- Send the ciphertext block in your message or attach the .enc file to your email. Separately, tell your recipient the passphrase through the other channel, and ask them to open the same tool, switch to Decrypt (Text or File), load the ciphertext or .enc file with the passphrase, and recover the original data.
How this compares to uploading a file to an online encryption service
Many services that offer to encrypt a file work by receiving your file on their server, encrypting it there, and letting you download the result: the plaintext content passes through a system you do not control, if only for the seconds it takes to process. The AES Encrypt and Password Generator tools here run entirely in your browser using the Web Crypto API: encryption uses AES-256 in GCM mode, and the passphrase is stretched into a key with PBKDF2-SHA-256 at 310,000 iterations, with a fresh random salt and initialization vector every time. None of the plaintext, file bytes, passphrase, or ciphertext is sent to any server during the process.
| Feature | AES-256-GCM (Authenticated) | AES-256-CBC (Legacy) | ZIP Crypto (PKZIP / Deflate) |
|---|---|---|---|
| Reference | NIST SP 800-38D · 128-bit Auth Tag | NIST SP 800-38A + HMAC-SHA256 | Legacy CRC-32 Stream Cipher (Broken) |
| Scope | PBKDF2-HMAC-SHA256 (310,000 iter) | PBKDF2 / Argon2id | Fixed Insecure Password Hash |
Sharing the passphrase without undoing the protection
Encryption only protects a message or .enc attachment if the passphrase travels separately from the ciphertext. Sending both in the same email thread, or right after each other in the same chat, gives anyone who reads that thread everything they need. Read the passphrase aloud on a call, send it through a messaging app unrelated to the one carrying the encrypted file, or hand it over in person for anything genuinely sensitive. Store it afterward in a password manager rather than leaving it in the conversation.
| Feature | Base64URL Text (≤ 1 MB) · .enc File (≤ 100 MB) | Out-of-Band Passphrase Delivery | DevTools Zero-Upload Audit |
|---|---|---|---|
| Reference | UTF-8 Text String or Binary .enc Blob (SA v1) | Never Send Passphrase in Same Email / Thread | F12 → Network (Fetch/XHR: 0 B) |
| Best for | Paste in Chat/Email or Attach .enc (≤ 100 MB) | Signal · Matrix · SMS · In-Person QR Code | 0 B Transmitted (Air-Gap Ready) |
Choosing between .enc encryption, PDF passwords, and desktop tools
The AES Encrypt tool handles pasted UTF-8 text up to 1 MB and arbitrary binary files up to 100 MB (saved directly as binary .enc without Base64 bloat). Because .enc is a binary AES-256-GCM format, your recipient decrypts it in the same browser tool rather than opening it directly in a document reader. If you are sending a PDF that the recipient needs to open natively in any PDF viewer with a prompt, adding password protection with the PDF Password tool (also up to 100 MB) is a better fit. For files larger than 100 MB or entire folder trees, pack an archive or use desktop tools such as 7-Zip, Cryptomator, or age.
The tools used in this guide
- AES Encrypt / DecryptEncrypt or decrypt text (up to 1 MB) and binary files (.enc up to 100 MB) with AES-256-GCM and PBKDF2-SHA-256.
- Password GeneratorCreate strong random passwords or memorable passphrases with entropy calculation, custom symbols, NATO phonetics, and bulk export.
- Base64 Encoder / DecoderEncode UTF-8 text or files to Base64, Base64URL, or Data URIs, and decode Base64 to text or binary files.
- Password-protect PDFEncrypt PDFs with AES-256/128 passwords, restrict printing or text copying, and strip metadata locally.
Frequently asked questions
Is the passphrase, file, or text I encrypt ever sent to a server?
No. The Password Generator and the AES Encrypt tool run entirely in your browser using crypto.getRandomValues and the Web Crypto API's crypto.subtle. Nothing you type or drop is transmitted anywhere at any point; you can confirm this yourself by opening your browser's developer tools, watching the Network panel, and running through the whole process.
What happens if the passphrase is lost?
The ciphertext or .enc file cannot be recovered without it. There is no recovery option and no backdoor: PBKDF2 at 310,000 iterations makes brute-forcing a genuinely random 20-character passphrase impractical. Keep the passphrase in a password manager rather than only in the conversation where you shared it, so losing that one message does not also cost you the file.