A lightweight desktop application for merging multiple PDF files with full control over page size, orientation, and output quality — all through a clean, user-friendly graphical interface. No command-line knowledge required.
- 📂 Folder-based file picker — select a folder and all PDFs inside are loaded automatically
- 🔀 Drag-and-drop reordering — drag files into your preferred merge order directly in the list
- ▲ ▼ Move buttons — fine-tune order with Move Up / Move Down controls
- 📐 Page size selection — choose from A3, A4, A5, Letter, Legal, Tabloid, or keep original sizes
- 🔄 Orientation control — set output to Portrait or Landscape
- 🗜️ Compression / quality options — three quality presets to control output file size:
- High Quality — no changes, preserves original quality
- Medium Quality — compresses streams and re-encodes images at 60% JPEG quality
- Low Quality — maximum compression, images re-encoded at 25% JPEG quality
- 📊 Live progress bar — visual feedback during merge and compression
- 📋 Output summary — success dialog shows page size, orientation, quality, and final file size
Python 3.8 or higher is required.
| Package | Purpose | Required |
|---|---|---|
pypdf |
Core PDF reading, writing, and merging | ✅ Yes |
Pillow |
Image re-encoding for Medium / Low quality compression | |
tkinter |
GUI framework (ships with Python standard library) | ✅ Yes (built-in) |
Note:
tkinteris included with most Python installations. On some Linux distributions you may need to install it separately:sudo apt-get install python3-tk
1. Clone the repository
git clone https://github.com/abiodun360/pdfusion.git
cd pdfusion2. Install required dependencies
pip install pypdf3. (Optional) Install Pillow for image compression support
pip install PillowWithout Pillow, Medium and Low quality modes still compress text and vector streams — only image re-encoding is skipped.
Run the application with:
python pdf_merger.py- Click 📂 Browse Folder and select the folder containing your PDF files
- All PDFs in the folder are loaded into the list automatically
- Reorder the files by dragging rows or using the ▲ / ▼ buttons
- Use ✕ Remove to exclude any files you don't want merged
- In the Output Settings panel:
- Choose a Page Size (or keep originals)
- Set Orientation — Portrait or Landscape
- Select a Quality preset
- Click 🔗 Merge PDFs, choose where to save, and you're done
pdfusion/
│
├── pdf_merger.py # Main application — run this file
└── README.md # Project documentation
| Option | Dimensions |
|---|---|
| Original (keep as-is) | Preserves each page's existing size |
| A5 | 148 × 210 mm |
| A4 | 210 × 297 mm |
| A3 | 297 × 420 mm |
| Letter | 8.5 × 11 in |
| Legal | 8.5 × 14 in |
| Tabloid | 11 × 17 in |
When a page size is selected, content is uniformly scaled and centred to fit — the aspect ratio is always preserved.
| Quality Preset | Content Streams | Image Re-encoding | Best For |
|---|---|---|---|
| High Quality | Unchanged | Unchanged | Archival, print-ready |
| Medium Quality | Compressed | JPEG 60% | General sharing / email |
| Low Quality | Compressed | JPEG 25% | Web upload, minimal size |
Image compression requires Pillow to be installed. Content stream compression works without it.
Contributions, bug reports, and feature suggestions are welcome! Feel free to open an issue or submit a pull request.
- Fork the repository
- Create a feature branch (
git checkout -b feature/your-feature) - Commit your changes (
git commit -m 'Add your feature') - Push to the branch (
git push origin feature/your-feature) - Open a Pull Request
This project is licensed under the MIT License — free to use, modify, and distribute.
Built with: