This article explains how to batch rename files in Windows. Instructions apply to Windows 10.

What to Know

  • Open File Explorer, go to a file folder, select View > Details, select all files, select Home > Rename, enter a file name, and press Enter.In Windows PowerShell, go to a file folder, enter dir | rename-item -NewName {$_.name -replace “My”,”Our”} and press Enter. Using Command Prompt, go to a file folder, enter ren . ????????????-filename.jpg and press Enter.

Batch Rename Files in Windows 10 Using File Explorer

Renaming a file on Windows 10 is simple. You just right-click and select Rename. But doing this for a few dozen or a few hundred files gets tedious. Thankfully, it’s easy to batch rename files in Windows 10 using File Explorer, PowerShell, or the Command Prompt.

If you have a batch of pictures or other files that share something in common, you can rename all the files to use the same basic file structure.

For example, you can rename all your Disney World vacation photos from 2019 to ‘Disneyworld Vacation Photos 2019.’ When you batch rename files in Windows 10 using File Explorer (also known as File Manager), each file receives the new name with a number at the end, such as (1), (2), and so on.

  • Open File Explorer and navigate to the folder that contains all the files you want to rename.
  • Select View > Details in the Layout group in the ribbon. This lets you view the entire file name for each file in the folder.
  • Select all files in the folder by selecting the first file, holding the Shift key, and then selecting the last file. Or you can select Ctrl+A to select all files as well.
  • Select Home > Rename from the Organize group in the ribbon. This will change the first file to a field so you can type the new file name. Type the file name you’d like to use to rename all the files.
  • When you press Enter, you’ll notice all the other selected files received the same name with a number at the end to differentiate each file.

Using File Explorer to batch rename files in Windows 10 is just as fast as renaming a single file, with just a few extra clicks.

Open File Explorer and navigate to the folder that contains all the files you want to rename.

Select View > Details in the Layout group in the ribbon. This lets you view the entire file name for each file in the folder.

Select all files in the folder by selecting the first file, holding the Shift key, and then selecting the last file. Or you can select Ctrl+A to select all files as well.

Select Home > Rename from the Organize group in the ribbon. This will change the first file to a field so you can type the new file name. Type the file name you’d like to use to rename all the files.

When you press Enter, you’ll notice all the other selected files received the same name with a number at the end to differentiate each file.

Batch Rename Multiple Files With PowerShell

If you prefer using a command line tool to rename all your files, PowerShell is an excellent tool.

If you mistyped the name or changed your mind about renaming all the files, you can press Ctrl+Z to undo your last rename operation.

Using the last example, you can use PowerShell to rename all the files so that the first word of the file name is “Our” instead of “My”.

  • Select the Start menu, type Powershell, and select Windows PowerShell to open the app.
  • Navigate to the directory where your files are stored by using the cd command to navigate folders.
  • Once you’re in the correct directory, type the command:
  • dir | rename-item -NewName {$_.name -replace “My”,“Our”}
  • Then press Enter.
  • How the parameters for this function work:
  • Dir: Sends all files in the folder to the rename-item commandrename-item: A PowerShell command to rename files$_.name: Symbolizes each of the file being replaced-replace: Tells PowerShell that the action to take on each file is to replace the name"My",“Our”: The first word in quotes is the word in each title to replace, and the second word is what you want to replace it with
  • The Dir command in PowerShell has a lot of functionality.
  • The rename-item command in PowerShell has other syntax you can use. For example following rename-item with “$_ “Preface - $_” will add “Preface - " to the front of every filename.
  • When the command finishes, you’ll notice all your files have been renamed in the manner you specified.

Batch Rename Multiple Files With Command Prompt

You can also rename multiple files using the command prompt and the ? (question mark) wildcard.

Select the Start menu, type Powershell, and select Windows PowerShell to open the app.

Navigate to the directory where your files are stored by using the cd command to navigate folders.

Once you’re in the correct directory, type the command:

dir | rename-item -NewName {$_.name -replace “My”,“Our”}

Then press Enter.

How the parameters for this function work:

  • Dir: Sends all files in the folder to the rename-item commandrename-item: A PowerShell command to rename files$_.name: Symbolizes each of the file being replaced-replace: Tells PowerShell that the action to take on each file is to replace the name"My”,“Our”: The first word in quotes is the word in each title to replace, and the second word is what you want to replace it with

The Dir command in PowerShell has a lot of functionality.

The rename-item command in PowerShell has other syntax you can use. For example following rename-item with “$_ “Preface - $_” will add “Preface - " to the front of every filename.

When the command finishes, you’ll notice all your files have been renamed in the manner you specified.

  • Launch the command prompt and navigate to the folder where your files are stored.
  • Type the command
  • ren . ????????????-Vacation.jpg
  • Then press Enter.
  • Now you’ll see all the files have been renamed, keeping the first 12 original characters of the file name and adding “-Vacation” at the end.
  • Using the command prompt is an easy way to rename files quickly, keeping a unique portion of the file name while adding something descriptive at the end.

Whether you choose to batch rename files in Windows 10 using File Explorer, PowerShell, or Command Prompt really depends on the original file names and how you want to rename them.

Launch the command prompt and navigate to the folder where your files are stored.

Type the command

ren . ????????????-Vacation.jpg

Now you’ll see all the files have been renamed, keeping the first 12 original characters of the file name and adding “-Vacation” at the end.

Using the command prompt is an easy way to rename files quickly, keeping a unique portion of the file name while adding something descriptive at the end.

Get the Latest Tech News Delivered Every Day