At some point in time, a lot of us might have come across a situation where we find the need to rename multiple files at once. Be it images, videos, apps, or even PDFs, renaming every single file individually is a pretty daunting task. Luckily, macOS offers two different options that allow you to rename multiple files at once. So, let’s dive in and look at these methods.
Method I. Rename Multiple Files using Finder
With OS X Yosemite, Apple introduced a new built-in tool in Finder, which allows you to rename multiple files at once. Here’s how.
i. Launch the Finder app and locate the files that you want to rename.
ii. Hit shift + click or command + a to select all files.
iii. Next, open the actions menu. You can do this using control + click, a two-finger tap on the trackpad, or clicking the actions button with a gear icon on the top menu.
iv. Select Rename [X] Items… from the list.
v. Now, in the Rename Finder Items box, you will be greeted with three different options: ‘Replace Text’, ‘Add Text’, and ‘Format’, each serving a different purpose.
So let’s see when and how to use these options.
Option 1: Rename Finder Items with Replace Text
The ‘Replace Text’ option comes in handy when you want to find and replace a portion of the existing file name. For instance, if you have multiple images that contain some random gibberish like ‘DSC’ in the name, you can find and replace them with the name you want you using this option.
i. Select ‘Replace Text’ in the Rename Finder Items box.
ii. Now, enter the part of the name that you want to ‘find and replace with another text’, and enter it in the input box next to Find.
iii. Similarly, in the box beside ‘Replace with’, enter the ‘name/text that you want to replace the existing name with’, and hit Rename.
Option 2: Rename Finder Items with Add Text
With the ‘Add Text’ option, you can add text to the existing file name as a prefix or suffix.
i. Select ‘Add Text’ in the Rename Finder Items box.
ii. In the input box beside the ‘Add Text’ dropdown box, enter the text you want to add to the existing file name.
iii. Now, next to the input field, select either after name or before name from the dropdown box to add your text as a suffix or prefix, respectively. And then, hit Rename.
Option 3: Rename Finder Items with a Format
If you have a specific preference for renaming files or want more control with naming, you can choose the ‘Format’ option.
i. Select ‘Format’ in the Rename Finder Items box.
ii. Click on the dropdown menu next to the ‘Name Format’ option, and select amongst Name and Index, Name and Counter, and Name and Date options.
iii. Now, in the input box beside ‘Custom Format’, enter the name, and in the input box beside Start numbers at, enter the number that you want the files to have.
iv. Additionally, choose between the after name and before name options next to Where, to add name or number before or after.
v. Once done, hit Rename.
Method II. Rename Multiple Files using Automator
1. Open the Automator app by opening the Launchpad and going into the Others folder, or by hitting the command + space combination to open Spotlight Search and then searching for Automator.
2. Click on New Document.
3. Now, from the Choose a type for your document box, select Workflow.
4. Next, make sure that the Actions tab is highlighted, and click on the Files & Folders option under Library in the left pane.
5. Now, find the Get Selected Finder Items option from the list and drag it to the right pane. You can also search for it in the search bar located next to Variables.
6. Similar to the previous step, find the Rename Finder Items option from the list and drag it below the previous item.
7. Next, on the pop-up menu that appears, click on Don’t Add. You can also opt for Add to create copies of the renamed files if you want.
8. Now, in the Rename Finder Items, tap on the dropdown menu and select Make Sequential.
9. Next, for the Add number to option, select new name and enter the name that you want to give your files in the input field.
10. From the Place number dropdown menu, select after name or before name accordingly, and in the input field next to Start numbers at, enter the number that you want the name to contain.
11. Further, you can also perform additional formatting by changing the separator from the dropdown menu next to the separated by option and choosing from a dash, period, space, underscore, or nothing in for your file name.
12. Finally, save the workflow by pressing command + s and give the workflow a name that you can remember. For future references, let’s call the workflow, Rename Multiple Files.
Now, with the workflow ready, all you need to do is select the files you want to change the name of, and then, trigger a right-click by either: control + click, or double finger tap on the trackpad. Once done, select Services from the list of options and click on the name of the workflow to execute it.
Further, in case you are feeling lazy and don’t want to go around selecting images and clicking through different options, you can create a custom shortcut for your workflow, using which, you can execute the workflow by simply pressing a key combination.
Assigning a Keyboard Shortcut for the Workflow
1. Open System Preferences and select Keyboard.
2. On the next screen, choose Shortcuts from the top menu.
3. In the left pane, tap on Services, and from the list that pops-up on the right pane, select the service that you just created.
4. Next, tap on the service and click on the Add Shortcut option.
5. Enter a key combination that you want to assign for the workflow.
To execute the workflow, select the files that you want to rename and press the key combination. Once done, the workflow will run itself and rename all the selected files for you.
And that’s it!
You should have now renamed all your selected files in one go. However, a thing to remember with this method is that it is ideal for situations when you want a specific name format for all your files, and for instances when you want a different name, you can either opt for the first method or make changes to the existing workflow, and you’re all set.