Range: Move, Copy, Delete or Keep Part of a Filename
Batchio's Range rule lets you grab a specific part of every filename and do something with it. Select by character position or by a word or pattern, then move, copy, delete, or keep the selection. Every change appears in the live preview before you commit.
How do you select part of a filename in Batchio?
By Position is ideal when your files share a consistent structure, such as a fixed prefix or a code of the same length at the start of every name. You set where the selection starts and how many characters it covers, and Batchio highlights that slice in the live preview. By Text is the better choice when the part you care about moves around. You type the text to find, optionally as a regular expression, and Batchio locates the first match in each filename no matter where it sits.
Because By Text accepts regular expressions, a pattern such as \d{4} finds a four digit year in any position. That flexibility is what makes the Range rule reliable across messy, inconsistent filenames rather than only tidy ones.
Can you move a part of the filename to the end?
A common need is pulling a year or a code from the front of a name to the back. With the Move action you select the part once, then pick where it lands. Placing it before or after specific text is especially useful when position varies, because Batchio finds the anchor text first and drops your selection next to it. If the anchor text is not present in a given file, that file is left unchanged, so nothing breaks across a mixed batch.
Copy works the same way but leaves the original in place, which is handy when you want a code to appear in two spots. For a whole template style reshuffle rather than moving a single part, the Rearrange rule splits the name into pieces and rebuilds it in any order.
How do you keep only part of a filename and discard the rest?
Keep is the inverse of Delete. Instead of removing the selection, it removes everything around it. This is the fastest way to reduce long, cluttered names down to the one piece that matters, such as an order number, a date, or an identifier buried inside a longer string. Combined with By Text selection, you can keep a matched pattern like a year or an invoice number even when its position differs from file to file.
Delete does the opposite and strips the selected part out while leaving the rest intact. Both actions ignore selections that fall outside the name and searches that find no match, so a rule applied to a large, varied batch only touches the files it genuinely matches.
Does the Range rule work with other rules?
You might use Find & Replace to clean up separators, then a Range rule to move a code to the end, then Numbering to append a sequence. Because each rule feeds into the next, you build a complete renaming workflow that runs in a single pass. You can reorder the rules with the up and down controls on each rule, and you can limit a rule to only some files using Smart Filters.
Every step stays visible in the two column preview, so you always see the original name beside the final result before anything is written to disk.
Reshape Any Filename, Safely
Move, copy, delete, or keep exactly the part you need, with a live preview on every file. Batchio includes all 12 rule types free.
Download BatchioMarcel Iseli is an indie app developer and the creator of Batchio. He builds native macOS utilities focused on productivity and file management.