Spreadsheets & Bank · Microsoft Excel

Excel "Save As CSV" (locale & encoding export)

A CSV written by Excel's Save As dialog. People assume "CSV" means comma-delimited, UTF-8, and value-faithful; Excel's output depends on the machine's regional settings and the exact CSV variant chosen.

The shape, how the file is really laid out

Excel uses the operating system's list separator as the field delimiter, in

many non-US locales that is a semicolon, not a comma, and the same regional

setting makes the decimal separator a comma, so a money field can read

"1.234,56" inside a semicolon-delimited file. Encoding depends on the format

picked: legacy "CSV (Comma delimited)" writes Windows-1252/ANSI, which turns

accented names, the euro sign, and smart quotes into "?" or mojibake, while

"CSV UTF-8" prepends a UTF-8 byte-order mark (EF BB BF) that naive parsers

read as part of the first header cell. Leading zeros are dropped from anything

stored as a number ("01234" → "1234"), long numeric IDs are written in

scientific notation ("1.23457E+14") or truncated to about 15 significant

digits, and dates are emitted in the machine's short-date format. Percent

cells export either as a decimal (0.25) or as the text "25%" depending on cell

type.

The traps

Assuming a comma delimiter shreds a semicolon-delimited European export into one column, and where the decimal is a comma the delimiter and the decimal point collide so "1.234,56;7.890,00" is easily misparsed.

In the Format LibraryGet the Format Library

Reference: Microsoft Support, "Save a workbook to text format (.txt or .csv)" · Microsoft Support, "Import or export text (.txt or .csv) files" · Microsoft Learn, regional/list-separator and CSV encoding behavior