Blog

How to Rename scan_0042.pdf Files Automatically

Updated October 11, 2026

You can rename scan_0042.pdf files automatically, but only a tool that reads the page can name them after what is inside. Pick one of three ways by the size of your pile, and use the name card below so every file ends up as date, vendor, what it is.

The useful name is inside the PDF, not in the filename

A scanner or phone app names a file scan_0042.pdf because it only knows the order it made it in. The date, the store and the thing you bought are printed on the page. Even Renamer.ai, a rename tool, describes the problem as a pile of files like Scan0043.pdf through Scan0847.pdf where the vendor, date and reference number are inside the PDF and not in the filename.

That is why a plain find-and-replace cannot fix it. You need the name written once, from the page, in a pattern that holds.

Use this name card: date, vendor, what it is

Copy this into a note and use it for every scan.

  1. Date: year, month, day, numbers only. 2026-03-14
  2. Vendor: lowercase, hyphens between words. hardware-store
  3. What: one word. receipt, invoice, lease, warranty
  4. Join with underscores: 2026-03-14_hardware-store_receipt.pdf
  5. Two on the same day: add a padded number at the end. 2026-03-14_hardware-store_receipt_01.pdf

Example: three names in this pattern.

BeforeAfter
scan_0042.pdf2026-03-14_hardware-store_receipt.pdf
scan_0043.pdf2026-01-02_dentist_invoice.pdf
scan_0044.pdf2025-11-20_landlord_lease.pdf

None of this is a Stash rule. It is the standard advice. Library and records guides say to write dates as YYYY-MM-DD, which sorts in time order, to start the name with the date when order matters, and to use only letters, numbers, hyphens and underscores. Pad any counting number with zeros, so 001, 003 and 021 sort in order and 1, 21 and 3 do not, as the Notre Dame digital projects guide says.

Two things to skip: spelled-out months and more than three parts. "March 14" sorts April ahead of March. Five-part names never get typed the same way twice.

Pick your way by the size of your pile

Your situationDo this
About 20 files or fewer, one-offsRename by hand with the card
Hundreds of old scans in a folderUse a rename tool that reads the text, on a copy
New scans, photos and emails keep arrivingUse a place that names things as they come in

If you are not sure, ask how often the pile refills. A one-time backlog is a tool job. A pile that refills every week is a habit problem, and no rename run fixes a habit.

Way 1: rename by hand when it is about 20 files

Open the PDF, find the date, who it is from and what it is, then type the name. Select the file and press Return on a Mac or F2 on Windows. Start with the ten newest and stop when you can find things by name alone.

Check the clock before you commit. Multiply seconds per file by the number of files.

Example: say 25 seconds a file and 300 files. That is 7,500 seconds, or 125 minutes. Over an hour means a tool or a drop-in place pays for itself. Use your own seconds per file.

Your computer's batch rename can add the prefix, but it cannot read

Both Mac and Windows can rename a whole folder at once. They only change text already in the filename.

Mac: select the files, Control-click one and choose Rename. Under Rename Finder Items, choose Replace Text, Add Text or Format. Add Text with the prefix you want, placed before the name.

Windows: install PowerToys and turn on PowerRename. Select the files, right-click, choose PowerRename, and type what to find and what to replace it with. It shows a preview before you finalize and can undo a rename afterward. It also supports regular expressions, for example to strip the scan_ part.

Example: you scanned 40 receipts on one March visit, scan_0001.pdf through scan_0040.pdf. Add the prefix 2026-03-14_hardware-store_ to all 40. Each file becomes 2026-03-14_hardware-store_scan_0001.pdf, which sorts in time order, and you only rename the few you need to tell apart.

The rule: use batch rename when every file in the folder shares one date or one source. If you would have to open each file to know what to call it, batch rename is not enough. A shared prefix on files from different dates looks tidy and is wrong, which is worse than an obvious mess.

Way 2: use a rename tool when hundreds of scans are waiting

A rename tool opens each PDF, reads the text, and builds the name from what it finds. For scans that means OCR, which is software reading the picture of the page. Renamer.ai says its batch rename scans each file's content and extracts the document type, key entities and dates, and that it works on scanned PDFs, including ones exported from phone scanning apps. That is the vendor's description. Check it on your own files before you trust it.

Run it this way:

  1. Copy the folder. Run the tool on the copy.
  2. Set the pattern to date, vendor, what, in that order.
  3. Open 10 percent of the renamed files, and at least 5, and compare each name to its page.
  4. If more than one in ten is wrong, rerun with a stricter pattern or fix by hand. If it is one in ten or better, apply to the rest.

Example: 300 renamed files means opening 30. Four wrong is fine, so fix those four. Seven wrong is not, so rerun.

Tools that only read metadata are weaker for this job. Software such as A-PDF Rename lists renaming from fields like Title, Author and Subject. A phone scan often has none of those filled in, so the field you are renaming from is empty.

Way 3: use a place that names files when they arrive

If scans, photos and forwarded emails keep coming, rename runs are a treadmill. You clear the folder, and in a month it is full again.

The other way is to stop making a folder of loose files. Drop things into one place that names and files them as they arrive. Stash works like that: you drop in the PDF or forward the email, it names and files itself, and there are no folders to set up and no tags to pick. Every account gets its own email address to forward things to, so a receipt that lands in your inbox goes straight in without being saved first.

The honest catch: we do not claim every name will be perfect. That is why finding by asking matters. You can type "the dentist invoice from January" and not depend on remembering what it was called or where it went. How to search your files by asking in plain words walks through it. If you want a home for the receipts and contracts once they are named, where to keep receipts, contracts and warranties covers it.

On cost: the free plan holds 100 things, no card. Pro is $90 a year, billed yearly, for 2,000 things, with bulk import of a whole folder when you want the backlog in one go. Export everything any time from Settings. If you stop paying, everything stays and stays searchable.

Five mistakes that cost you the most

MistakeWhat it costs
Renaming the originals with no copyA bad batch can overwrite good names, and undoing it takes longer than the job
Trusting every automatic nameOCR on a crooked phone scan can misread a date, which puts the file in the wrong spot in the list
Putting the vendor firstFiles from different years mix, and "the receipt from last March" gets hard to find
Spaces and odd charactersSome upload forms and sync apps reject or change them, so a name differs between your computer and a site
Switching separators halfwaySearching for part of a name finds half your files

Rename ten scans in the next ten minutes

  1. Copy your downloads folder or scans folder somewhere safe.
  2. Pick the ten newest scan_#### files in the copy.
  3. Open each one and rename it with the name card.
  4. Sort the folder by name. If the ten run in date order from top to bottom, the pattern works.

If it worked and you dread the other three hundred, that is the sign to pick Way 2 or Way 3.

Drop in one real scan and see if it files itself

Take one scan_0042.pdf from that folder and drop it into Stash. The free plan has no card and no setup, so the test costs you about a minute. Start free.

Frequently asked questions

Can I rename many PDFs at once without installing anything?
On a Mac, yes: select the files, Control-click, choose Rename, then Replace Text, Add Text or Format. On Windows you need PowerToys for PowerRename. Both only change text already in the filename, not what is printed inside the PDF.
Can a tool name a scanned PDF from what is written on it?
Some can. Renamer.ai says its tool reads each file's content with AI and OCR and pulls out the document type and dates, including from phone scans. Spot check 10 percent of the names, and at least 5, before you trust the rest.
What is a good file name for a receipt or invoice?
Use date, vendor, what it is, joined with underscores, like 2026-03-14_hardware-store_receipt.pdf. The date goes first as year-month-day so files sort in time order.
Is it safe to batch rename my original files?
Copy the folder first and run the rename on the copy. A wrong rule can rename hundreds of files at once, and fixing it means a second pass over all of them.
Why not put the vendor first in the name?
Files from different years then mix together, and finding last March's receipt gets harder. With the date first, the list reads as a timeline.
How do I stop scan_0042.pdf files from piling up again?
Stop collecting loose files in a folder. Drop scans and forwarded emails into one place that names and files them as they arrive, such as Stash, then find them later by asking in plain words.

Stash does the filing

Drop anything in and it gets read, named for what is actually inside it, and put where it belongs. Ask for it back in plain words. A hundred things free.

Start free