Encrypt PDFs Service

As anyone who involved in the business of business can tell you: PDF files are the life blood of business communications and data retention. That is why the built-in PDF actions in the Automator library are so important. They can be used to create desktop tools for quickly combining, annotating, encrypting, and even watermarking PDF files in the Finder. This is business efficiency in practice.

This webpage details how to create and install an Automator workflow service for encrypting PDF files selected in the Finder. Enjoy!

The Service Workflow

DO THIS ►Launch Automator and create a new service workflow. Leaving the document unsaved, replicate the workflow described in detail below.

DO THIS ►After setting the service input data parameters  1  , add each of the Automator actions listed in callouts  2  through  5 , adjusting the action parameters mentioned in the red callouts  1  through  7  .

 1  Data Input Bar  (⬇ see below )  • The first step in creating any Automator service is to set the parameters of the data input bar at the top of the workflow document window. Set the input data type by selecting “PDF files” from the input types popup menu  1 , and then select the Finder application from the target application  2  popup menu.

 2  Encrypt PDF Documents • This action, from the PDF category of actions in the Automator library, is designed to create an encrypted duplicate, of each PDF file passed to it.

The interface of this action contains the password entry and confirmation input fields, that you will want to be displayed when the service is executed. To make the action view visible during run, click the actions Options button  3  and then select the checkbox for indicating to show the action when the workflow is run  4 

An Automator workflow for encrypting PDF files selected in the Finder.

 3  Rename Finder Items  (⬆ see above )  • By default, the Encrypt PDF Documents action creates an encrypted duplicate, of a source PDF file, named the original name of the source file with the text “ (Encrypted)” appended to the original name. If you would rather use another (or no) name appendage, add the Rename Finder Items action to the workflow, and set the renaming method of the popup menu to Replace Text  5  and then fill-in the Find and Replace fields  6  with the required text strings. NOTE: if you want to replace the auto-appended string, be sure to allow for the leading space in “ (Encrypted)”

 4  Move Finder Items • By default, the Encrypt PDF Documents action creates the encrypted duplicate PDF file in the user’s Temporary Items folder, which by design is hidden. The Move Finder Items action will enable you to indicate the destination directory to contain the encrypted duplicate PDFs. Select Other… from the destination directory popup menu  7  and then (create) select the folder to contain the encrypted files  (⬇ see below ) 


NOTE: select the checkbox titled “Replace exiting files”  7   if you want the watermarking process not to replace existing PDF files whose name matches one of the created PDFs. Be aware however, that without the option selected, the workflow will error if there is a naming conflict.

 5  Reveal Finder Items • As a convenience for confirming the process completed correctly, add this action to the workflow and it will display the encrypted files in the Finder.

Save the Service

To save and install the service, select Save from the Automator File menu and enter the name for the service in the forthcoming sheet.  (⬇ see below ) 

save sheet

NOTE: The name you assign for the workflow file will be the menu title that appears in the Services and contextual menus.

Using the Service

With the service created and installed, you are now ready to try it out. We’ve provided some example files for this purpose.

DO THIS ►DOWNLOAD some example PDF files to use when testing or demonstrating this workflow service.


DO THIS ►Select one or more PDF files, and choose the service from either the Finder action menu or contextual menu.  (⬆ see above ) 

DO THIS ►In the password dialog, enter the password to be used to encrypt the selected PDF files, and then click the Continue button:  (⬇ see below ) 


DO THIS ►Encrypted duplicates of the original PDF files will be created and displayed  (⬇ see below )