33

How do I remove some pages of a .pdf file? I tried some tips mentioned in different websites, but to no avail.

1
  • 3
    It would be helpful to mention what "tips" exactly you've tried so you don't get the same suggestions over again.
    – slhck
    Dec 11 '12 at 19:32
20

You can use command line tools pdftk and qpdf for this purpose. They are available on Windows and linux.

Use scoop to install them easily on Windows:

scoop install pdftk
scoop install qpdf

Here is the example of the code to keep only pages 1-9 and 26-end of the original file input.pdf and save them to outputfile.pdf.:

pdftk example: (taken from here)

pdftk input.pdf cat 1-9 26-end output outputfile.pdf

qpdf example:

qpdf input.pdf --pages . 1-9,26-z -- outputfile.pdf 
3
11

I've used PDF SAM (Split And Merge) ( http://www.pdfsam.org/ ) numerous times and it works well.

It's a free Java app, so you will need Java installed. It allows PDFs to be extracted to single pages and then reattached back again.

2
  • This works fine, I just wish they would add something like Adobe Acrobats "organize pages" were one could easily remove, add, rotate or reorder pages.
    – Foad
    Jan 8 '19 at 9:32
  • Visually selecting and then removing pages is now a premium-only feature :-(.
    – Sixtyfive
    Oct 15 '20 at 12:46
5

You can use any PDF editor, or if you don't want to download/install anything big, use the command-line portable pdftk (PDF Toolkit). Just extract the EXE and DLL to the same directory as your PDF, then from the command prompt use a command similar to the following:

pdftk in.pdf cat 1-12 14-end output out.pdf

This will delete page 13 from the PDF. See the man(ual) and examples pages for more help/options, or just type pdftk --help.

3
  • You can search for PDFTK portable version for a GUI version without installatoin.
    – Kenneth L
    Jan 3 '16 at 14:32
  • I wish there were a command to remove certain pages. that would be way more easier IMO.
    – Foad
    Jan 8 '19 at 9:32
  • For what's it worth, I found qpdf to work better than the java-based toolkits. Dunno why but I tend to work closer to the C/C++ software stack and oldschool UNIX philosophy. Your mileage may vary, obviously. :)
    – shevy
    Mar 29 '20 at 17:05
5

Another option is to use a PDF printer (e.g. CutePDF ( http://www.cutepdf.com/ ) )

"Print" your PDF to another PDF making sure to choose only the pages you want from the print dialog.

1
  • 2
    Many OS have a PDF printer installed by default.
    – adam.r
    Sep 22 '18 at 21:19
5

Sejda is a new "Advanced Online Manipulation Tool" that has the ability to split a PDF document at the page number that you wish. It also has numerous other abilities:

https://www.sejda.com/extract-pdf-pages

To remove pages, use the Extract task. Select all page but the ones you wish removed, and click "Extract".

You can select multiple pages at once pressing SHIFT

Extract PDF pages using sejda.com

1

Pdf printer drivers, as in Foxit, will convert your original pdf file, but may result in a different quality, or much larger file, when using high quality print.

Alternatively, it is recommended to simply cut off pages, from the original pdf file, without converting it.

This online tool does it very well: http://smallpdf.com/split-pdf

 1. Upload your file with drag and drop or press Choose file.
 2. Select the pages you want to save into a new file.
 3. Press the Split PDF button and download your file.

0
1

Another commercial option is using Ricoh's Print&Share:

There are several ways to "remove" pages. Easiest option:

  1. Print your pdf document or other document to Print&Share
  2. Go to the Print&Share pages overview by clicking that icon in the upper right corner: Ricoh Print&Share pages overview
  3. Deselect the pages that you don't want: Ricoh Print&Share deselect pages
  4. Click the Send and Close button. Ricoh Print&Share Send and Close

Now it is also possible to deselect pages based on conditions and automatically instead of doing it manually. This can be for example if the page contains too much color or too much white space or if it contains certain words, or specific page ranges, etc... The page selection options can be found here: Ricoh Print&Share advanced page selection

0

The free foxit reader comes with a pdf printer that allows you to print (ranges of) pages to a pdf file. And it's a great alternative to Adobe Reader.

0

Removing pages of a pdf

This uses the package pdftk . To Download the file you first pull it off the web.

cd ~
cd Downloads/
wget "https://www.pdflabs.com/tools/pdftk-the-pdf-toolkit/pdftk_free-2.02-win-setup.exe"

Then you install the package

./pdftk_free-2.02-win-setup.exe

To find where the executable file was saved, use the where command

where pdftk

To add the pdftk to your path, add it to ./bashrc and source it

echo 'alias pdftk="C:/Program\ Files\ \(x86\)/PDFtk/bin/pdftk.exe" ' >> ~/.bashrc
source ~/.bashrc

Now cd to the file of interest is

cd /d/Documents/BoxSync/Classes_Spring2021/Advanced_Biostatistics_EEB590C/Lectures/

The actual commands for removing pages are below. The format is "pdftk {input.pdf} cat 1-9 26-end output {outputfile.pdf}" In this example the input.pdf and outputfile.pdf are what you change and the numbers of the pages we are keeping are 1-9 and 26 until the end of the document.

#example
#pdftk input.pdf cat 1-9 26-end output outputfile.pdf

pdftk 10_Multivariate_Association_and_Canonical_Ordination_Methods.pdf cat 1-40 43-end output 10_Multivariate_Association_and_Canonical_Ordination_Methods_altered.pdf
1
  • 2
    This seems very complicated for a Windows system. In what ways is it superior to the answers already given? Mar 30 at 21:50

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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