Skip to content
Apps by Flavio

Rename files from a CSV spreadsheet

By Flavio

Rename a batch of Mac files using a two-column CSV spreadsheet. Use Finder for shared patterns, or preview every old-to-new filename pair and save renamed copies.

You have a folder of files named Scan 1.pdf through Scan 6.pdf, and a spreadsheet that gives each file its real name. When every file follows the same rule, Finder can rename the batch in a few clicks. When each file needs its own name from a spreadsheet, CSV File Renamer previews every old-to-new pair, catches missing files and duplicate names, and saves renamed copies in a new folder.

How do I rename a batch of files in Finder?

Select the files you want to rename in a Finder window, then choose File › Rename… from the menu bar (or right-click the selection and pick Rename…). Finder opens a sheet with three modes: Replace Text, Add Text, and Format.

  • Replace Text swaps one piece of text for another in every selected filename, such as changing Scan to Juniper Archive.
  • Add Text puts the same prefix or suffix before or after each name.
  • Format replaces the name with a shared base name and a counter or date, such as Juniper Archive 001.pdf, Juniper Archive 002.pdf.

Finder showing the Harbor West folder with Scan 1.pdf through Scan 6.pdf selected and the Rename Finder Items sheet open to Replace Text

Look at the example line at the bottom of the sheet before you click Rename, because Finder changes the originals right away. If you notice a mistake right after, press Command–Z to undo the batch. Apple’s guide to renaming files in Finder.

Finder stops helping when each file needs a distinct name that already sits in a spreadsheet, like matching camera numbers to student names, product SKUs, or catalog titles. For that you either rename one file at a time or feed the spreadsheet straight into a tool built for CSV mappings.

How should I format the CSV spreadsheet?

Keep two columns in Numbers, Excel, or Google Sheets: the current filename in the first column and the new filename in the second. Include the file extension in both columns (Scan 1.pdf, not Scan 1), and export the sheet as a comma-separated UTF-8 CSV.

Existing filename,New filename
Scan 1.pdf,Juniper Archive - 001.pdf
Scan 2.pdf,Juniper Archive - 002.pdf
Scan 3.pdf,Juniper Archive - 003.pdf
Scan 4.pdf,Juniper Archive - 004.pdf
Scan 5.pdf,Juniper Archive - 005.pdf
Scan 6.pdf,Juniper Archive - 006.pdf

If a filename contains a comma, wrap that whole filename in double quotes so the comma stays inside the column. Remove extra columns like notes or totals before exporting, because every row needs two columns.

How do I preview and rename from a CSV?

Open CSV File Renamer and click Choose… under Files to rename to pick the folder that holds your files at its top level. Click Import… under Filename mapping CSV to load the CSV file, or paste the CSV lines into the box.

Turn on First row contains column names if your spreadsheet has a header row. If your spreadsheet puts the new names in the first column instead of the second, turn on Read new filenames from the first column. Pick a Save in location outside the source folder, enter a New output folder name, and click Preview.

CSV File Renamer preview mapping Scan 1.pdf through Scan 6.pdf in Harbor West to Juniper Archive - 001.pdf through 006.pdf, each with a green Rename copy pill

Every matched row appears with an arrow to its new name and a green Rename copy pill. If a row names a file that is not in the folder, repeats the same source file twice, gives two rows the same new name, or contains a / character, that row moves to the top with a red pill and Create Renamed Copies stays off until you fix the CSV and preview again.

Situation in the batchFinder RenameCSV File Renamer
Same prefix or counter across 6 filesFormat renames all 6 in placeMaps each row from the CSV
Different name per file from a spreadsheetOne file at a time by handImports all rows and previews them at once
Typo or missing file in your listFound by hand while scanning the folderFlagged in red before copying starts
Two rows asking for the same new nameStops when Finder hits the duplicateBlocked in preview before any copy runs
Original files after runningRenamed in placeLeft untouched; renamed copies go in a new folder
Preview a CSV filename mapping before copyingLoad the source folder and two-column CSV, check every row for missing files or duplicate names, fix any red rows, and then write renamed copies and Rename map.csv to a new folder.NoYesFolder + two-columnCSVEvery row valid inPreview?Fix missing orduplicate rows inCSVCreate renamedcopies + Renamemap.csv

What goes into the new folder?

Click Create Renamed Copies once every row is green. The app creates the new folder, writes each renamed copy without touching its contents, and saves Rename map.csv next to them so you have a permanent record of which original became which new file.

CSV File Renamer done screen showing 6 renamed copies are ready with Copied pills, Rename map.csv, and a Show in Finder button

Click Show in Finder to inspect the output folder before sending it out. Your original files stay in the source folder under their old names, so throwing away a batch is as easy as deleting the output folder. The app costs $19 plus tax where it applies, paid once.

Get CSV File Renamer

Use a spreadsheet to map existing filenames to new names. Check missing files and collisions, then make renamed copies with a CSV map back to the originals.

Available for Mac and Windows — both included in one purchase.

See CSV File Renamer → · Mac docs · Windows guide · $19 ($99 Office & Team). See the app page for tax details.

All files and folders apps → · More files and folders tutorials → · All app tutorials →