Skip to content

Batch Rename

Renames the selected files and folders in one pass according to a set of rules. There are three ways to open it.

Entry point Action
Context menu Right-click the selection → "Batch Rename"
Shortcut Shift+F2 (rebindable in the key binding settings)
Icon bar The "Batch Rename" button in the toolbar at the top of the pane

All three require at least one item to be selected. The main window is disabled while the batch rename window is open, so the selection can never change out from under you while you are composing the rules.

Top: rename mask

This field defines the skeleton of the new name. Left empty, the original name is used as-is. The buttons insert variables for you.

Variable Meaning
$N Original name without the extension
$N2-5 / $N2- Characters 2-5 / from character 2 onward of the original name
$E Extension, without the dot
$P / $G Parent folder name / the folder one level above that
${} Counter. Tunable per occurrence as ${start=10;increment=2;padding=3}
$YYYY $YY $MMMM $MMM $MM $M Year and month ($MMMM is the month name, following the display language)
$DDDD $DDD $DD $D Day-of-week name and day
$hh $h $mm $m $ss $s Hour, minute, second (24-hour clock)
$$ A literal $

The notation follows PowerToys PowerRename, the Windows-standard tool. Date variables read the modified timestamp by default; the dropdown switches them to the creation timestamp.

Below the buttons sits an always-visible legend of the variables, and under that a worked example using the files you actually selected (e.g. report.txt → report_20260813.txt). You can build the mask while watching what it really does, without having to remember what each symbol means.

Middle: search / replace and options

  • Use regular expressions: interprets the search field as a regular expression. The replace field accepts back-references $1, $2 (for example (\d{4})(\d{2})(\d{2}) → $1-$2-$3). While the expression is invalid, an error appears under the field and the preview is not updated

    Ticking it reveals pattern insert buttons and a legend underneath. \d+ (one or more digits), \s+ (whitespace), .* (any sequence), ( ) (group), ^ (start), $ (end) and \. (a literal dot) go into the search field; $1, $2, $3 go into the replace field. The legend is always visible, so you never have to hover to remember what a symbol means.

    On top of that, the "before" column of the preview highlights whatever the search matched. You can see at a glance why you got the result you did, which is what you need when a pattern is not behaving as expected. (No highlight is shown when a mask is also in use, since the search then no longer operates on the original name.) - Replace all matches: turn it off to replace only the first occurrence - Match case - Apply to: name only (default) / extension only / name and extension. The mask, the search-and-replace, and the case conversion all operate on this range. Folders are never split at a dot, so a name like v1.2 stays intact - Letter case: no change / lowercase / UPPERCASE / sentence case / Title Case - Counter: default start, step and digit count. Each ${} can override them individually - Include: toggles whether files and folders are each included

Bottom: before → after preview

Check the outcome line by line before anything runs.

  • Clear the checkbox on the left to exclude that row individually (excluded rows do not consume a counter value)
  • "Show changed only" hides the rows that stay the same
  • Rows whose names would collide, that contain characters Windows cannot use, a reserved name (CON, NUL, …), or a trailing dot or space, whose path would be too long, or that clash with an existing item outside the selection, are shown in red with the reason in a tooltip
  • The execute button stays disabled while even one problem remains

The counts (selected / changed / issues) are shown at the bottom right. The preview is recalculated in the background as you type, so operations never stall however many items are selected.

Executing and undoing

  • Swaps such as a → b, b → a do not break — a temporary name is used internally
  • If one item fails part way through, the rest still run and the resulting counts are reported
  • Afterwards, a single Ctrl+Z reverts the entire batch

Presets

Save a rule set under a name and recall it later. The save button asks for a name; picking an entry from the dropdown at the bottom left loads it into the fields. Saving under an existing name overwrites it.