64.23 PDF Watermarks

20200429 To add a watermark to a PDF file we can use pdftk with it’s background, stamp, and multistamp operations.

The process begins by creating a single page (for example, using libreoffice) containing the watermark. The watermark might simply be some grey text at the top and bottom of the page. The page margins may need to be adjusted to get the text exactly where you want it to appear. Export the document as pdf, perhaps calling it watermark.pdf.

Suppose the document you want to watermark is called survivor.pdf. To add the watermark as an underlay to each page of the pdf document:

$ pdftk survivor.pdf background watermark.pdf output survivor_watermarked.pdf

The stamp operation places the watermark on top of each page, thus possibly occluding parts of the original page.



Your donation will support ongoing availability and give you access to the PDF version of the book. Desktop Survival Guides include Data Science, GNU/Linux, and MLHub. Books available on Amazon include Data Mining with Rattle and Essentials of Data Science. Popular open source software includes rattle, wajig, and mlhub. Hosted by Togaware, a pioneer of free and open source software since 1984. Copyright © 1995-2021 Graham.Williams@togaware.com Creative Commons Attribution-ShareAlike 4.0.