File Organizer Batch Script

Automatically organize your files into separate folders based on their file extensions. Copy the code or download the ready-to-use BAT file.

● Windows Batch (.BAT)
@echo off
for %%a in (".\*") do (
    if "%%~xa" NEQ "" if /I "%%~fa" NEQ "%~f0" (
        if not exist "%%~xa" mkdir "%%~xa"
        move "%%a" "%%~xa\"
    )
)
How to use: Copy the code or download the BAT file. Save and run it inside the folder whose files you want to organize.

Note: Take a backup of your important files before running this script. It moves files into extension-based folders.