🔗 Live Demo: https://seehiong.github.io/pdf-merge/
A sleek, secure, and entirely client-side PDF merging and page organization utility. Combine multiple PDF files, insert images, rotate pages, reorder layouts, and stamp page numbers directly in your browser without any server-side processing.
- Premium UI: Modern dark-mode/light-mode interface with responsive glassmorphism, clean transitions, and animations.
- Security First: Merging happens entirely in your local browser sandbox. Your files are never uploaded to any remote server.
- Interactive Page Organizer: Switch from File Manager to the organizer grid to view page-by-page thumbnails of your documents.
- Individual Page Controls:
- Drag-and-drop to reorder individual pages.
- Delete specific pages from the merge sequence.
- Rotate pages in increments of 90° (both clockwise and counter-clockwise).
- Import Images: Seamlessly combine PNG, JPEG, and JPG images along with your PDFs into a single, merged PDF file.
- Page Number Stamping: Automatically stamp page numbers with customizable formatting ("Page X", "Page X of Y"), positions (header/footer, left/center/right), sizes, and colors.
- Password-Protected PDFs: Detects encrypted PDFs and prompts with a secure, glassmorphic modal to unlock them client-side.
- HTML5 & Vanilla CSS: Dynamic grid layout, responsive design, custom variables, and transition animations.
- Native JavaScript (ES6): Tab switching, state synchronization, sequential file loading, and color syncing.
- pdf-lib: Client-side PDF copy/paste page streams, page-number drawing, rotation, and compiler.
- pdf.js: Mozilla's rendering engine for generating high-fidelity page preview thumbnails inside
<canvas>tags.
- Open
index.htmlin any modern web browser, or host it on GitHub Pages. - Drag and drop your PDFs and images into the upload area.
- If any PDF is password-protected, enter the passcode when prompted to unlock it.
- File Manager Tab: Reorder the input documents as a whole or remove them.
- Page Organizer Tab: Hover over page cards to rotate, delete, or drag them to fine-tune the final layout.
- Page Numbers Settings: Toggle page numbers, select formatting, colors, position, and sizing.
- Click Merge & Download to download the combined document instantly.
This project is open-source and available for use under the MIT License.