Convert a CSV to Excel
A real .xlsx, with nothing in it changed on the way.
- Leading zeros survive
- Long IDs are not rounded
- Numbers stay summable
- Nothing uploaded
1.Open the file
CSV or TSV. Drag it here, or choose a file.
Why it exists
Opening a CSV in Excel is not a neutral act. Excel guesses what every cell means, and the guesses are destructive: ZIP codes lose their leading zero, 16-digit order numbers are rounded to 15 digits, and anything that resembles a date becomes one. This writes the .xlsx itself, deciding each column from every value in it, so numbers arrive as numbers you can sum and everything that only looks like a number arrives as the text it was.
What it does
- Reads every value in each column, not a sample, before deciding whether the column is numeric.
- Writes numbers as real numbers and true/false as Excel booleans.
- Keeps any column with leading zeros or more than 15 digits as text, and shows you which ones before you download.
- Freezes and bolds the header row, adds a filter, and sizes the columns to fit.
- Splits a file of more than 1,048,576 rows across several sheets of one workbook, since that is Excel's limit per sheet.
Why not just open the CSV in Excel
Because Excel converts on open, and the conversion is the damage. A cell that was `00742` is stored as 742, and saving the file back writes 742. Writing the workbook directly means the type of every cell is decided once, by a rule you can see, rather than by Excel's guess at the moment you double-click.
Questions
- Will my leading zeros survive?
- Yes. Any column in which a value starts with a zero followed by more digits is written as text, so 00742 stays 00742 in the workbook and in every copy of it.
- Why are some of my numbers stored as text?
- Because they are identifiers rather than quantities: ZIP codes, phone numbers, account and order numbers. Excel can only hold 15 significant digits, so a 16-digit number would be rounded, and an identifier with its last digit changed is a different identifier. If you would rather have everything as text, tick the box and nothing is converted.
- Does it work with very large files?
- Yes, up to what the browser tab has memory for. Past 1,048,576 rows the workbook gets a second sheet, and a third, because no single Excel sheet can hold more.
The other tools
- Open a CSV file in your browserDrop a file in. It opens here, and it stays here.Open it
- Run SQL on a CSV fileReal SQL, on your file, without installing a database.Open it
- Merge CSV files into oneSeveral files in, one file out, columns matched by name.Open it
- Remove duplicate rows from a CSVDuplicates on the columns you say identify a row.Open it
- Compare two CSV filesAdded, removed, changed, matched on a key rather than line by line.Open it
- Convert a CSV to PDFA CSV, laid out as a readable table, saved as a PDF.Open it
- Convert a CSV to JSONEvery row an object, every header a key.Open it
- Convert JSON to CSVA tree, flattened into a table you can open anywhere.Open it
- Convert Excel to CSVEvery sheet of a workbook, out as clean UTF-8 CSV.Open it
- Split a CSV fileOne file too big to use, as several that are not.Open it
- Clean up a messy CSVGermany, germany and “Germany ” become one value again.Open it
- Convert a CSV to SQL INSERT statementsA CSV in, a .sql script any database will run.Open it