How to Batch Rename Files in Windows 10

Do you have a bunch of file titles that you need to edit or rename? If so, a third-party program isn’t essential to rename a batch of files. In fact, you can batch rename multiple files with both File Explorer and Powershell. Even Command Prompt has some handy commands for editing multiple file extensions. This is how you can batch rename a group of files with File Explorer and PowerShell.

Batch Rename Files in File Explorer

File Explorer includes a Rename option on its Home tab. Thus, you can rename one, or more, files by selecting that option. Alternatively, you can select Rename from a file’s context menu.

First, press the File Explorer button, which is on the Windows 10 taskbar. Browse to the folder that includes a group of files you need to rename. Hold the Ctrl key and select all the file titles to rename with the cursor as in the snapshot below. Alternatively, press the Ctrl + A hotkey to select all the files within the open folder.

Now press the Rename button on the Home tab. Alternatively, press the F2 key. Then you can enter a new title for the selected files. That will rename all the selected file titles when you press Enter. As File Explorer can’t have duplicate file titles within the same folder, each renamed file will include a number as shown in the snapshot below.

Rename Files With ContextReplace

You can also rename multiple files via File Explorer’s context menu with the ContextReplace software. This is a freeware program that adds a Replace option to the context menu. Then you can right-click a folder and select the Replace option to rename a batch of files with matching titles within the directory.

To add ContextReplace to Windows, open this Softpedia page and press Download. Click the ContextReplace.exe to install the program. Then click Replace.exe in the program’s folder to run the software.

Next, open File Explorer and right-click a folder that includes the files you need to rename. Select the Replace option on the context menu. That will open the window shown directly below.

Select the Replace in file names option on that window, and deselect all the other check box settings. Then enter the file title you need to change, but don’t include its extension. Input the new file title in the right text box, and press the Replace button. That will rename all files in the folder that match the title entered in the left text box.

Batch Rename Files with PowerShell

PowerShell is one of two command line interpreters included with Windows. The other is Command Prompt, but PowerShell is more flexible when it comes to renaming multiple files. You can both rename and edit multiple files with PowerShell.

First, open the folder that includes the files to rename. Then click File to open a menu with further options. Select Open Windows PowerShell, and then click Open Windows PowerShell as an administrator. That will open the window below at the directory opened in File Explorer.

Next, enter the following PowerShell command: Get-ChildItem -Filter “*file title*” -Recurse | Rename-Item -NewName {$_.name -replace ‘file title’,’new file title’ }. There you’ll need to replace ‘file title’ with the file name to modify. Delete ‘new file title’ and enter a file title there to rename the files to.

Press the Return key to initiate the batch file operation. This will rename all files with the first specified text string to the file title entered at the end of the commandlet. Thus, you can rename a multitude of files with the same text string.

You can edit a batch of files with PowerShell by entering: dir | rename-item -NewName {$_.name -replace ” “,”_”}. That will replace the file titles’ spaces with an underscore for all files included within a folder.

You can adjust that commandlet by replacing the underscore with something else. For example, the commandlet could be: dir | rename-item -NewName {$_.name -replace ”  “,”-“}. That will replace all double spaces in file titles with a hyphen.

So that’s how you can quickly rename and edit a batch of file titles with both File Explorer and PowerShell. PowerShell will certainly come in handy if you need to rename a multitude of file title with the same text string. For further details on how to rename files with PowerShell, check out this YouTube video.

Leave a Reply

Your email address will not be published. Required fields are marked *


Disclaimer: Some pages on this site may include an affiliate link. This does not effect our editorial in any way.

Todays Highlights