Tell me more ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

There are a lot of software in Windows to merge PDF files but how can we do the same in Ubuntu?

share|improve this question

9 Answers

up vote 37 down vote accepted

PDF-Shuffler Install PDF-Shuffler

If you want a tool with a simple GUI, try pdfshuffler. It allows for merging of PDFs as well as rearranging and deleting pages. For batch processing and/or more complicated tasks, pdftk is of course more powerful.

Screenshot of PDF-Shuffler

share|improve this answer
I tried this - it didn't work on 10.04 – David Oneill Mar 13 '12 at 2:06
On 12.04, pdfshuffler always complains that there are "too many values to unpack", making it unusable. – despens Apr 12 at 12:15

pdftkInstall pdftk

To merge two pdf files, file1.pdf and file2.pdf:

pdftk file1.pdf file2.pdf cat output mergedfile.pdf

More info available here.

share|improve this answer
pdftk is buggy - bugs.launchpad.net/ubuntu/+source/pdftk/+bug/779908. gs might be slow, but does the work perfectly [IgnitE's answer] – Guanidene Apr 3 at 11:05

PDF Chain Install PDF Chain

A very nice solution is PDFChain. It's GUI is a frontend of PDFTK where you can merge, split or even add some background to your PDF files.

share|improve this answer

Ghostscript is a package (available by default in Ubuntu) that enables you to view or print PostScript and PDF files to other formats, or to convert those files to other formats.
To use Ghostscript to combine PDF files, type something like the following:

gs -dBATCH -dNOPAUSE -q -sDEVICE=pdfwrite -sOutputFile=finished.pdf file1.pdf file2.pdf

Here is a brief explanation of the command:

gs         starts the Ghostscript program.
-dBATCH    once Ghostscript processes the PDF files, it should exit.
           If you don't include this option, Ghostscript will just keep running.
-dNOPAUSE  forces Ghostscript to process each page without pausing for user interaction.
-q         stops Ghostscript from displaying messages while it works
-sDEVICE=pdfwrite 
           tells Ghostscript to use its built-in PDF writer to process the files.
-sOutputFile=finished.pdf
           tells Ghostscript to save the combined PDF file with the specified name.

Your input files don't even need to be PDF files. You can also use PostScript or EPS files, or any mixture of the three.

There is a lot you can do with Ghostscript. You can read it's documentation for more details.

Source

share|improve this answer
True, but it's incredibly slow. I just tried concatenating 45 x 400K, single-page PDFs. pdftk took 0m0.484s, gs took 1m32.898s (that's almost 200x slower) The file from gs was about 21% smaller though. – aidan Mar 22 at 6:47

Give PDF Mod a try

http://live.gnome.org/PdfMod

share|improve this answer

You can use pdftk to merge and modify PDF documents in general. Alternatively there's an online service to do just that: http://www.pdfmerge.com/

share|improve this answer

You can also use jPDFTweak, pdfsam or pdfjam.

(That said, I use pdftk.)

share|improve this answer

The best solution and the cheapest is the usage of some online tools. For me works http://go4convert.com/PdfProcess. The only thing that you have to prepare zip archive with the sorted files in, so the service can merge them in proper order.

share|improve this answer

Use pdfsam http://www.pdfsam.org/ it's very good for splitting and merging pdfs

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.