2

I've found and tried several of the solutions to extracting a page range from a PDF file (pdftk, Ghostscript, etc.). They all work, but they all seem to strip the tagging (PDF tags, used to make documents more accessible) from the resulting file.

Does anyone know of a solution, or a set of options I can use with an existing solution, to extract a page range AND retain the PDF tags in the extracted file?

1 Answer 1

0

To preserve original tags in the extracted pages range, please use an application that supports tag extraction. One open source and excellent application is PDFSAM.

  1. Install it by running the following command in the terminal:

sudo apt install pdfsam

  1. Open your file with PDFSAM and choose Extract. Then, specify pages range separated by commas, chose your output directory, and click Run like in the image bellow:

enter image description here

Done: Your extracted pages range with tags preserved will be located in the chosen output directory.

1
  • Thanks for this. I was actually looking for a command-line tool not a graphical one, apologies for not making that clear. I found a link via the pdfsam site to the sejda SDK which seemed to offer that, but unfortunately upon testing I discover that tags are not preserved when extracting pages using that tool.
    – Duncan
    Sep 8, 2019 at 19:09

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .