Line endings (CR, LF, CRLF) in a product CSV
Your CSV looks fine on screen, but your import page rejects it or shows something odd at the end of a value. For example, the rightmost column header is refused even though it looks correct, or the rightmost value in a row seems to carry an invisible extra character. These symptoms can have other causes. This post covers the invisible marker at the end of each row. If your problem is a line break inside a cell, see "Line breaks inside a CSV cell: fix split rows".
Why it happens. Rows are separated by an invisible marker. Row endings come in these forms. LF: a "line feed" character. CRLF: a "carriage return" followed by a "line feed". CR: a "carriage return" on its own, used by very old Mac software. Some importers may accept any of these forms. Others may expect a particular form. That depends on the importer, and we have not tested any importer.
What the free CSV check does. The free CSV check reads CRLF, LF, old-Mac CR, and mixed line endings the same way, with no effect on the result. This means the check does not flag this issue. A clean report does not tell you whether your importer accepts your file's line endings. Use the steps below for that, and use the check for the other problems it covers.
How to check it yourself. Open the file in a plain-text editor. Some spreadsheet programs may not show line endings at all. Look for the line-ending indicator; in many editors it sits near the bottom of the window. It may read CRLF, LF or CR. If your editor has an option to show invisible characters, turn it on. Compare the line-ending setting with what your import page asks for. If the page does not say, check its help text or ask its support.
How to fix it. 1. Keep a copy of the original file before you start. 2. In the same text editor, change only the line-ending setting to the form your import page expects. Do not change any other setting, such as the encoding. 3. Save the file. 4. Reopen it and confirm the indicator shows the form you chose. 5. Try the import with a small sample of rows before you use the full file.
Note. Not tried on a synthetic file: these steps have not been run on a synthetic file for this post.
Where the numbers come from
- HQ CEO chain draft, 27 September 2026; no customer file, no importer tested, and the steps were not tried on a synthetic file
- Free CSV check behaviour (heloft.com/m01): CRLF, LF, old-Mac CR and mixed line endings give the same rows and the same result, and the line-ending style is never reported (local run with synthetic files, 27 September 2026)