Two spreadsheets rarely arrive ready to be treated as one. A monthly export needs stacking onto the previous month's file, or a customer list and an orders list need combining on a shared customer ID so each order shows up next to the customer's name and email. Doing either by hand in a spreadsheet works for small files and becomes error prone the moment either file has more than a few dozen rows.
Both merge modes run entirely in your browser using a real RFC 4180 aware CSV parser, so quoted fields containing commas or line breaks survive the process correctly. Neither file is ever uploaded anywhere, which matters when one of the two files behind a merge is a customer list or another export you would rather keep off a third party server.
Choosing between appending rows and joining on a key
Appending is the right mode when both files share the same columns and you simply want every row from both of them in one file, such as combining January's export with February's into a single running dataset. The column list comes from the union of both files' headers, so a column that only exists in one of the two files still ends up in the merged output with a blank cell for the rows that never had it.
Joining is the right mode when the two files describe different things that are related by an identifier, such as a customers file and an orders file that both contain a customer ID column. A join matches rows between the two files on that shared key and produces one merged row per match, combining columns from both sides rather than simply stacking them. This csv merger's join mode is the setting for that relational case.
- Append when both files share the same columns and you want every row from both in one output.
- Join when the files describe related but different things, connected by a shared key column.
- Join with left join when you want every row from the first file even without a match in the second.
- Join with inner join when a row without a match on both sides should be left out entirely.
How this csv merger can merge csv files by appending rows
In append mode, the header row from the first file and the header row from the second file are combined into one column list, in the order each column name is first seen across both files. Every row from the first file is written out first, followed by every row from the second, with each row's values placed under the correct combined column regardless of which order the columns originally appeared in. This is the append csv rows behaviour the mode is named for, and it is the setting to reach for whenever two exports share the same shape.
A column present in only one of the two files is not treated as an error. It simply gets a blank cell for every row that came from the file that never had it, the same forgiving behaviour a spreadsheet's own paste special handles when combining two ranges of slightly different shapes.
How the join csv on key column mode works
Joining requires naming one column that exists in both files with the same header name, such as customer_id or email, and this tool uses that shared value to line up rows from the first file with rows from the second. A left join keeps every row from the first file, filling in blank cells for its columns from the second file when no matching key value is found there. An inner join instead drops any row from the first file that has no match at all in the second, which is the right choice when a row without a counterpart is meaningless for the report you are building.
The output places every column from the first file first, followed by every column from the second file except its own copy of the key column, since repeating the same key value in two separate columns of the merged file would just be redundant. If a key value appears more than once in the second file, every matching row produces a separate merged row in the output rather than silently picking just one.
Preparing files before you combine csv files
A join only works cleanly when the key column's values are formatted identically in both files, so a customer ID stored as 00042 in one file and 42 in the other will not match even though a person can see they mean the same thing. Checking a handful of key values in both files before running the join catches this kind of mismatch early, well before it shows up as an unexpectedly short result.
For append mode, having both files use the exact same header text for what is meant to be the same column matters just as much, since a column named Email in one file and email in the other are treated as two distinct columns rather than one, which produces two mostly empty columns in the merged output instead of one complete one. Checking both header rows before running this csv merger avoids that surprise.
What limits how large a merge can get?
Each file is parsed independently with a state machine that follows RFC 4180, so quoted fields containing commas, embedded newlines and doubled quote escapes are read correctly in both files before any merging happens. Append mode then walks both row sets once each, while join mode builds a lookup keyed by the chosen column's values from the second file so that matching against the first file's rows stays fast even on files with many thousands of rows.
Because both the parser and the append or join logic that follows it run as plain JavaScript in your browser tab, there is no upload step and no server side processing queue for either file, which is what keeps a merge of two large exports as fast as your device can read them.
How to merge two CSV files
- 1
Add both CSV files
Paste or drop the first file, then the second. Neither file leaves your device at any point.
- 2
Choose append or join
Pick append to stack rows together, or join to combine columns using a shared key column.
- 3
Set the join details
For a join, name the shared key column and pick inner join or left join depending on how you want unmatched rows handled.
- 4
Merge and download
Press merge, check the resulting row and column counts, then download the combined CSV file or copy it.
Related tools worth bookmarking
Sources and further reading
- RFC 4180: Common Format for CSV FilesThe specification this tool's CSV parser follows for quoting and escaping in both source files.rfc-editor.org
- MDN: FileReaderThe browser API used to read each uploaded CSV file locally without a network request.developer.mozilla.org
- W3C: Model for Tabular Data and MetadataThe W3C recommendation describing tabular text formats, including relating tables by a shared key.w3.org
Frequently asked questions
Common questions about the csv merger.
No, in either mode. This csv merger's append mode matches columns by header name rather than position, so the second file's columns line up correctly under the first file's headers even if they were exported in a different order. A join looks up rows by the key column's value alone, so column order in either source file has no effect on the result.
Append stacks every row from both files into one output using a combined column list, which is the right choice when both files share the same columns. Join instead matches rows between the two files on a shared key column, combining related data side by side rather than simply stacking rows.
That depends on the join type you pick. A left join keeps the row from the first file with blank cells for the second file's columns. An inner join drops that row entirely, which is the right choice when a row without a counterpart in the second file is not useful for the result.
Yes, in append mode. The combined column list is the union of both files' headers, so a column that exists in only one of the two files still appears in the output with blank cells for every row from the file that never had it.
This almost always means the key column's values are formatted differently between the two files, such as one file storing a leading zero that the other dropped, so values that look the same to a person do not match exactly. Checking a few key values in both files before merging catches this quickly.
No. Each file gets its own pass through the RFC 4180 parser inside your browser tab, and the join mode's lookup table is built from those parsed rows in memory rather than from anything sent out. A customer list and an orders file can be merged side by side without either one crossing the network.