Developer tools
Merge CSV files into one
This page merges CSV files into one file inside your browser. Add two or more CSV or TSV files and put them in order. Then stack their rows under one header, with columns matched by name, or place their columns side by side. Copy the result or download it.
1. Add CSV files
Drop two or more CSV files here
UTF-8 CSV, TSV or delimited text
Add more files at any time. The list order determines the output order.
No files added yet.
3. Results
No result yet
Enable JavaScript to merge CSV files.
Scroll within the table to see more columns. With the table focused, use the arrow keys.
Preview shows windows of 25 rows and 8 columns. Copy and download include every record.
How to combine CSV files into one
To merge two CSV files or more, add them, set their order, pick a merge mode and select Merge CSVs. You can change the order and settings until then.
- In 1. Add CSV files, select Choose files or drop two or more files on the box. Load example replaces the list with two sample files.
- Set the merge order with Move up and Move down. Remove takes a file out of the list.
- In 2. Merge settings, pick a Merge mode: Append rows (vertical) or Side by side (horizontal).
- Keep First row in every file is a header checked when each file starts with column names. In append mode, Align appended columns by header name matches columns by name.
- Leave Input delimiter on Auto-detect for each file, or pick comma, semicolon, tab or pipe. Pick the result's separator in Copy / download delimiter.
- Select Merge CSVs and check the preview in 3. Results. Then select Copy CSV or Download CSV. With Tab, the link reads Download TSV.
Append CSV files with different headers
In append mode the tool matches columns by header name. Files with the same columns in a different order still line up. A column that only some files have joins the output, and the other files get empty cells in it. Each file's first row is its header, and the output has one header row.
The match is exact. Case and spaces count, so "ID" and "id" become two columns. When a file repeats a name, its second "id" matches the second "id" of the other files. Before you merge, the file list counts the output columns each file lacks and names up to 8.
In the Load example files, january.csv has id, name and total, and february.csv has name, id and note. The merged header is id, name, total, note, and Lee's row becomes 003, Lee, an empty total and "new, customer". The leading zeros in 001 and 09 stay, because the tool keeps every value as text. The results line counts 3 padded cells.
Append rows or place columns side by side
Append rows (vertical) puts the files one under another. It suits exports that share a layout, such as one file per month. The result has as many data rows as all the files together.
Side by side (horizontal) puts the columns of each file after the columns of the file before it. Rows pair by position, so row 1 meets row 1 and row 2 meets row 2. The tool does not match rows by an ID or key column. When one file has fewer rows, the empty cells go after its last row, and repeated header names stay as separate columns.
Two settings change how the files are read. Clear Align appended columns by header name to stack columns by position. The earliest header at each position then names that column, and the file list counts the labels that differ. Clear First row in every file is a header when your files have no header row, and every row stays as data.
Limits
The tool stacks files or sets them side by side. It does not join rows by a shared ID or key column, and it does not remove duplicate rows. Only the first row of each file is read as a header, so a header row that repeats inside a file stays in the output as data.
The tool decodes every file as UTF-8. A file with bytes that are not valid UTF-8 gets an error that asks you to save it as UTF-8. Save Excel and other spreadsheet workbooks as CSV first.
The tool reads any valid UTF-8 text file, whatever its extension. The Choose files dialog lists CSV, TSV and plain text files by default, so drop other files on the box.
The list marks a file with a broken quoted field or with no records at all. The page exports nothing until you fix or remove it. If a file exceeds the browser's text-size or memory limit, the page reports a decode error.
Output format and size
The output quotes every field and separates records with CRLF, in UTF-8 with no byte order mark. Pick Tab (TSV) in Copy / download delimiter to get tab-separated values, and the file downloads as merged.tsv. Copy CSV puts the same text on the clipboard.
Blank lines stay in the output as empty rows, and each one adds to the padded-cell count. The tool drops only the line break after the last record, so delete extra blank lines first if you do not want them.
The page sets no limit on files or rows. The files and the result must fit in browser memory. In Chrome the merged text must also stay under about 536 million characters, because the tool builds it as one piece of text. Every field gains two quote marks, so the output can be longer than the input files.
Questions
How can I merge CSV files online for free?
Open this CSV merger, add two or more files and select Merge CSVs. The page has no account or payment step. Your files are not uploaded, because the browser reads them and a background worker on your device builds the merged file. You then copy the result or download it from the page.
Can I combine multiple CSV files into one?
Yes. The page sets no limit on the number of files, but the combined size must fit in browser memory and, in Chrome, stay under about 536 million characters. In append mode the rows of every file go under one header row, in list order. Files with different columns still combine, and the missing cells stay empty.
How can I merge multiple CSV files into one?
Add the files, pick a merge mode and select Merge CSVs. Append rows suits files that hold the same kind of record, such as monthly exports. Side by side pairs rows by position, so every file must hold the same records in the same order. If one file lacks a record, its later rows pair with the wrong rows.
What does CSV mean?
CSV stands for comma-separated values. A CSV file is plain text in which each line is a record and commas separate the fields. A field that holds a comma, a quote or a line break sits inside double quotes. This tool also reads files that use a semicolon, a tab or a pipe instead.