Лучшие инструменты для массового переименования файлов в Windows, macOS и Linux
Эти программы помогут быстро навести порядок в именах файлов.
Windows
Проводник
Стандартный файловый менеджер Windows умеет переименовывать группы файлов, но без особых изысков. Выделите несколько файлов и щёлкните «Переименовать» на вкладке «Главная». После этого переименуйте файлы и нажмите Enter. В результате они получат одинаковое имя и будут по порядку пронумерованы.
Total Commander
Этот универсальный файловый менеджер поддерживает массовое переименование файлов, причём вы можете создавать невероятно гибкие шаблоны имён. Возможности Total Commander можно расширить при помощи дополнений, что делает групповое переименование ещё более функциональным.
Advanced Renamer
Advanced Renamer — продвинутый инструмент, способный переименовывать большое количество файлов любым способом. Приложение бесплатно для некоммерческого использования.
Siren
Siren переименовывает файлы согласно создаваемым вами паттернам. На первый взгляд процесс создания шаблона кажется довольно сложным, но с помощью встроенного мастера это не составит труда.
Bulk Rename Utility
Интерфейс Bulk Rename Utility не вызывает особого восторга. Кроме того, в приложении отсутствует русский язык. Но со своими задачами оно справляется на ура.
Rename Master
Rename Master позволяет переименовывать файлы по множеству критериев, добавлять и удалять символы и нумеровать файлы в нужном вам порядке.
macOS
Finder
Файловый менеджер macOS оснащён встроенным инструментом для группового переименования. Просто выделите нужные файлы, щёлкните правой кнопкой мыши и выберите пункт «Переименовать».
NameChanger
Простое и бесплатное приложение, обладающее необходимыми возможностями для переименования большого количества файлов.
Name Mangler
Name Mangler отличается неплохой функциональностью, но за него придётся заплатить 19 долларов. Поддерживает пользовательские регулярные выражения и метаданные из файлов.
Better Rename
Better Rename стоит 19,95 доллара, но оно способно как угодно менять текст, кодировку, позиции, сокращения в именах файлов. Поддерживает работу с изображениями и фотографиями в формате RAW, а также с музыкальными файлами.
Это самое продвинутое приложение для массового переименования на Mac. Особенно оно понравится фотографам и обладателям больших музыкальных коллекций.
Linux
Sunflower
Sunflower — великолепный и многофункциональный менеджер файлов, способный потягаться с такими продвинутыми аналогами, как Total Commander и Double Commander. Кроме того, он поддерживает и массовое переименование файлов.
Установите Sunflower и в настройках отыщите пункт «Модули». Включите модуль «Улучшенное переименование». Затем выделите нужные файлы и запустите «Улучшенное переименование», которое находится в меню «Инструменты».
Thunar Bulk Renamer
Thunar Bulk Renamer входит в состав Thunar — файлового менеджера среды XFCE. Это очень простой инструмент для массового переименования, который поддерживает все необходимые функции, вплоть до переименования музыкальных файлов в соответствии с их тегами.
Чтобы установить Thunar Bulk Renamer, выполните команду sudo apt-get install thunar thunar-media-tags-plugin
KRename
KRename разработан для графической среды KDE, но функционирует и в других оболочках. Это приложение с наиболее богатыми возможностями из всех представленных альтернатив. Оно отлично справляется как с документами, так и с изображениями и музыкой.
Чтобы установить KRename, выполните команду sudo apt-get install krename
GPRename
Аналогичный инструмент для среды GNOME. GPRename позволяет переименовывать файлы, изменять регистр их имён и добавлять нумерацию. Заменять имена файлов можно с учётом регистра или регулярных выражений.
Чтобы установить программу, выполните команду sudo apt-get install gprename
pyRenamer
Это приложение очень похоже на GPRename, с той лишь разницей, что оно ещё и поддерживает работу с тегами в изображениях и музыке.
Чтобы установить pyRenamer, выполните команду sudo apt-get install pyrenamer
Если мы упустили какое-нибудь приложение для группового переименования, о котором следовало бы рассказать, пишите об этом в комментариях.
Rename multiple files in a folder, add a prefix (Windows)
I’d like to batch rename files in a folder, prefixing the folder’s name into the new names. i.e. files in C:\house chores\ will all be renamed house chores — $old_name .
8 Answers 8
Option 1: Using Windows PowerShell
Open the windows menu. Type: «PowerShell» and open the ‘Windows PowerShell’ command window.
Goto folder with desired files: e.g. cd «C:\house chores» Notice: address must incorporate quotes «» if there are spaces involved.
You can use ‘dir’ to see all the files in the folder. Using ‘|’ will pipeline the output of ‘dir’ for the command that follows.
Notes: ‘dir’ is an alias of ‘Get-ChildItem’. See: wiki: cmdlets. One can provide further functionality. e.g. ‘dir -recurse’ outputs all the files, folders and sub-folders.
What if I only want a range of files?
Instead of ‘dir |’ I can use:
For batch-renaming with the directory name as a prefix:
Option 2: Using Command Prompt
In the folder press shift+right-click : select ‘open command-window here’
If there are a lot of files, it might be good to add an ‘@echo off’ command before this and an ‘echo on’ command at the end.
The problem with the two Powershell answers here is that the prefix can end up being duplicated since the script will potentially run over the file both before and after it has been renamed, depending on the directory being resorted as the renaming process runs. To get around this, simply use the -Exclude option:
This will prevent the process from renaming any one file more than once.
Free Software ‘Bulk Rename Utility’ also works well (and is powerful for advanced tasks also). Download and installation takes a minute.
See screenshots and tutorial on original website.
I cannot provide step-by-step screenshots as the images will have to be released under Creative Commons License, and I do not own the screenshots of the software.
Disclaimer: I am not associated with the said software/company in any way. I liked the product for my own task, it serves OP’s and similar requirements, thus recommending.
This worked for me, first cd in the directory that you would like to change the filenames to and then run the following command:
I was tearing my hair out because for some items, the renamed item would get renamed again (repeatedly, unless max file name length was reached). This was happening both for Get-ChildItem and piping the output of dir. I guess that the renamed files got picked up because of a change in the alphabetical ordering. I solved this problem in the following way:
This «locks» the results returned by Get-ChildItem in the variable $dirs and you can iterate over it without fear that ordering will change or other funny business will happen.
Dave.Gugg’s tip for using -Exclude should also solve this problem, but this is a different approach; perhaps if the files being renamed already contain the pattern used in the prefix.
(Disclaimer: I’m very much a PowerShell n00b.)
How to batch rename multiple files on Windows 10
Source: Windows Central
On Windows 10, the process to rename a single file is easy, but it can become troublesome quickly when trying to change the name (or extension) to a long list of files within a folder.
Although, you can always install third-party tools to ease the process, Windows 10 includes various tools to make it easier to change the name of files using File Explorer, Command Prompt, and PowerShell.
In this Windows 10 guide, we’ll walk you through three ways to rename multiple files, including changing the extension, without the need to resource to third-party tools.
How to rename multiple files using File Explorer
On Windows 10, File Explorer offers the easiest methods to rename one or multiple files.
Rename multiple files one at a time
To rename multiple files with different names using the «Tab» key, use these steps:
- Open File Explorer.
- Browse to the folder with the files to rename.
- Click the View tab.
Select the Details view.
Source: Windows Central
Click the Rename button.
Source: Windows Central
Quick tip: You can also press the F2 button, right-click the files and select the Rename option, or click the file once and slowly click the file name again to trigger the rename action.
Once you complete these steps, you may need to repeat step No. 10 until you’re done renaming files.
Rename multiple files at once
To rename multiple files in bulk with the same name structure, use these steps:
- Open File Explorer.
- Browse to the folder with the files to rename.
- Click the View tab.
Select the Details view.
Source: Windows Central
Click the Select all button.
Source: Windows Central
Quick tip: You can also use the Ctrl + A keyboard shortcut to select all files quickly. You can press and hold the Ctrl key and then click the files to rename, or you can even choose the first file, press and hold the Shift key, and then click the last file to select a group.
Type the new file name and press Enter.
Source: Windows Central
After you complete these steps, all the selected files will be renamed using the same name structure with a count number between parentheses to make each name different. For example, summer_trip_2020 (1).jpg and summer_trip_2020 (2).jpg.
If you made a mistake, you could use the Ctrl + Z keyboard shortcut to undo the changes. Alternatively, you can click the menu button from the top-left corner (on the title bar of File Explorer) and select the Undo button.
How to rename multiple files using Command Prompt
You can also use Command Prompt to change the name of one or multiple files in bulk.
Rename single file
To rename one file with Command Prompt, use these steps:
- Open Start.
- Search for Command Prompt and click the top result to open the app.
Type the following command example to navigate to the folder with the files you want to rename and press Enter:
This example opens the «files» folder inside «Documents»:
Source: Windows Central
Type the following command to view a listing of the files and press Enter:
Type the following command to rename a file and press Enter:
ren «OLD-FILE-NAME.EXTENSION» «NEW-FILENAME.EXTENSION»
In the command, the quotation marks are only required if the name includes spaces.
This example renames the file to «summer_trip_20_notes.txt»:
ren s_trip_2020_notes.txt summer_trip_20_notes.txt
Source: Windows Central
Once you complete these steps, you may need to repeat step No. 5 to change the name of the remaining files.
Rename multiple files
To rename multiple files in bulk with the same name structure with Command Prompt, use these steps:
- Open Start.
- Search for Command Prompt and click the top result to open the app.
Type the following command example to navigate to the folder with the files you want to rename and press Enter:
This example opens the «files» folder inside «Documents»:
(Optional) Type the following command to view a listing of the files and press Enter:
Type the following command to rename multiple files in bulk and press Enter:
ren *.FILE-EXTENSION . -FILE-NAME.*
In the command, the asterisk * is a wildcard that tells the ren command to rename everything with a «.jpg» extension. The question mark ? is also a wildcard, but it represents a character of the original file name.
This example renames all «.jpg» files leaving the first three characters (which works as a unique identifier to avoid duplication) and appends «-hikingTrails» to the name:
ren *.jpg . -hikingTrip.*
Source: Windows Central
After you complete these steps, all files from a specific format will be renamed using the settings you specified.
Trim multiple file names
To make long file names shorter with Command Prompt, use these steps:
- Open Start.
- Search for Command Prompt and click the top result to open the app.
Type the following command example to navigate to the folder with the files you want to rename and press Enter:
This example opens the «files» folder inside «Documents»:
(Optional) Type the following command to view a listing of the files and press Enter:
Type the following command to make file names shorter and press Enter:
In the command, the asterisk * matches all the file names and extensions in the folder, and the question marks ? indicate how many characters to use for the new file name.
This example trims the file names longer than five characters:
Source: Windows Central
If the file name is less than five characters, then the name will not change. (If you want to make the file name longer, add extra question marks.)
Once you complete these steps, you’ll end up with shorter file names depending on the question marks (?) you specified in the command.
Modify multiple file names
To rename part of the file name on similar files, use these steps:
- Open Start.
- Search for Command Prompt and click the top result to open the app.
Type the following command example to navigate to the folder with the files you want to rename and press Enter:
This example opens the «files» folder inside «Documents»:
(Optional) Type the following command to view a listing of the files and press Enter:
Type the following command to rename part of file name and press Enter:
ren OLD-FILE-NAME-PART*.* NEW-FILENAME-PART*.*
This example renames names files start with «summer_trip_20» to «vacation_2020»:
ren summer_trip_20*.* vacation_2020*.*
Source: Windows Central
After you complete these steps, the group of files with similar names will be modified with the new name structure.
Change file extension
To change the file extension to another compatible extension, use these steps:
- Open Start.
- Search for Command Prompt and click the top result to open the app.
Type the following command example to navigate to the folder with the files you want to rename and press Enter:
This example opens the «files» folder inside «Documents»:
(Optional) Type the following command to view a listing of the files and press Enter:
Type the following command to change the file extension and press Enter:
ren *.OLD-EXTENSION *.NEW-EXTENSION
This example changes the extension from «.txt» to «.doc» compatible with Microsoft Word for the files in the folder:
This example changes only extension of a single file from «.txt» to «.doc»:
ren vacation_2020_notes.txt vacation_2020_notes.doc
Source: Windows Central
Once you complete these steps, the file extension will change to the new extension you specified in the command.
Rename specific extension file names
The previous instructions are meant to rename every file within the folder location. However, if you want to rename only a group of files with a particular format, you need to omit the asterisk * and specify the target extension in the command.
To rename files with a specific file extension, use these steps:
- Open Start.
- Search for Command Prompt and click the top result to open the app.
Type the following command example to navigate to the folder with the files you want to rename and press Enter:
This example opens the «files» folder inside «Documents»:
(Optional) Type the following command to view a listing of the files and press Enter:
Type the following command to change the extension for a group of files and press Enter:
ren FILE-NAME*.EXTENSION FILE-NAME*.EXTENSION
This example only renames images with a «.jpg» extension:
ren vacation_2020_*.jpg summer_trip_2020_*.jpg
Source: Windows Central
After you complete the steps, Command Prompt will rename the files using the settings that you specified in the command.
How to rename multiple files using PowerShell
On Windows 10, PowerShell is a scripting tool, similar to Command Prompt, which allows you to rename files virtually any way you want. Although there are many ways to use PowerShell to manipulate files, these instructions walk you through the most common scenarios to rename one as well as various files at the same time.
Rename single file
To rename only one file using PowerShell, use these steps:
- Open Start.
- Search for PowerShell and click the top result to open the app.
Type the following command example to navigate to the folder with the files you want to rename and press Enter:
Source: Windows Central
Quick note: The above command opens the «files» folder inside «Documents,» but you can use cd c:\users\USER-FOLDER-NAME\PATH\TO\FOLDER example syntax to navigate to other folder locations.
(Optional) Type the following command to view a listing of the files and press Enter:
Type the following command to change the name of a single file and press Enter:
Rename-Item «OLD-FILE-NAME.EXTENSION» «NEW-FILE-NAME.EXTENSION»
In the command, the quotation marks are only required if the name includes spaces.
This example renames the file to «summer_trip_2020_notes.txt»:
Rename-Item hiking_trip_notes.txt summer_trip_2020_notes.txt
Source: Windows Central
Once you complete the steps, you may need to repeat step No. 5 to continue renaming other files.
Rename multiple files in bulk
To rename multiple files in bulk, when the name structure isn’t important, use these steps:
- Open Start.
- Search for PowerShell and click the top result to open the app.
Type the following command example to navigate to the folder with the files you want to rename and press Enter:
(Optional) Type the following command to view a listing of the files and press Enter:
Type the following command to rename multiple files in bulk and press Enter:
This example renames images with a «.jpg» extension using the same («beach_trip_2020») naming structure and appends a different number at the end of the name:
Source: Windows Central
After you complete these steps, all the files with the format you specified will rename using your configuration.
Trim multiple file names
To make file names shorter, or trim part of the names by an N number of characters, use these steps:
- Open Start.
- Search for PowerShell and click the top result to open the app.
Type the following command example to navigate to the folder with the files you want to rename and press Enter:
(Optional) Type the following command to view a listing of the files and press Enter:
Type the following command to rename files using shorter names and press Enter:
Dir | Rename-Item -NewName
In the command update, «$_.BaseName.length-N» by changing the value of «N» to specify the number of characters that you want to remove.
This example will trim the name of your files by eight characters:
Dir | Rename-Item -NewName
Source: Windows Central
Once you complete these steps, you’ll end up with shorter file names depending on the length you specified in the command.
Delete part of the name from multiple files
To remove part of the file name on multiple files with PowerShell, use these steps:
- Open Start.
- Search for PowerShell and click the top result to open the app.
Type the following command example to navigate to the folder with the files you want to rename and press Enter:
(Optional) Type the following command to view a listing of the files and press Enter:
Type the following command to remove part of the file name and press Enter:
Dir | Rename-Item -NewName
This example removes the word «trip» from the name of all files in the folder:
Dir | Rename-Item -NewName
Source: Windows Central
After you complete these steps, the command will delete the part of the filenames that you specified in the command.
Replace part of the name from multiple files
To rename the same part of the file name, use these steps:
- Open Start.
- Search for PowerShell and click the top result to open the app.
Type the following command example to navigate to the folder with the files you want to rename and press Enter:
(Optional) Type the following command to view a listing of the files and press Enter:
Type the following command to replace part of file name and press Enter:
Dir | Rename-Item -NewName
This example replaces the word «vacation_» for «hiking_trip_» on the file name:
Dir | Rename-Item -NewName
Source: Windows Central
Once you complete these steps, the command will modify the part of the filenames with the replacement you specified in the command.
Remove spaces from multiple files
Spaces within the file names can sometimes cause issues, especially when using a command line. If you have filenames with spaces, you can modify the name to include a visual separator, such as a dash or underscore symbol.
To remove and replace spaces with underscores, use these steps:
- Open Start.
- Search for PowerShell and click the top result to open the app.
Type the following command example to navigate to the folder with the files you want to rename and press Enter:
(Optional) Type the following command to view a listing of the files and press Enter:
Type the following command to remove spaces from file name and press Enter:
Dir | Rename-Item -NewName
This example replaces spaces with underscores in all files:
Dir | Rename-Item -NewName
Source: Windows Central
After you complete these steps, the spaces within the filenames will be replaced with the separator you specified.
Change file extension
To change the file extension for a bunch of files with PowerShell, use these steps:
- Open Start.
- Search for PowerShell and click the top result to open the app.
Type the following command example to navigate to the folder with the files you want to rename and press Enter:
(Optional) Type the following command to view a listing of the files and press Enter:
Type the following command to change the extension on files and press Enter:
Dir | Rename-Item -NewName
This example changes any file extension to «.doc»:
Dir | Rename-Item -NewName
Source: Windows Central
Once you complete the steps, PowerShell will change the extension to the one you specified in the command.
Rename specific extension file names
The previous instructions are meant to rename every file within the folder location. However, if you want to rename a particular file format, such as documents, pictures, or videos, then you can use the «-filter» option.
To change the names of a specific file format, use these steps:
- Open Start.
- Search for PowerShell and click the top result to open the app.
Type the following command example to navigate to the folder with the files you want to rename and press Enter:
(Optional) Type the following command to view a listing of the files and press Enter:
Type the following command to rename files with a specific extension and press Enter:
This example renames only files that include the «.jpg» extension:
Source: Windows Central
Once you complete the steps, PowerShell will rename the files of a specific extension using the name that you specified in the command.
Although these commands have been tested to work as expected, it’s always recommended that you perform a test run before trying to rename the original files.
More Windows 10 resources
For more helpful articles, coverage, and answers to common questions about Windows 10, visit the following resources:
We may earn a commission for purchases using our links. Learn more.
Xbox Smart Delivery Games List
The full list of Xbox Series X and Xbox Series S titles committed to Smart Delivery support, and other free visual upgrade offers headed into next-generation consoles.
Xbox game store pages are still a nightmare for non-English speaking users
Microsoft’s push for global gaming is still set back by this basic feature disparity.
Giveaway: Win an Xbox Series X, a PS5, and an NZXT RTX 3080 PC
RobeyTech is giving away a huge amount of epic next-gen gaming swag to readers in the U.S. See inside for entry details!
The NFL is back! Check out these must-have Windows apps for football fans
After months of waiting through a unique offseason and no preseason games, the NFL is finally back this week. With these Windows 10 apps, you won’t miss a snap of the NFL action.