Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I have one standard file (call it ending.pdf) that I want added to the end of all of the PDFs in a folder. Can I automate this task? I have Acrobat Pro X. Thanks in advance for any suggestions.

Oh, I forgot to mention I'm using Windows 7.

share|improve this question
Which operating system are you using? –  Flimzy Jun 5 '13 at 20:55
What OS are you using? If it's something unixy, you can use imagemagick, namely the convert command. –  SBI Jun 5 '13 at 20:56
@SBI imagemagick "runs on Linux, Windows, Mac Os X, iOS, Android OS, and others." –  terdon Jun 5 '13 at 21:00
I know, but depending on what you run, installing and using it is straight forward...or not ;) –  SBI Jun 5 '13 at 21:00
Assuming Windows as platform, you could use the PDF Toolkit PDFtk: pdflabs.com/tools/pdftk-the-pdf-toolkit Just loop through your existing files using a CMD command file using a "for /F" construct. Take special care for encrypted/protected/compressed files. –  Axel Kemper Jun 5 '13 at 21:58
show 1 more comment

1 Answer

up vote 2 down vote accepted
  1. Download and install PDFtk.

  2. Copy Ending.pdf to one directory (say C:\End) and all the other PDFs to another directory.

  3. At the command prompt type pdftk and press Enter. If you receive an error like 'pdftk' is not recognized as an internal or external command, operable program or batch file, you'll need to add the PDFtk installation directory to your PATH or specify the full path to pdftk.exe in the command below.

    Alternatively, since the app is pretty much portable and I don't see any registry keys or miscellaneous files being created/littered about the system, you can simply copy pdftk.exe from the installation directory to the directory where your PDFs reside.

  4. At the command prompt run the following command in the directory with the PDFs you want to append Ending.pdf to:

    for %a in (*.pdf) do pdftk "%~a" "C:\End\Ending.pdf" cat output "%~na (Joined)%~xa"
share|improve this answer
Hey Karan, thank you so much! This works great. I just have one follow-up question. How can I make them have the same file name as the original, rather than with (Joined) at the end? I tried just removing that bit in the code, but it gives an error that the input file name matches the output file name. Perhaps having them deposited into a subfolder or something? –  Josh Jun 6 '13 at 18:08
Yeah, you can try something like ... cat output "C:\MyPDFs\%~a" and you should hopefully end up with new files but with their original names in C:\MyPDFs. –  Karan Jun 6 '13 at 18:30
Woo hoo! That worked perfectly. Thank you once again. Answer accepted. –  Josh Jun 6 '13 at 18:57
add comment

Your Answer


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.