How to rename scanned documents by date on Mac
Any PDF renamed using the date found inside it, so scans sort correctly by name
Beginner · About 2 minutes
In this guide
What this does
Most scanners save files with a generic name like “Scan001.pdf” and a timestamp for when it was scanned, not the date on the actual document. This rule renames every incoming PDF using the date it finds inside the document’s own text, so a stack of scans sorts into the right order by filename alone, without you renaming a single one by hand.
What you’ll build
A rule that matches every PDF, then renames each one using the date found inside it.
Open the rule editor
This walkthrough happens inside FilesAutomator itself, so install it from the Mac App Store first if you have not already, then open it. In its toolbar, choose Add, then New Automation Rule.
Name the rule and choose a folder
Name it something like “Rename my scanned documents by date” and use Add Folder to choose your scanner’s output folder.
Build the condition
Add a single condition: Extension is pdf.

Add the action steps
Step 1: Rename
Choose Add Step, then Rename. In “New name, built from the parts below”, use Add Part, then Date,
then Full date: y-MM-dd. Change that chip’s source to Date found in the file’s text. Add Part
again, choose Text, and type an underscore. Add Part once more and choose Original name, so the
scanner’s own filename still follows the date rather than being lost.

Turn it on
Select Create Automation Rule, then switch the rule on. Every scan that lands here from now on gets a proper, sortable name automatically.
A faster way
The template gallery inside FilesAutomator already has this rule ready to install, named Rename scanned documents by date.
Related rules
Get FilesAutomator
Everything in this guide happens inside FilesAutomator itself. Download it free from the Mac App Store to follow along, or to install this exact rule from the template gallery in one click instead of building it by hand.
Download on the App Store