Folder Actions in macOS Explained with Practical Examples

This guide will explain what Folder Actions for macOS are, how to set them up, and provide help for you to create your own Folder Actions.

What are Folder Actions for macOS?

In a nutshell, Folder Actions are scripts that can be attached to folders. They enable events to take place when items are added or removed from that folder, or when the folder is opened, closed or moved. A number of Folder Actions are included with macOS, but more importantly – you can build your own and even download Folder Actions created by others in the Apple community. Once you start using them you quickly realize how helpful and time-saving they can be.

Examples of Folder Actions

  • When you put images in a certain folder, they’re automatically converted to JPG or PNG
  • When you put files in a certain folder, they’re automatically uploaded to a web server
  • When you close a Finder window, all the sub-folder windows close as well
  • You’re notified when new files are placed in a certain folder
  • When an image is placed in a folder macOS automatically sets that image as your Desktop wallpaper
  • When new files are placed in a certain folder (like your Desktop or Download folder) they’re moved based on file type

How to enable and use Folder Actions

  1. For this example we’ll set up a Folder Action that automatically converts images to JPG format just by dropping them into a folder (this particular Folder Action is included with macOS). Start by creating a new folder. Now right-click (ctrl-click) on that new folder and select Folder Action Setup…
  2. Finder right-click context menu with an arrow pointing at Folder Actions Setup

  3. When prompted, click the Run Service button.

    a macOS dialogue box with an arrow pointing to the Run Service button

  4. Now choose a script to attach to your folder. For this example we’ll go with Image – Duplicate as JPEG.scpt. Once you’ve selected it, click the Attach button.
  5. the Folder Actions Setup macOS window

  6. Make sure there’s a check in the box labelled Enable Folder Actions and then exit out of the Folder Actions Setup panel.
  7. Enable Folder Actions in macOS

  8. That’s it. Now drag a non-jpg picture into that folder (a PNG, GIF etc).
  9. If you’re using macOS Catalina (10.15) or higher, you’ll be presented with a couple of access permission requests. Click OK on each of them.

    a macOS additional Permission request

  10. Ta-da! The Folder Action will have duplicated your image, but this time as a JPG. It will also save the original image.
  11. a Finder window with an arrow pointing at a JPG file

  12. If you ever want to change or disable a Folder Action, right-click (ctrl-click) the folder and select Folder Actions Setup… again and either remove the check-mark next to the Folder Action you wish to disable or select the Folder Action and click the Edit Script button.

Additional Folder Action Resources

If this article helped you, I'd be grateful if you could share it on your preferred social network - it helps me a lot. If you're feeling particularly generous, you could buy me a coffee and I'd be super grateful :)

buy a coffee for

Home » Mac » Folder Actions in macOS Explained with Practical Examples