Forum moved here!

Home / Split / Merge PDFs using Sumatra

stuartfamily9

Hello! I am researching affordable, aka free pdf software for my coworkers that could really use a program that allows them to import and extract pages in a document.
Can anyone confirm that the free downloadable Sumatra PDF program would actually include this feature?

SumatraPeter

Sumatra PDF is a reader and is not designed to allow document editing. If there are no PDF restrictions imposed by the author then it will allow copying of text and images, but that’s about it.

GitHubRulesOK

Whilst there are ways to script the current page location to a backend editor application, a feature used with LaTeX editors that can add or remove PDF contents on the fly, that is unlikely to suite your intended usage.
SumatraPDF can be used in a commercial setting as a frontend to any enhanced virtual printer, which in turn can add or remove pages as required.

Several virtual printers are available, and I am not endorsing these two, simply offering their features page as possibly meeting some requirements

One is http://www.pdfill.com/freewriter.html

The other is https://www.win2pdf.com/features.html#merge-pdf-files
There is NO connection with the recommendation on that site to combine with SumatraPDF

GitHubRulesOK

Since split and merge is a highly popular topic.

Splitting pages only to image based files can be done most easily by using command line instructions to the Microsoft PDF printer, as discussed in other topics.
in short -print-to "Microsoft Print to PDF" -print-settings %p "%1"
but you will still need to provide a named output file or filename port, for automation you will find a programmable Print Driver as included in some of the above mentioned products is better.

Alternatively if non comercial users wish to extract just the current page we can combine with cpdf https://community.coherentpdf.com/ (other products are available) using SumatraPDF settings by adding to ExternalViewers
CommandLine = "path to\cpdf.exe" "%1" %p "%1-page-%p"

GitHubRulesOK

There are many Open Source applications that can
Split (Burst or Extract) Merge (Combine or Mix) and Rotate PDF pages

PDFSAM a simple portable GUI driven java app (from the same stable as the more extensive sejda* version) is one that has a Free Open Source basic version that can easily be called from SumatraPDF. There are limitations to this simplicity, since without adding a more complex page handling mechanism, we are initially constrained to only passing one filename. Expanding to include multiple files in preset workspaces is possible but goes well beyond the scope of this post.

Get the “Official Latest” (currently 4.1.4) Portable archive.zip from

For this example we will unzip to say D:\port apps\pdfsam-4.1.4-windows\, so in that folder we should see pdfsam.exe

It is worth running that once to choose your prefered choices for updates, news, donations, premium and other setting preferences.

Clearly SumatraPDF passing only one file to be merged/combined will require others to be selected later within PDFSAM, thus it will not offer to merge on the opening screen !

However for Extract, Rotate or Spliting in 3 modes this is less of a limitation, and the following external viewers entry,

ExternalViewers [
	[
		CommandLine = "D:\port apps\pdfsam-4.1.4-windows\PDFsam.exe" "%1"
		Name = PDFSAM &1 to extract, split or rotate
		Filter = *.pdf
	]
]

allows for ALT F 1 +see footnote (or file > open with) to initiate the start up screen for the 1 current file
image

For Merging you will need to dismiss that screen and use the Merge option in the dashboard to find and select the current file along with other(s).
We could work around the limitation by adding a dummy pdf (e.g. cover.pdf)
then delete or use the entry (note the dummy file must exist)
so adding to the above,

ExternalViewers [
	[
		CommandLine = "D:\port apps\pdfsam-4.1.4-windows\PDFsam.exe" "%1"
		Name = PDFSAM &1 to extract, split or rotate
		Filter = *.pdf
	]
	[
		CommandLine = "D:\port apps\pdfsam-4.1.4-windows\PDFsam.exe" "F:\Data\Samples\cover.pdf" "%1"
		Name = PDFSAM &2 to mix, extract, merge, or rotate
		Filter = *.pdf
	]
]

allows for ALT F2 +see footnote (or file > open with) to initiate the start up screen for the 1 current file
image

If you dont want that cover simply discard it, and add the extra entries as required.

There are many nice features in PDFSAM for merging such as add a contents page and merge bookmarks etc. but I will let you find those for yourself

+ footnotes

  • Sejda has has many more features and my first all round goto option however it is capped for free daily usage. There are Portable and online choices too. (Please, simply avoid using PDF compressor options)
  • Using &1 or &2 when files are listed in history (using same numeric shortcuts) will require you to hit enter. You could replace with other keys such as &- &= so that enter is not required as shown here

image

denis52

Wow. looks too complicated. I need just to merge a few pdf pages together. Is there a simpler way?

GitHubRulesOK

Use Adobes free online merge my pdf service its the best :slight_smile:
Merge PDFs online for free | Adobe Acrobat (United States)

RGarudan

Yes, there are a lot of free software programs that suits your needs.

PDFsam Basic

PDFill PDF Tools
https://www.pdfill.com/pdf_tools_free.html
PDFedit
https://sourceforge.net/projects/pdfedit/

Popo_Lino

For such needs, Sumatra is not the best choice. It is a pdf reader and as I know it can not be used for splitting or editing the pdf files. I personally never used it for such needs. There are a lot of online pdf editors where you can merge or split the pdf pages. For example, I use [url=commercial site removed] you need just to import the pdf file and you can edit it as you want.