Folder batch renaming tutorial: Use wildcards to uniformly rename directories with different numbers to test names


Translation:EnglishFrançaisDeutschEspañol日本語한국어,Update Time:2026-06-30 07:12:41

Disclaimer: All images, text, and video content on the website are for reference only and may not be the latest, correct, or accurate. In case of any dispute, please refer to the actual experience effect!

In many office scenarios, folder names are often composed of project codes, client numbers, batch numbers, or test IDs. If these numbers differ but follow the same naming pattern, manual renaming can be very inefficient. This article uses a practical example to explain how to select "Find and replace keywords in folder names" in HeSoft Doc Batch Tool , add multiple folders, use a formula to fuzzy-find the text \d{3}, and then uniformly replace the matched three-digit numbers with -TEST. This approach allows you to quickly batch-rename a large number of folders, making it suitable for directory archiving, test data organization, and project documentation standardization.

Organizing folder names is a basic task that many office workers encounter. For example, after project testing is completed, a batch of folders named with numbers need to be changed to a unified test directory; before archiving materials, the serial numbers in the directory need to be replaced with version identifiers; or folder names submitted by multiple departments have similar formats but different numerical identifiers, which need to be renamed according to unified rules. If there are only two or three folders, manual renaming is acceptable; but if there are dozens or even hundreds, modifying them one by one will take up a lot of time and is prone to omissions and errors.

This article introduces a method more suitable for batch office processing: using HeSoft Doc Batch Tool to batch fuzzy modify folder names using wildcards or regular expressions. The example goal is to uniformly replace the different trailing three digits in multiple folder names with -TEST. That is to say, instead of separately searching for 812, 293, 376, 194, 705, use \d{3} to match all consecutive three-digit numbers at once, and then batch replace them with the specified text.

This method is suitable for users who want to improve file organization efficiency, especially for scenarios such as frequently handling Word document directories, Excel report directories, PDF archive directories, image material directories, project material directories, etc. The value of the software is not just "being able to rename," but more importantly, turning repetitive, rule-based manual operations into a one-time configuration and batch execution.

Applicable Scenarios: When should you use wildcards for batch renaming folders

Ordinary batch renaming is usually suitable for adding unified prefixes or suffixes to folders, or replacing identical text. But this article discusses a further requirement: the target content in folder names is different, but they conform to the same pattern. In this case, you need to use wildcards, formula fuzzy search, or regular expressions.

The following types of work are particularly suitable for using the method described in this article:

  • Batch replacement of numbered directories: For example, directories like INV4X812, ORD7A293, have different trailing numbers, but they are all three-digit identifiers.
  • Unifying test folder naming: Batch replace official identifiers with -TEST to distinguish test materials from official materials.
  • Project material organization: Replace old identifiers, batch numbers, and serial numbers in project directories with new names according to rules.
  • Standardizing directories before archiving: Before packaging, uploading, or sharing files, unify the folder names first to reduce subsequent search costs.
  • Batch office file management: Regardless of whether the folder contains doc, docx, xls, xlsx, ppt, pptx, pdf, or image materials, standardizing the outer directory name makes subsequent management clearer.

For such repetitive tasks, using specialized office software for batch processing can avoid wasting time on mechanical clicks and manual input. Especially when the naming rules can be described by expressions, the efficiency improvement is very significant.

Effect Preview: From Different Three-Digit Identifiers to Unified -TEST Marking

Before Processing: Multiple folder names with similar formats but different identifiers

The screenshot before processing shows that there are 5 folders in File Explorer, named INV4X812, ORD7A293, PO9C376, REQ8F194, SO2D705 respectively. The common feature of these names is: the front part is a mixed code of letters and numbers, and the tail end is a three-digit number.

If manually modified, you would need to open the rename state one by one, delete 812, 293, 376, 194, 705, and enter -TEST. It can be barely completed when there are few folders, but it is easy to get tired and make mistakes when the number increases. A more efficient approach is to abstract the "trailing three-digit number" into a rule, letting the software automatically search according to the rule.

image-Batch rename folders,rename folders using wildcards,batch replace directory names

After Processing: The three-digit numbers in the names are batch replaced

The screenshot after processing shows that the folder names have been changed to INV4X-TEST, ORD7A-TEST, PO9C-TEST, REQ8F-TEST, SO2D-TEST. It can be seen that the first half of each folder name is preserved unchanged, and the original three-digit numbers have been replaced with -TEST.

This is precisely the advantage of batch replacement using wildcards or regular expressions: it does not require each target character to be exactly the same, as long as these characters conform to a unified pattern, they can be processed at once. For renaming, standardizing, and test-processing a large number of directories, this method is more reliable than manual modification.

image-Batch rename folders,rename folders using wildcards,batch replace directory names

Operation Steps: Batch Renaming Folders with HeSoft Doc Batch Tool

Step 1: Open the Folder Name category and enter the Find and Replace function

After starting HeSoft Doc Batch Tool , first find Folder Name in the left navigation bar. The screenshot on the left also shows categories like File Name, File Organization, Word Tools, Excel Tools, PowerPoint Tools, PDF Tools, Text Tools, Image Tools, Video Tools, Audio Tools, etc., which indicates that this software is a toolbox-style software for office file batch processing.

Since this task is to modify folder names, not file content, nor processing Word, Excel, or PDF files, the "Folder Name" category should be selected. After entering, multiple function cards are displayed in the interface. The function to be used in this article is the first one: Find and replace keywords in folder names.

The purpose of choosing this function is to let the software find the target text in folder names according to the search rules we set, and replace it with new text. It can handle both fixed text replacement and the formula fuzzy search in the example.

image-Batch rename folders,rename folders using wildcards,batch replace directory names

Step 2: Add folders to the processing list and confirm the record count and paths

After entering the function page, an Add Folder button is provided at the top of the interface. After clicking, add the folders that need batch renaming to the task list. The list in the screenshot has successfully added 5 records, with names INV4X812, ORD7A293, PO9C376, REQ8F194, SO2D705 in order.

The table also shows the path, creation time, and modification time. The path column helps users confirm which directory the processing objects come from; for example, the path in the screenshot is located under D:\test\. A delete icon can be seen in the operation column on the right. If an item is found not to be a folder for this processing, it can be removed from the list before proceeding to the next step.

This checking action is very important. The advantage of batch tools is speed, but the premise is that the processing objects are accurate. If a folder is mistakenly selected, the subsequent rules will act on it as well. Therefore, it is recommended to check the record count, folder names, and paths before clicking the Next button at the bottom. The bottom of the screenshot shows that the record count is 5, indicating that the current task will process 5 folders.

image-Batch rename folders,rename folders using wildcards,batch replace directory names

Step 3: Set the search method to formula fuzzy text search

After clicking Next, you enter the "Set Processing Options" interface. The core setting here is the "Search Method". There are two options in the screenshot: Exact text search and Use formula for fuzzy text search. If you want to replace completely fixed text, you can choose exact search; but in this example, the numbers in each folder are different, so you need to choose Use formula for fuzzy text search.

The so-called formula fuzzy search can be understood as describing the content to be searched for with rules. We are not telling the software "search for 812" or "search for 293," but telling the software "search for three consecutive digits." In this way, all three-digit numbers that match the rule will be identified.

Step 4: Enter the list of keywords to search for and the list of keywords to replace with

In the "List of keywords to search for" on the left, enter:

\d{3}

In the "List of keywords to replace with" on the right, enter:

-TEST

Here, \d{3} is an expression that matches three consecutive digits. In this example, it will match 812 in INV4X812, 293 in ORD7A293, 376 in PO9C376, 194 in REQ8F194, and 705 in SO2D705. After filling in -TEST on the right, these matched three-digit numbers will be uniformly replaced with -TEST.

Therefore, the software will execute according to the following logic:

  • INV4X812 → INV4X-TEST
  • ORD7A293 → ORD7A-TEST
  • PO9C376 → PO9C-TEST
  • REQ8F194 → REQ8F-TEST
  • SO2D705 → SO2D-TEST

After the settings are complete, click the Next button at the bottom of the interface. The process bar at the top of the screenshot shows that the subsequent steps include setting the save location and starting processing. Continue to confirm by following the wizard, and then the batch folder name replacement can be executed.

image-Batch rename folders,rename folders using wildcards,batch replace directory names

Key Settings Analysis: The Role of Wildcards and Regular Expressions in Batch Renaming

Many users may find \d{3} unfamiliar when they first see it. In fact, its meaning is very intuitive: \d means a digit, {3} means it appears three consecutive times, so overall it represents three consecutive digits. Rather than memorizing complex syntax, it's better to first understand its value from office scenarios.

In batch renaming folders, the common target is not a single fixed character, but regular character fragments. For example, three-digit identifiers, four-digit years, dates, version numbers, batch numbers, etc. As long as these fragments can be described by rules, they can be located at once through formula fuzzy search. In this article's example, the suffix numbers of the 5 folders are all different, but they all conform to the rule of "three consecutive digits," so they can be matched by the same rule.

The value of this type of method lies in reducing manual judgment. Users only need to confirm the naming pattern in the early stage and write the pattern into the search box, and the remaining repetitive replacement is completed by the software. For office software, this is precisely the core meaning of batch processing files and folders.

Frequently Asked Questions and Notes

1. What if there are multiple three-digit numbers in the folder name?

When using \d{3}, it focuses on three consecutive digits. If there are multiple consecutive three-digit numbers in a folder name, it might match multiple positions. To avoid incorrect replacement, it is recommended to test with a small number of folders first to confirm the results meet expectations before batch processing a large number of directories.

2. Can the replacement keyword list be left empty?

The prompt in the right area of the screenshot says "Leaving blank means deletion". This means if you only want to delete the matched content, you can leave the replacement text empty; but the goal of this article is to replace the identifier with -TEST, so -TEST must be entered on the right. Otherwise, the processing result might become deleting the three-digit number instead of replacing it with the test identifier.

3. Why use "Use formula for fuzzy text search"?

Because the content to be replaced in this example is not fixed text, but different numerical identifiers. Exact text search is suitable for looking up completely identical content, for example, if all folder names contain "old version"; whereas formula fuzzy text search is suitable for looking up text with the same format but different specific content, such as three-digit numbers, dates, or identifiers.

4. Should I back up before batch modifying folder names?

It is recommended to back up important directories first, or select a small batch of sample folders for testing first. Batch renaming itself is a high-efficiency operation, but if the rules are set incorrectly, it can quickly affect multiple folders. Testing first, then executing in batch, is a more prudent processing flow.

5. Does this method only handle folders?

The screenshots in this article display functions under the "Folder Name" category, so this article focuses only on explaining batch replacement of folder names. Other categories like File Name, Word Tools, Excel Tools, PDF Tools can also be seen in the software interface, but different tasks should be entered into their corresponding modules to avoid confusing folder name processing with file content processing.

Summary: Using Rules for Batch Directory Renaming to Reduce Repetitive Work

Through the example in this article, it can be seen that the key to batch modifying folder names is not inputting new names one by one, but first finding the pattern in the names, and then letting the office software process according to the rules. The "Find and replace keywords in folder names" function in HeSoft Doc Batch Tool can match different but regular character fragments through "Use formula for fuzzy text search." The example uses \d{3} to match three consecutive digits, and then uniformly replaces them with -TEST, ultimately quickly completing the batch renaming of 5 folders.

If you often need to organize project directories, test directories, archive directories, or various office folders, it is recommended to hand over such repetitive naming tasks to batch processing tools. First add folders, check the list, then set the fuzzy search rules and replacement text, and finally execute the processing following the wizard to complete more standardized folder management in less time.


Keyword:Batch rename folders , rename folders using wildcards , batch replace directory names
Creation Time:2026-06-30 07:12:27

Disclaimer: All images, text, and video content on the website are for reference only and may not be the latest, correct, or accurate. In case of any dispute, please refer to the actual experience effect!

Related Articles

Don't see the feature you want?

Provide us with your feedback, and after evaluation, we will implement it for free!