File Encoding Converter (UTF-8 with BOM, Shift_JIS)

Convert the character encoding of a CSV or text file. Add a BOM so Excel opens UTF-8 correctly, or convert to Shift_JIS. Runs entirely in your browser.

Recommended settings by purpose

Which encoding to save depends on who receives the file. Use this as a starting point.

What you want to do Recommended setting
Open a UTF-8 CSV directly in Excel UTF-8 with a BOM — the BOM lets Excel recognise the encoding
Import into an older business system Shift_JIS with CRLF — the traditional Windows combination
Read the file from a program (Python, PHP…) UTF-8 without a BOM, LF — a BOM ends up inside the first column name
Open in Excel for Mac UTF-8 with a BOM — the Mac version is also more reliable with a BOM
Import into Google Sheets UTF-8, BOM optional — the BOM is ignored automatically
Prepare text for an old email client ISO-2022-JP (JIS) — the legacy encoding for Japanese email

The encodings in brief

What this tool supports and what to watch out for.

Encoding Notes
UTF-8 Today's standard; covers every script and emoji.
UTF-8 with BOM Three marker bytes at the start so Excel does not guess the encoding wrongly.
Shift_JIS Long used on Japanese Windows. Cannot represent emoji or some variant kanji.
EUC-JP A Japanese encoding used mainly on UNIX systems; rarely chosen for new work.
ISO-2022-JP (JIS) The encoding used for Japanese email. Cannot represent half-width katakana.

Why CSV files come out garbled

Almost every case of garbled text in a spreadsheet comes down to a mismatch between the encoding a file was saved in and the encoding the application assumes when reading it. Excel on Windows assumes a CSV file is Shift_JIS unless the file says otherwise, while most modern services export UTF-8. Reading UTF-8 bytes as Shift_JIS produces the familiar strings of unrelated characters.

There are two fixes: convert the file to Shift_JIS, or keep UTF-8 and add a BOM — three marker bytes at the start of the file that tell the application which encoding it is. Adding a BOM does not change any of the text, so it is the safer option. This tool does both, detects the original encoding for you, and runs entirely in the browser so the file is never uploaded.

How to convert a file encoding

  1. Choose a file Drag and drop a CSV or text file, or click to select one. The original encoding and line endings are detected on load.
  2. Check the preview If the preview reads correctly, detection worked. If it looks like nonsense, the file is probably not plain text.
  3. Pick the target For Excel choose UTF-8 and tick "Add a BOM". For an older system that demands it, choose Shift_JIS.
  4. Download The converted file keeps its extension and gains a suffix such as _utf8bom or _sjis.

Tips for getting more out of it

  • If the file only needs to open in Excel, UTF-8 with a BOM is the safest choice: no character is lost, including emoji.
  • Converting to Shift_JIS replaces characters it cannot represent with "?". This tool lists them first so you can see what would be lost.
  • Never add a BOM to files a program will parse — in most languages it becomes part of the first column name and breaks header matching.
  • Excel can open a file with a chosen encoding via Data → From Text/CSV, but you have to repeat it every time. Converting the file once avoids that.
  • To repair a garbled string rather than a file, the mojibake repair tool is quicker.

When this helps

An exported CSV is garbled in Excel

Services commonly export UTF-8, which Excel misreads. Adding a BOM is enough to fix it.

A legacy system rejects your file

Older accounting and payroll systems often accept Shift_JIS only.

A BOM breaks your first column name

The BOM is invisible but ends up inside the first header when a program reads it. Convert to UTF-8 without a BOM.

Line endings collapse the file into one row

Convert LF to CRLF when handing a file to an older Windows application.

You just want to read a file you cannot open

Detection plus the preview lets you see what is inside without converting anything.

Encoding terms

Character encoding
The rule that maps characters to the bytes stored on disk. When the writing and reading rules differ, text comes out garbled.
BOM
Byte Order Mark: three bytes (EF BB BF) at the start of a file that identify it as UTF-8. Helpful for Excel, unwanted when a program parses the file.
Line endings
The bytes that end a line. Windows uses CRLF, macOS and Linux use LF, so files moved between them can gain or lose line breaks.
Shift_JIS
A Japanese encoding long used on Windows. Its repertoire is smaller than UTF-8, so emoji and some variant kanji cannot be represented.
Mojibake
The Japanese term for garbled text — the result of decoding bytes with the wrong encoding.

FAQ

If Excel is the only consumer, choose UTF-8 with a BOM — it prevents the garbling without losing any character. Shift_JIS is only necessary when the receiving system requires it, and it drops emoji and variant kanji.

Three bytes (EF BB BF) at the very start of a file. They are not displayed as text, but applications such as Excel read them to identify UTF-8. They do not change the body of the file.

No. Detection, conversion and download all happen in your browser, so the contents never leave your device — safe for files containing personal or internal data.

You may have selected something that is not plain text. An .xlsx workbook, for example, is a compressed archive rather than a text file; export it as CSV first.

No. Only the encoding changes; the characters are untouched. Leading zeros disappear because Excel interprets the column as a number, which is a separate issue.
Tool-kun

Side Note — What garbled text tells you

Garbled text has recognisable patterns. Strings of unrelated kanji appear when UTF-8 bytes are read as Shift_JIS: a Japanese character takes three bytes in UTF-8, so re-reading them two at a time produces entirely different characters. The opposite mistake — reading Shift_JIS as UTF-8 — yields rows of replacement characters instead, because the byte sequences are simply invalid. The shape of the damage points at the cause.

The BOM was originally invented for UTF-16, where it signals whether the bytes are big- or little-endian. UTF-8 has no such ambiguity, so the Unicode standard actually recommends against using a BOM with it. It survives in the Windows world anyway, because applications that can only guess at an encoding needed an explicit marker — a case of something the specification calls unnecessary becoming indispensable in practice.

CSV itself was only given a formal specification in 2005, with RFC 4180, long after the format was in daily use. Because every vendor had already implemented its own variant, quoting rules and line endings still differ between tools — which is why importing a CSV remains fiddly even when the encoding is right.