Merge two CSV files
Stack two files putting the columns back in the right place even when the order differs, or match rows on a key column and see at once how many were left without a partner.
or click to pick it, it stays on your device
or click to pick it, it stays on your device
How to use it
Paste the two CSV files in the two boxes, or drop the files onto the two dashed areas. Then pick what you want to do. Stacking puts the second file under the first one and gives you a single file, which is the right way to put twelve monthly exports back together. Matching brings the columns of the second file next to the rows of the first one, the job you would do in Excel with VLOOKUP, for example to place the customer email next to every order. The separator is detected file by file, so you can merge a comma file with a semicolon file without fixing them first.
Stacking lines the columns up by name, not by position
If the first file has date, description, amount and the second one has amount, date, description, the columns are put back in the right order by looking at the header (ignoring case and extra spaces), not at the position. A column that exists in only one of the files is added at the end and stays empty on the rows that do not have it. This is the most common mistake when two exports are copied and pasted by hand, because they look alike and the result quietly mixes amounts with dates.
Matching, the key and repeated keys
Choose the column holding the code the two files share, for example the customer code or the product code. You can keep every row of the first file (unmatched cells stay empty), only the matched ones, or every row of both files. The key column of the second file is not repeated because it would carry the same value, and columns with a name already taken get the _2 suffix. If the same key shows up several times in the second file the choice is yours, either keep the first row found or produce one row per match, which multiplies the rows. The count of repeated keys and of unmatched rows is always spelled out, together with the first codes that found no partner.
Why two codes that look the same do not match
The problem is almost never the tool. A leading zero eaten by a spreadsheet turns 007 into 7, an invisible trailing space from a paste makes "C001 " different from "C001", an id exported as a number becomes 1234.0, and upper case matters unless you tick the option. The tool always trims the edges and, with that option on, ignores case and doubled spaces, but it never invents a resemblance: if two codes stay different it will not join them, and it says so instead of making rows disappear.
The limits, stated up front
This works on the CSV text, so formulas, formats, colors and multiple sheets do not exist (for an .xlsx file go through Excel to CSV first). The key is a single column, not a pair of columns. Everything is held in memory, so the practical ceiling is a few tens of thousands of rows per file and anything above 20 MB is refused with a message. The downloaded file carries the UTF-8 mark at the start so Excel gets accented letters right, and cells are never touched: if a cell starts with an equals sign, Excel will read it as a formula exactly as it did before. No data leaves the device, there is no server behind this page.