data · 6 min read

Why your CSV starts with 

Three bytes that one program writes deliberately and another draws as rubbish. Nothing is broken — but they will quietly break a column lookup.

You open a CSV and the very first thing in it is , sitting in front of a column name that was supposed to be id. Or you import it, and a script that has worked for a year suddenly cannot find that column at all.

What is  at the start of a CSV file

A UTF-8 byte order mark, read the wrong way

Three bytes — EF BB BF — that mark the file as UTF-8. A reader that understands UTF-8 sees one invisible character and shows nothing. A reader that assumes one byte per character sees three, and draws them as . The file is fine; the table being used to read it is wrong.

read as UTF-8three bytes, one characterU+FEFFnothing is drawnthe bytesEFBBBFread as Windows-1252one byte, one character
The bytes are produced here by running U+FEFF through TextEncoder, and the bottom row by reading each one as a single byte — the same two operations your editor and your spreadsheet are performing. Nothing in the file is broken. One of them is using the wrong table.

Why anybody writes it on purpose

Excel on Windows opens a double-clicked CSV using the system code page, not UTF-8 — unless it finds the byte order mark at the front, which tells it otherwise. Without the mark, a file full of Arabic or accented names comes up as a screen of Ø and Ã. With it, the same file opens correctly on a double-click.

So every exporter that expects its output to be opened by a human on Windows writes one, and is right to. The mark is not a mistake or a leftover. It is one program leaving a note for another, and the note is only rubbish to whoever cannot read the handwriting.

The failure that costs money

It attaches itself to your first column name. A parser that does not strip the mark hands back a header of <invisible>id rather than id. On screen the column reads id. In a lookup, a join, or a config that names the column, it matches nothing.

Nothing errors. The import succeeds, the row count is right, and one field comes back empty forever. This is worth naming because the visible version of the problem —  in a cell — gets noticed and fixed in a minute, and the invisible version gets blamed on the data for a week.

Keep it or strip it

There is no universally correct answer, only a question about what reads the file next.

Keep it when a person is going to double-click the file on Windows, and especially when it contains anything outside plain English. That is the one case the mark exists for.

Strip it when the file is going into a script, a database import, an API, or any pipeline that told you what encoding it expects. Those readers know the encoding already and the mark is only a stray character on the front of your first field.

Removing it changes nothing else. It is three bytes at the very start; every other byte in the file is untouched. The encoding fixer reads the file in your browser, and the CSV cleaner will show you the parsed header so you can see whether the mark is still riding on it.

Why UTF-8 has one at all

It is inherited. In UTF-16 a byte order mark does real work: it tells you whether each pair of bytes arrives big end or little end first, which is genuinely ambiguous. UTF-8 has no such ambiguity — the byte order is defined by the encoding — so the mark carries no information about order.

What survived is the signature. Three bytes at the front that say this is UTF-8, which the Unicode standard recommends against and which too much software still needs. For more on what the encoding itself is doing, UTF-8 explained covers the part underneath this one.

The short version

 is a UTF-8 signature seen through the wrong reader. Keep it if a human on Windows will open the file; strip it if a machine will. And if a column lookup has started failing for no reason, check the first header for a character you cannot see.

Questions

What is  at the start of my CSV file?

It is the UTF-8 byte order mark — three bytes, EF BB BF — being drawn by a program that is reading the file one byte at a time instead of as UTF-8. In UTF-8 those three bytes are a single invisible character. Read as Windows-1252 they are the three separate characters ï, » and ¿. Your file is not corrupt, and nothing was added by whoever sent it to you beyond those three deliberate bytes.

Should I remove the byte order mark?

It depends entirely on what reads the file next. Excel on Windows uses it to recognise UTF-8 and will mangle accented and Arabic text without it, so for a file destined for a double-click it earns its place. A script, a database import or an API usually wants it gone, because it arrives silently attached to the first column name and turns id into id, which then matches nothing.

Why does it appear in my first column header?

Because a parser that does not strip it treats it as part of the first field. The header looks like id on screen and is really an invisible character followed by id, so a lookup for the column fails while the file looks perfectly normal. This is the most expensive form of the problem, because nothing errors — a join simply returns nothing and everybody blames the data.

Is a BOM required for UTF-8?

No, and the Unicode standard recommends against it for UTF-8. UTF-8 has no byte order to mark — the name is inherited from UTF-16, where the mark genuinely told you which end came first. In UTF-8 it survives only as a signature that says "this file is UTF-8", which is useful precisely because too much software still guesses.

Why does Excel need it when nothing else does?

Excel on Windows opens a double-clicked CSV using the system code page rather than UTF-8, unless it finds a byte order mark telling it otherwise. That single decision is the reason the mark is still written in 2026. Excel’s own import wizard lets you pick the encoding and needs no mark at all — it is only the double-click path that guesses.

What does or  mean in a text editor?

Both are the same three bytes shown by an editor that is not reading UTF-8. is the older rendering some terminals and editors use;  is what you get from a Windows-1252 reading. Seeing either means the file has a BOM and the thing displaying it does not know that.

How do I remove it without breaking the rest of the file?

Re-save the file as UTF-8 without a BOM, or read and rewrite it with a tool that strips it. Deleting the characters by hand in an editor works only if the editor is showing them, which the ones that matter usually are not. Nothing else in the file changes — the mark is three bytes at the very front and touches no other byte.

Is my file uploaded to fix it?

No. The tools on this site read the file in your browser and it never reaches a server. That matters here more than usual: a CSV with an encoding problem is almost always a customer list, an export or a report, and those are the files people are least willing to hand to a stranger to have three bytes taken off the front.

Tools from this guide

More data tools — all of them running in your browser, none of them uploading a file.