Protect PDF with Password
Real PDF encryption with custom-built solution
We built our own lightweight encryption engine that works entirely in your browser. Your PDF will be truly password-protected and will require the password to open in any PDF reader.
Drag & drop PDF to protect
or click to select file
🚀 A Technical Achievement
We built what others said was impossible: Real PDF encryption in under 1MB
The Challenge We Solved:
- ▸Size Constraint: Cloudflare Workers has a 1MB limit. Existing libraries are 2-20MB.
- ▸No Native Code: Edge environments don't support compiled binaries.
- ▸PDF Complexity: PDFs require proper encryption of all objects and streams.
Our Solution:
- ✓Custom Crypto: Hand-crafted MD5 and RC4 implementations in ~7KB
- ✓PDF Standard Compliant: Implements Algorithm 2 & 3 from PDF specification
- ✓Zero Dependencies: Works with just pdf-lib for structure parsing
- ✓Edge-Ready: Pure JavaScript that runs anywhere
For Developers:
Interested in using our lightweight PDF encryption solution in your own projects? We've open-sourced our custom encryption engine as an npm package.
@pdfsmaller/pdf-encrypt-litePackage features: RC4 128-bit encryption • PDF 1.4 compatible • Zero dependencies • Edge-ready • <10KB total
🔐 True Privacy Without Compromises
Your files are processed in memory and immediately discarded
🚫 What We DON'T Do:
- ❌ Save your files to disk
- ❌ Store in databases
- ❌ Keep copies or backups
- ❌ Log file contents
- ❌ Track or analyze your data
- ❌ Share with third parties
✅ What We DO:
- ✓ Process in volatile memory (RAM)
- ✓ Encrypt in milliseconds
- ✓ Return encrypted file immediately
- ✓ Auto-delete from memory
- ✓ Apply PDFKit standard encryption
- ✓ Maintain zero data footprint
Lightning Fast
Encryption in under 1 second
RC4 128-bit
PDF standard encryption
Universal
Works with all PDF readers
Add Password Protection to PDF Files
Your PDF files never leave your device. All password protection happens entirely in your browser using advanced JavaScript technology. Add password protection to PDFs without uploading to any server. Set a password to restrict who can open your PDF, preventing unauthorized access. Control permissions for printing, editing, and copying while keeping your files completely private.
Key Features:
- 100% Private: No server uploads, no data collection. Your files and passwords stay on your device.
- Password Protection: Add a password to prevent unauthorized access to your PDFs.
- Restrict Permissions: Control printing, editing, and copying permissions.
- Secure Encryption: Strong encryption protects your sensitive documents.
- Fast Processing: Instant password protection in your browser with no upload delays.
- Free Unlimited Use: No registration, no limits, protect as many PDFs as needed.
How It Works:
- Select your PDF file from your device
- Choose a strong password for your PDF
- Set permissions (optional): printing, editing, copying restrictions
- Download your password-protected PDF instantly