CSV UTF-8 in Excel: accented invoice text

When Excel shows Café instead of Café, it read a UTF-8 CSV with the wrong encoding. Reimport as UTF-8, check the BOM and separate it from OCR errors.

See the PDF-to-Excel example

When Excel shows “Café” instead of “Café”, it has read a UTF-8 CSV as if it used another encoding, usually because the file was opened with a double-click and carries no UTF-8 signature (BOM). Reimport the untouched file with UTF-8 (65001) chosen as the file origin in Excel’s import dialog, or save it with the “CSV UTF-8” file type so the signature is written; do not correct the garbled words by hand.

Check one thing before reimporting: is the error in the CSV or in the invoice text itself? An encoding error is reversible, because the bytes are intact and only their reading is wrong. A character misread from a scanned PDF is not: no import setting brings back a letter that was never there. Encoding sits next to the other structural CSV issues, such as CSV commas and quotes inside a description field, and each needs its own check.

Why does Excel break accents in a UTF-8 CSV?

A CSV is a sequence of bytes. In UTF-8, é is stored as two bytes, C3 A9. Read as Windows-1252, a common legacy encoding, the same two bytes display as é. The bytes did not change; their interpretation did. That is why “Café” becomes “Café”, “Piñón” becomes “Piñón”, and “Überwurf” becomes “Überwurf”.

The CSV format does not carry the encoding inside the file. RFC 4180 registers a charset parameter for the text/csv media type, but that information is lost once the file is saved to disk. Excel then typically relies on a signature at the start of the file or on your choice in the import dialog; without either, it usually falls back to a legacy encoding.

How do you open a UTF-8 CSV in Excel with accents intact?

  1. Keep an untouched copy of the original CSV.
  2. Open a blank workbook and start the text/CSV import from the Data tab instead of double-clicking the file.
  3. Set the file origin to 65001: Unicode (UTF-8) and check the preview: “Café filtre” must appear correctly.
  4. Choose the delimiter, then set identifier columns to Text and amounts to the right numeric convention.
  5. Load and compare the sample values below with the PDF.

To hand the file to someone who will double-click it, save it with the “CSV UTF-8 (Comma delimited)” file type that recent Excel versions offer, which writes the UTF-8 signature. A plain “CSV” save usually uses a legacy encoding, and characters outside it can be replaced by question marks; reopen the saved copy to confirm what your version wrote.

InvoiceLineLab extracts invoice line items from PDF to Excel or CSV and keeps supplier descriptions as text, with the source page beside each row, so an accent can be checked against the invoice. The synthetic example shows the target table.

What does a UTF-8 BOM fix, and what not?

The Unicode BOM FAQ identifies EF BB BF as the UTF-8 byte order mark. In UTF-8 it has no byte-order role and works only as a signature, and the FAQ notes that some recipients of UTF-8 data do not expect it. For an interactive spreadsheet workflow it usually helps; for a machine importer it can hurt.

The typical side effect is a first header that reads reference instead of reference: the three signature bytes were read as Windows-1252 characters. Fix the BOM handling in the receiving import; do not rename every column. A BOM identifies an encoding. It repairs neither OCR errors nor delimiters.

Do not search and replace à in a saved file: the character can be legitimate, and a file saved after a wrong decoding may already have lost information. Reopen the original with the right encoding instead.

Is it an encoding error or an OCR error?

Compare the same line at three stages: the PDF, the CSV decoded with its documented encoding, and the imported sheet. Change one setting at a time: encoding first, then delimiter, then column types.

Observed symptomFirst checkAction if the check fails
Café appears as CaféDecode the untouched file as UTF-8Reimport the original rather than editing words
Café is correct but all fields sit in one columnInspect the delimiterCorrect the delimiter, independently of encoding
Accents correct but 000742 becomes 742Inspect the identifier column typeReimport the column as text
The saved file already contains Caf? or Caf�Compare with the supplier export and the PDFObtain the original characters; do not guess
The PDF itself shows Cafe or Caf6Compare with a clearer sourceOCR or source issue, not an encoding issue

If decoding the original as UTF-8 makes the accents reappear, the problem was the import. If every decoded view still shows the wrong word, go back to the supplier export or the PDF.

How do you check that accented descriptions survived?

Take a fictional invoice F-82 from a vendor (supplier) that prints amounts in EUR:

LineReferenceDescriptionQuantityUnit priceLine net
1000742Café filtre212.5025.00
2P-19Piñón38.0024.00
Total49.00

A correct import and one showing “Café filtre” both total EUR 49.00 (25.00 + 24.00), so the total cannot settle whether line 1 still matches the purchasing description. After reimporting, require two rows, unchanged references (000742 with its zeros), unchanged amounts and the exact accented descriptions.

Keep the failed import apart rather than appending corrected rows to it, which would count the same purchases twice. Do not strip accents from every description to make a comparison pass: that changes the text and can break product matching. Finish with a round trip on a copy: save in the agreed format, close, reimport with explicit settings, and compare the first header, both rows and the total.

FAQ

How do I open a CSV in Excel without breaking accents?

Import it from the Data tab and set the file origin to 65001: Unicode (UTF-8). Double-clicking relies on a signature the file may not have.

Does my CSV need a UTF-8 BOM?

For people who double-click the file in Excel, it usually helps. For automated importers, agree it first: some do not expect it and read it as part of the first header.

Why do accents break again after I save the file?

The file was probably saved with the plain CSV type, which uses a legacy encoding. Save with the CSV UTF-8 type instead.

Can an import setting fix an OCR error?

No. Encoding only changes how intact bytes are read. A letter misread from a scan must be corrected from the source.

Continue the checks

Item codes face a different conversion: see Excel leading zeros in supplier item codes. Before stacking several suppliers, prepare a supplier invoice column map, and protect descriptions against CSV formula injection in supplier text. Descriptions belong to line items rather than header fields.

InvoiceLineLab turns supplier invoice lines into reviewable spreadsheet rows. Download the fictional invoice CSV to test your import settings, and see the invoice data validation checks.

Sources and further reading

Get started with InvoiceLineLab

Enter your work email to get access to InvoiceLineLab. No account or payment is created at this stage.

Submitting sends your email and visit context to our publisher’s infrastructure, named on the Privacy page. No account, payment or automatic email is triggered. Privacy.