• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
  • Skip to footer
Watchman Advisors

Watchman Advisors

Liberation - Life Purpose - Legacy

  • Home
  • Marketing Services
  • 1-on-1 Mentoring
  • Blog
  • Reviews
  • Support
  • Free Training
You are here: Home / Blog / How to Merge Hundreds of CSV Files on a Mac in 4 Free Steps (No Paid Software)

How to Merge Hundreds of CSV Files on a Mac in 4 Free Steps (No Paid Software)

May 12, 2026 by Trent Jessee 10 Comments

What You Will Learn
  • How to merge hundreds of CSV files into one — free, using Terminal
  • The exact copy-paste commands (no paid software needed)
  • How to split a huge CSV file into smaller chunks
  • How to remove duplicate rows after merging
  • How to avoid the common “rows run together” problem

Want an easy, free way to merge multiple CSV files on your MacBook Pro or other Apple laptop? I’ll also show you how to split huge CSV files into smaller chunks for easy upload to a database or other tool.

A while back I found myself with 254 separate CSV files that I needed to merge into one, so I could upload the list to my email marketing platform. Uploading all 254 files one at a time would have been a nightmare.

Merge multiple CSV files in bulk on a Mac

There are plenty of paid apps that merge CSV files for you — but I didn’t want to pay for something your Mac can already do for free in about a minute. Below are the exact steps and commands, followed by the video walkthrough.

How to Merge Multiple CSV Files on a Mac (Free)

The whole thing runs in Terminal, the free command-line app already built into every Mac. Here are the four steps:

  1. Put every CSV you want to merge into one folder. Move all the files into a single new folder (for example, one on your Desktop called csvfiles). Make sure only the CSVs you want to combine are inside it.
  2. Open Terminal. Press Command + Spacebar, type “Terminal,” and hit Enter.
  3. Navigate into your folder. Type cd (which stands for “change directory”), a space, then drag the folder from Finder onto the Terminal window — it fills in the path automatically — and press Enter. For example: cd ~/Desktop/csvfiles
  4. Merge them with one command. Paste the command below and press Enter. It combines every .csv in the folder into a single new file called merged.csv:
cat *.csv > merged.csv

That’s it. You’ll find merged.csv inside the same folder, containing all the rows from every file combined. It handles hundreds of files just as easily as a handful.

Two Common Gotchas (From Reader Questions)
  • Rows running together? If the last row of one file and the first row of the next end up on the same line, it’s because a file was missing a final line break. Opening merged.csv in a text editor and re-saving usually fixes it, or make sure each source file ends with a blank line before merging.
  • Want to remove duplicate rows? After merging, open merged.csv in a text editor with a “remove duplicate lines” feature (BBEdit is a popular free Mac option), or run sort merged.csv | uniq > deduped.csv in Terminal to create a duplicate-free copy.

Video Tutorial: Merging Multiple CSV Files Into One

Want the commands in a handy reference? Here’s a free cheat sheet you can copy to your own Google Drive.

How to Split a Big CSV File on a Mac (Free)

The opposite problem is just as common. I once had a client project that required cleaning a 100 MB CSV to import into a database — and the import needed the data broken into smaller chunks. Here’s how to split a huge CSV into smaller files, again using Terminal (navigate into the file’s folder with cd first, just like above).

Split the large file into roughly 1 MB pieces:

split -b 1m yourfile.csv

(Replace yourfile.csv with your actual filename. Change 1m to 5m for 5 MB pieces, and so on.)

Then add the .csv extension back onto each new piece:

for i in *; do mv "$i" "$i.csv"; done

Run that second command in a folder that contains only the split pieces, so it doesn’t rename anything you want to keep.

Tip: Free Spreadsheet Tools

If you’d rather open and clean your CSVs in a spreadsheet without paying for Excel, LibreOffice (libreoffice.org) is a free, actively maintained option that works much like Excel. Google Sheets is another free choice that runs right in your browser.

Give it a try, and let me know how it works for you in the comments — along with any tips or questions you have.

Working with large customer lists and data as you grow your business? If you’d like help turning that data into more sales, book a free 30-minute call with me here.

Reader Interactions

Comments

  1. Nicole Maxino says

    May 16, 2016 at 10:54 am

    Is there a way to eliminate duplicate entries when merging files?

    Reply
    • Trent Jessee says

      May 17, 2016 at 4:07 pm

      yes, you would simply use the remove duplicate function inside of the text editor you are using. I personally use Text Wrangler to do that after I merge the files. Great question :-)

      Reply
  2. Aidan Walker says

    May 26, 2016 at 2:59 am

    Hi,

    great video easy to follow and understand.

    I have a question, that’s not related to the video per se but does relate to downloading .csv files to my mac book pro.

    I am currently studying a free online edX course using my mac book pro and it seems it is more geared to those with windows when it comes to downloading .csv files. I am struggling to download three .csv files for the coursework to save and the load to R. When I click on the links to each .csv file they just open to a safari window but don’t actually download so I can’t save them to the coursework file to later retrieve. Any idea how I can do this.

    Reply
    • Trent Jessee says

      May 26, 2016 at 8:36 pm

      Hi Aidan,

      Great questions. I personally use OpenOffice which is free to use. Just go to openoffice.org and download the software. It’s similiar to Excel. Or you can use Google Docs which is also free.

      Regards,

      Trent

      Reply
  3. businessenglishtutors says

    November 10, 2016 at 1:07 am

    Hey Trent,

    Your method worked! Thanks so much! :-)

    Andrew

    Reply
    • Trent Jessee says

      November 10, 2016 at 9:37 am

      Glad it help out Andrew!
      Thanks
      Trent

      Reply
  4. Holger Raddatz says

    December 3, 2021 at 4:02 am

    First of all, thank you very much for this description.
    However, a problem arises for me when using it.
    I have customer data in .csv files consisting of last name, first name, street, phone number, etc. The individual details are separated by a comma. The data is meant to be imported into Excel and I use the commas to map the columns there.
    After the last entry in each individual csv. file is of course no comma.
    If I use the method you mentioned to import several of the csv. files. Files together, the first entry of the second file is added after the last entry of the first file … the first entry of the third file with the last entry of the second file, etc.

    Is there a command I can add in terminal that when merging the files a comma is added to the end of each file?

    Reply
    • Watchman Advisors says

      February 21, 2022 at 1:09 pm

      That’s a great question Holger! I don’t know of the command off the top of my head to use for that but you can probably find out online, sorry.

      Reply
  5. James says

    September 21, 2022 at 8:24 am

    Great step-by-step…worked flawlessly…only question I have is that in the video you said you would have a cheatsheet to download with your steps and I didn’t see one 🤷🏻‍♂️…oh and BTW, “cd” stands for ‘change directory’ which is the command it is giving the computer OS 😊.

    Reply
    • Watchman Advisors says

      October 6, 2022 at 11:15 am

      Thank you James. And here is the cheat sheet you can make a copy of:
      https://docs.google.com/document/d/1w2ijSkg0KX0tsvzZbktFadgdNrjXECiR46OtuiPhZ1k/edit?usp=sharing

      Reply

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Primary Sidebar

Search Watchman Advisors

Categories

  • Dropshipping
  • Finance
  • Investing
  • Marketing
  • Mentoring
  • Passive Income
  • Sales Skills
  • Success Principles
  • Tech

Want Help?
Book a Free 30 Minute
Breakthrough Call With Me Here

Company

  • Home
  • Marketing Services
  • 1-on-1 Mentoring
  • Blog
  • Reviews
  • Support
  • Free Training

Footer

Services

  • Consulting
  • WordPress Integration Services
  • Internet Marketing Management
  • Drop Shipping

Top Articles

  • Free List of 86 USA Dropshipping Suppliers That Let You Skip the Middleman and Keep More Profit
  • To Do List Member WordPress Plugin

Legal

  • Privacy Policy
  • Disclaimer
  • DMCA Notice
  • Copyright Notice
  • Anti-Spam
  • Affiliate Disclosure
  • Terms of Service
  • Refund Policy

Copyright © 2007 - 2026 Watchman Advisors, LLC