Creating Folders in Bulk Using Excel + Batch Files

Sometimes you need to get organized—fast. Maybe you’ve got 200 vendors, 80 strains, 12 months of compliance reports, or 6,000 blurry JPEGs from a mystery USB drive. Whatever the case, creating all those folders by hand is a waste of time and sanity.

This method lets you use Excel + a simple .BAT file to generate a bunch of folders in seconds. No programming knowledge, no IT guy needed—just you, a spreadsheet, and a little command line magic.

Use Case: Vendor Media Library

I used this exact method to create folders for every vendor we work with—one per folder—to store product photos, COAs, strain images, logo files, and social media assets. One minute of setup saved me hours of mindless clicking.

Other Cannabis Industry Use Cases

Here’s how else this trick can come in handy:

  • Compliance and Audits:
    Create folders by month/year (2023_01, 2023_02, etc.) for storing manifests, METRC reports, or testing results.

  • Strain Library Management:
    Build folders for each strain (GMO_Cookies, Blue_Dream, etc.) to organize terpene profiles, lab results, and product shots.

  • Retail Location Organization:
    If you operate multiple storefronts, make folders by store name or ID to keep invoices, staff docs, and daily sales cleanly separated.

  • Marketing Asset Management:
    Sort marketing collateral by campaign name, season, or product drop (4-20_Blowout, Fall_Bundle_2024).

  • Internal SOPs and Training Material:
    Keep SOPs, onboarding docs, and training videos organized by role (Budtenders, Managers, Security, etc.).

  • Event or Sponsorship Planning:
    Set up folders for trade shows, expos, and festivals you’re sponsoring or attending, each one housing everything from travel docs to booth designs.

This method isn’t just a time-saver—it’s a sanity-saver. When your operation starts scaling and the files start piling up, structure isn’t optional. It’s survival.

Let’s get into how it works.

Step 1: Prep Your Folder Names in Excel

  1. Open a new Excel workbook.

  2. In Column A, list all the folder names you want to create. For example:

    nginx

    CopyEdit

    Reports_2023 Q1_Sales Inventory_Archive Vendor_Contracts

  3. Make sure each folder name is valid—avoid symbols like \/:*?"<>| which Windows hates.

Step 2: Build the mkdir Command in Column B

  1. In Cell B1, enter this formula:

    excel

    CopyEdit

    ="mkdir """ & A1 & """"

  2. This will produce a command like:

    arduino

    CopyEdit

    mkdir "Reports_2023"

  3. Drag that formula down alongside all your folder names.

Step 3: Copy the Commands to Notepad

  1. Select all the cells in Column B that have the mkdir commands.

  2. Right-click → Copy.

  3. Open Notepad (or any plain text editor).

  4. Paste the commands in. You should see a list like:

    arduino

    CopyEdit

    mkdir "Reports_2023" mkdir "Q1_Sales" mkdir "Inventory_Archive" mkdir "Vendor_Contracts"

Step 4: Save as a Batch File

  1. In Notepad, go to File → Save As.

  2. Name it something like:

    CopyEdit

    create_folders.bat

  3. Set Save as type to All Files (*.*).

  4. Save it somewhere easy to access (like your desktop).

Step 5: Run the Batch File

  1. Double-click the create_folders.bat file.

  2. By default, it’ll create the folders in the same directory where the .bat file is saved.

  3. If you want the folders created in a specific directory, tweak the Excel formula like this:

    excel

    CopyEdit

    ="mkdir ""C:\Users\YourName\Documents\MyFolders\" & A1 & """"

Make sure the full path exists before you run it, or it’ll error out.