UtilityNest

Merge Excel and CSV Files

Combine rows from several spreadsheets into one table. Choose the worksheet in each file, match columns by header name or by position, preview the result and save XLSX or CSV. The files are processed in your browser.

Works withMicrosoft ExcelGoogle Sheets

How to use Merge Excel and CSV Files

  1. 1Add two or more Excel, CSV, TSV or ODS files, up to 12 files of 20 MB each. Choose one worksheet for each workbook.
  2. 2Leave First row contains column names on if your files have headings.
  3. 3Choose whether to match by header name or column position. Use the arrows to change file order.
  4. 4Tick Add a source filename column if you want to know where each row came from.
  5. 5Click Preview result to check the combined rows, then save Excel or CSV.

Situations this solves

Monthly sales exports that arrive as separate files, survey responses downloaded per region, sign-up sheets kept by different team members, or inventory lists from several stores all end up needing one master table. Copying and pasting each file by hand is slow and easy to get wrong when the columns are not in the same order. This tool lines them up for you and stacks the rows.

Match tables with different column order

In a test combining a CSV with ID and Name and an Excel sheet with Name, ID and Score, header matching lined up ID and Name and added Score. IDs such as 001 remained text in the Excel export. Rows from the first file leave Score blank. The optional source filename column shows where each record came from. Header names are compared without regard to capital letters or spaces at the ends, so Order ID and order id count as the same column.

Header name or position?

Match by header name is the safe choice when files come from different people or exports, because it follows the column names wherever they sit. Match by position simply puts column 1 under column 1, and so on. Use it when the files have no headings, or when headings differ in wording but you know the columns are in the same order. The column order of the result follows the first file, with new columns from later files added on the right.

Choosing the right sheet

Each workbook in the list shows a sheet menu. Hidden sheets are marked as hidden, and sheets without data cannot be picked. Pick the sheet that holds the rows you want, such as Data rather than a Summary tab with totals. CSV and TSV files have just one table, so they skip this step. Change the order with the arrows: the first file sets the column order and comes first in the result.

What happened when we tested it

We merged three order exports: January as an Excel file with 1,200 rows, February as Excel with 950 rows, and March as a CSV with 1,340 rows whose columns were in a different order. With header matching and a source filename column, the preview reported 3,490 rows ready in about a tenth of a second, with Order ID, Date, Region, Units, Total and Source file in that order. Every March row landed under the right headings.

The Excel download was 114 KB and the CSV 150 KB. The Excel file had a filter on the header row and the top row frozen. Units and totals from the Excel files stayed numbers, while values from the CSV arrived as text, because a CSV does not say which cells are numbers.

Know what the new file contains

The output is a single table of values from the selected sheets. It does not reproduce the original workbooks, formulas, charts or cell styling. Keep the originals when you need those features. The combined table can be up to 200 columns and 1 million cells. A cell longer than Excel's 32,767 character limit can only be saved as CSV. In the CSV, text that looks like a formula starts with an apostrophe, so a spreadsheet will not run it.

Common problems and fixes

If you see a message about blank or repeated headers, a file has an empty heading cell or two columns with the same name; rename them or switch to Match by position. If a workbook is refused, it may be password protected; remove the password in Excel first. If a sheet is greyed out in the list, it has no data. If numbers from a CSV need to add up, convert the column to numbers in your spreadsheet after opening the Excel file.

Frequently asked questions

Can I combine Excel and CSV in one run?

Yes. Add both files and choose the desired worksheet for each workbook.

What if two columns in one file have the same heading?

Give each column a unique heading before matching by name, or switch to matching by position and check that the columns are in the same order.

Can I merge several sheets from the same workbook?

Each file contributes one sheet. To combine sheets from one workbook, save the extra sheets as separate files first.

Does it remove duplicates while merging?

No. Every row is kept. Run the result through Remove Duplicates from Excel or CSV afterwards.

What does the source filename column contain?

The name of the file each row came from, such as jan.xlsx, added as the last column of the result.

How many rows can I merge?

As many as fit within 1 million cells and 200 columns in total. For example, 10 columns allow up to about 100,000 rows.

Are my files uploaded?

No. The files are read and merged in your browser.

Related guides