A modern web application built with Django that converts between Base64 strings and image files. Supports drag-and-drop, paste from clipboard, and PDF to image conversion.
- ✅ Image ↔ Base64 Conversion - Upload images or paste Base64 strings
- ✅ Drag & Drop Upload - Simple file drop with visual feedback
- ✅ Clipboard Paste - Paste screenshots and copied images with
Ctrl+V - ✅ PDF Support - Convert first page of PDF to image
- ✅ Multiple Formats - PNG, JPEG, GIF, BMP, WebP, TIFF, ICO
- ✅ Copy Output - One-click copy of results to clipboard
- ✅ Modern UI - Responsive design with smooth animations
- Python 3.10+
Windows (PowerShell):
irm https://astral.sh/uv/install.ps1 | iexmacOS/Linux:
curl -LsSf https://astral.sh/uv/install.sh | shRestart your terminal after installation.
git clone https://github.com/zpratikpathak/Base64-to-Image.git
cd Base64-to-ImageWindows:
start-server.batmacOS/Linux:
chmod +x start-server.sh
./start-server.shThe server will start at: http://127.0.0.1:8000
- Upload or drag-drop an image
- Click "Convert"
- Copy the Base64 string with the copy button
- Paste Base64 string in the text area
- Click "Convert"
- View or download the decoded image
- Press
Ctrl+Vto paste screenshots or copied images - Click "📋 Paste from Clipboard" button
- Upload a PDF file
- Click "Convert" - First page converts to image
- Copy the Base64 result
- Backend: Django 5.2.7 with Python 3.10+
- Image Processing: Pillow, PyMuPDF
- Frontend: HTML5, CSS3, Vanilla JavaScript
- Server: Waitress WSGI server
| Issue | Solution |
|---|---|
| UV not found | Install UV: curl -LsSf https://astral.sh/uv/install.sh | sh |
| Port 8000 in use | Kill process: lsof -i :8000 (macOS/Linux) or netstat -ano | findstr :8000 (Windows) |
| ModuleNotFoundError | Run start-server.bat or ./start-server.sh to reinstall dependencies |
| Drag & Drop not working | Hard refresh: Ctrl+Shift+R and clear cache |
| Virtual env issues | Delete .venv folder and re-run the startup script |
MIT License - feel free to use this project however you wish!
Found a bug? Have a feature idea? Contributions are welcome!
Pratik Pathak - @zpratikpathak
Made with ❤️ using Django and Python