How to convert CSV to Excel
- Choose your .csv, .tsv or .txt file, or paste the data.
- Check the preview: the columns should line up. If not, pick the delimiter.
- Click "Download Excel" to save an .xlsx file with the same name.
The header row gets filter buttons and columns are sized to fit their contents. Untick the option to store numbers as numbers if you want every cell as text, exactly as in the CSV.
How to open a CSV in Excel without losing leading zeros
Double-clicking a CSV loses leading zeros. Import it instead:
- In a new workbook: Data → From Text/CSV, and choose the file.
- Check the "File Origin" (65001: Unicode (UTF-8) for most files) and the delimiter, then click Transform Data.
- Select the columns with leading zeros or long numbers, and set Data Type → Text (choose "Replace current" if asked).
- Close & Load, then save as an Excel workbook.
Older Excel versions have the Text Import Wizard (Data → Get External Data → From Text), where you set those columns to "Text" in step 3.
In Google Sheets
File → Import → Upload, and untick "Convert text to numbers, dates, and formulas" to keep leading zeros. Then File → Download → Microsoft Excel (.xlsx).
Questions
- Why does Excel remove leading zeros from my CSV, and does this keep them?
- When Excel opens a CSV it turns anything that looks like a number into one, so 02134 becomes 2134 and a 16-digit card or ID number loses its last digits. This converter stores those values as text in the XLSX file, so they show exactly as in the CSV. Values that are plain numbers (no leading zeros, at most 15 digits) are stored as numbers you can calculate with.
- Which dates become Excel dates?
- Dates written as 2024-03-01 (with or without a time, 2024-03-01 14:30) become real Excel dates. Other formats such as 03/01/2024 are kept as text, because they mean different days in different countries; Excel can convert them with Data → Text to Columns once you know the format.
- My CSV uses semicolons or tabs. Does that work?
- Yes. The delimiter (comma, semicolon, tab or pipe) and the encoding (UTF-8, Windows-1252 and others) are detected, and you can change them if the preview looks wrong.
- What if my CSV has more than a million rows?
- An Excel sheet holds at most 1,048,576 rows, so the rest go on more sheets, each with the header. Big files are read in the background, so the page doesn't freeze.
- Is the CSV uploaded?
- No. It is converted in your browser; nothing leaves your computer.
Related tools
- Excel to CSV Converter, All Sheets Convert Excel (XLSX, XLS, ODS) to CSV online: one sheet, or every sheet as its own CSV in a ZIP. UTF-8, any delimiter. Free; nothing is uploaded.
- CSV to JSON Converter Convert CSV to JSON online: an array of objects or arrays, numbers typed or kept as text, nested keys, JSON Lines. Free; your data never leaves your computer.
- CSV and Excel Viewer and Editor Online Open CSV, Excel, JSON and XML files in your browser: view millions of rows, sort, search, edit cells and save. Free, no install, nothing is uploaded.
- Merge CSV or Excel Files Merge several CSV or Excel files, or the sheets of a workbook, into one. Columns are matched by name. Free, and your files never leave your computer.