How to merge PDF files without uploading them

Combine several PDFs into one on your own device with macOS Preview, qpdf, pdfunite or a browser tool that never uploads the files.

Updated 2026-12-01. Tool: Merge PDF

The short answer

Merging PDFs does not need a server. On a Mac, use Preview or Finder; on any system, qpdf --empty --pages a.pdf b.pdf -- merged.pdf or pdfunite a.pdf b.pdf merged.pdf; or use a browser tool that combines the files on your device.

Why keep the files local

Contracts, payslips, medical letters and scanned IDs are the kind of files people merge. Uploading them to a merge website means trusting its operator with the contents and with deleting them afterwards. Doing it locally removes the question.

On a Mac, iPhone or iPad

  • Preview: open the first PDF, show the sidebar with View > Thumbnails, and drag the other PDFs onto it where their pages should go. Save with File > Export as PDF to leave the original unchanged.
  • Finder: select the files, Control-click and choose Quick Actions > Create PDF. Check the page order in the result.
  • Files app: on recent versions of iOS and iPadOS, selecting several files offers Create PDF.

On Windows and Linux, the usual routes are a PDF editor, the command line or a browser tool.

On the command line

qpdf is in most Linux package managers and Homebrew, with builds for Windows:

qpdf --empty --pages cover.pdf report.pdf appendix.pdf -- merged.pdf

A page range after a file name takes only those pages: qpdf --empty --pages a.pdf 1-3 b.pdf -- out.pdf.

pdfunite comes with Poppler (the poppler-utils package on many Linux systems, poppler in Homebrew):

pdfunite cover.pdf report.pdf appendix.pdf merged.pdf

The last name is the output, and pdfunite overwrites it without asking, so a missing output name means your last input is replaced.

With Python and pypdf:

from pypdf import PdfWriter

writer = PdfWriter()
for name in ["cover.pdf", "report.pdf", "appendix.pdf"]:
    writer.append(name)
writer.write("merged.pdf")

Ghostscript also merges, with gs -dBATCH -dNOPAUSE -q -sDEVICE=pdfwrite -sOutputFile=merged.pdf a.pdf b.pdf, but it rewrites every page rather than copying it, which can change image quality and file size.

A shell pattern such as *.pdf expands in alphabetical order, so 10.pdf comes before 2.pdf. Number files with leading zeros or list them explicitly.

What to watch for

  • Bookmarks and links: tools differ in whether they keep each file's bookmarks (outline) and internal links. Check the result if you rely on them.
  • Form fields: two files with fields of the same name can end up linked or broken after merging. Fill in and flatten forms first if you can.
  • Password-protected files: a PDF that needs a password to open cannot be merged until it is unlocked. Remove the password in a PDF reader, or with qpdf's --decrypt option, using the password you were given.
  • Mixed page sizes: A4 and Letter pages, or landscape scans, keep their own size; merging does not resize them.
  • File size: the result is usually about the sum of the inputs, because fonts and images used in several files are generally stored once per file.

Do it in your browser

Merge PDF joins PDFs in the order you set with the arrows. It copies the pages as they are with the pdf-lib library, so text stays selectable and nothing is re-compressed. It shows each file's page count, reports a damaged or password-protected file by name, and takes files up to 50 MB each. It does not keep bookmarks or document properties, fillable fields may stop working, and it cannot reorder pages inside a file; extract the pages you want with Split PDF first. The files are never uploaded.

Frequently asked questions

How do I merge PDFs on a Mac without extra software?
Open the first PDF in Preview, show the thumbnails sidebar, drag the other PDFs onto it, then use File > Export as PDF. Finder’s Create PDF quick action also combines selected files.
Is it safe to merge PDFs online?
It depends on whether the site uploads the files. A tool that merges in the browser keeps them on your device; one that uploads them means trusting its operator to protect and delete them.
Does merging PDFs reduce quality?
Not with tools that copy pages as they are, such as qpdf, pdfunite, pypdf and the XUtil merger. Tools that rewrite or re-render pages, such as Ghostscript or printing to PDF, can change image quality and file size.
How do I merge only some pages of a PDF?
With qpdf, put a page range after each file name, as in qpdf --empty --pages a.pdf 1-3 b.pdf 5 -- out.pdf. In the browser, extract the pages with Split PDF first, then merge the parts.