Back to Skills

pdftk-server

Skill for using the command-line tool pdftk (PDFtk Server) for working with PDF files. Use when asked to merge PDFs, split PDFs, rotate pages, encrypt or decrypt PDFs, fill PDF forms, apply watermarks, stamp overlays, extract metadata, burst documents into pages, repair corrupted PDFs, attach or extract files, or perform any PDF manipulation from the command line.

30,445stars3,629forksUpdated 4/20/2026

Security Assessment

Medium Risk(60/100)

Detected risks:

Privilege Escalation([SKILL.md] sudo, [references/download.md] sudo)
Security Score60/100

About pdftk-server

The pdftk-server skill provides an efficient and flexible way to manipulate PDF documents using the command-line tool PDFtk Server. This skill simplifies complex tasks like merging multiple PDFs, rotating pages, applying watermarks, filling PDF forms, and more, making it a powerful tool for anyone needing to work with PDF files programmatically. Whether you need to extract metadata, repair corrupted PDFs, or even decrypt and encrypt PDF documents, this skill automates these tasks from the command line, saving time and reducing manual intervention. With its wide range of capabilities, pdftk-server addresses common issues that many users face when managing large volumes of PDF documents or when performing batch processing tasks on PDFs.

The main features of this skill include merging, splitting, and rotating PDF pages, adding background watermarks and overlay stamps, encrypting and decrypting PDFs, and filling forms from external data sources. It also offers the ability to extract PDF metadata and bookmarks, repair broken PDFs, and even compress or decompress PDF files. Users can also split a document into individual pages or collate separate even and odd pages. PDFtk Server supports a broad array of tasks, such as generating PDF outputs with user-defined changes, making it an essential tool for document manipulation in server environments.

This skill is ideal for users who need to automate or script PDF document manipulations without relying on graphical software. It's particularly useful for developers, IT professionals, and anyone handling PDF batch processing. Users working with large datasets or creating automated workflows involving PDF documents will find this skill indispensable, especially in situations where manual PDF editing is impractical or time-consuming. Its robust functionality ensures that users can maintain control over their PDF processes with ease and precision.

FAQ

How do I merge multiple PDF files?

Use the command `pdftk file1.pdf file2.pdf cat output merged.pdf` to merge files.

Can I split a PDF into individual pages?

Yes, use the command `pdftk input.pdf burst` to split the document into separate pages.

What if I encounter a corrupted PDF file?

You can attempt to repair a corrupted PDF using the command `pdftk broken.pdf output fixed.pdf`.

Is PDFtk Server compatible with all operating systems?

PDFtk Server is compatible with Windows, macOS, and Linux (Debian/Ubuntu, Red Hat/Fedora).

Can I apply both a watermark and a stamp to a PDF?

Yes, you can use both the `background` and `stamp` options to apply these elements to the PDF.

All Files

6 files
references/third-party-materials.md9.0 KB
View
references/pdftk-server-license.md1.5 KB
View
references/pdftk-man-page.md6.9 KB
View
SKILL.md4.6 KB
View
references/pdftk-cli-examples.md3.3 KB
View
references/download.md3.2 KB
View

Install pdftk-server

Download and extract the skill files to your .claude/skills/ directory.

Quick Setup:

  1. Copy the skill folder to .claude/skills/
  2. Claude will automatically detect and use the skill