I'm often printing several versions of a document (e.g. a paper in progress). To keep track of the printouts I would like to print the date and time of printing onto each page, regardless of which application I'm using (although it would be okay if it works for PDF files only, if it happens automatically). I have seen Windows printer drivers including this feature, but haven't found any settings here (e.g., Canon iR3225) nor any hidden-CUPS-feature-I-could-activate-in-the-config-file.

Any ideas? Some sort of preprocessing I could inject into cups?

(I'm using Mac OS X 10.6.7)

2 Answers 2


I finally found a usable solution using convert from ImageMagick, the PDF services mentioned by nathang and Automator.

  1. Start Automator, create a new "Print Plugin"
  2. Drag the "run shell script" action to the right and enter the following script:

    export PATH=/opt/local/bin:/usr/local/bin:$PATH
    convert -size 400x50 xc:white -font Arial -pointsize 24 -gravity center -draw "fill grey50 text 0,0 '`/bin/date`'" /tmp/stamp.png
  3. Add the "Watermark PDF Documents" action and add the file "/tmp/stamp.png" using the 'add...' button. (You probably have to create this file first, e.g. using touch /tmp/stamp.png in a Terminal). Then adjust the offset, scale and opacity as you like. I'm using x=480 y=820 scale=0.25 opacity=0.7.
  4. Add the "Open Images in Preview" action.
  5. Save the Automator script.

Now you should find a new action in the "PDF" drop-down menu of your printing dialog, which stamps the current date and time on each page and shows the result in Preview, from where you can print the document.

  • Your link is a 404. If you still have the script, can you re-upload it?
    – grg
    Commented Oct 7, 2015 at 11:26
  • @grgarside Sorry I don't have the file any longer as I reinstalled my mac several times since then. But you can create it yourself using the description above.
    – sqx
    Commented Oct 8, 2015 at 12:19

Perhaps use a PDF modification tool like Pdftk to add a watermark that contains the desired metadata.

  • I know about pdftk, and probably it's possible using it to write some script adding my timestamp to each page. But this does not solve the integration problem into the printing system -- the solution is sort of unusable if I have to go to the console pre-processing every PDF file I want to print.
    – sqx
    Commented Jun 7, 2011 at 11:19
  • How about integrating this with AppleScript? Commented Jun 7, 2011 at 17:30
  • Integrating into the system is the easy part, thanks to PDF services Commented Jul 8, 2011 at 2:56

You must log in to answer this question.

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