#494 · Developer Tool

BOM Detector

Inspect the leading bytes of an uploaded file for UTF-8, UTF-16, UTF-32, and several legacy Unicode byte order marks. Upload mode preserves the byte sequence needed for a reliable result; pasted text can only reveal a decoded U+FEFF character. The report separates an actual byte signature from a text-level marker and can produce a BOM-stripped copy.

Developer Input

BOM Detector
Ad space

How to use this developer tool

  1. Upload a file for byte-accurate detection, or paste text for a character-level check.
  2. Choose whether the detected signature should be removed.
  3. Run detection and review the encoding name and hexadecimal signature.
  4. Download the output only if stripping is intended.

What this developer tool does

The report identifies the recognized leading signature and shows the content with that prefix preserved or removed.

Compare the longest known BOM byte sequences first; pasted text is additionally checked for a leading U+FEFF character.

A BOM suggests an encoding but does not validate every byte in the file.

Example

Bytes: EF BB BF 48 65 6C 6C 6F
Detected: UTF-8 BOM

Use cases

  • Diagnose invisible characters at the start of source files.
  • Check CSV encoding before import.
  • Prepare BOM-free UTF-8 text for Unix tooling.

Tips for reliable output

  • Upload instead of pasting for exact bytes.
  • Check UTF-32 signatures before UTF-16.
  • Preserve a BOM when downstream software requires it.
  • Validate the remaining content separately.

Processing details

The detector recognizes UTF-8, UTF-16 LE/BE, UTF-32 LE/BE, UTF-7 variants, UTF-1, SCSU, BOCU-1, and GB18030 signatures when their byte sequences are available.

The shared upload control decodes a file as text before this tool runs, so exact non-UTF-8 byte inspection is limited in this single-page template; U+FEFF detection remains reliable for decoded text.

Frequently asked questions

What is a byte order mark?

A BOM is a short byte signature at the beginning of a file that can identify an encoding or byte order.

Can pasted text preserve its original BOM bytes?

Not reliably. Pasting gives the browser decoded characters; upload a file when exact leading bytes matter.

Is a UTF-8 BOM required?

No. UTF-8 has no byte-order ambiguity, though some software uses EF BB BF as an encoding signature.

Why does a file show no BOM but still decode correctly?

Many encodings, especially UTF-8, work without a BOM and are detected by configuration or content heuristics.

Does a BOM prove the entire file is valid?

No. It identifies only an initial signature. The remaining byte stream may still be malformed.

Output fields

FieldMeaning
SummaryHigh-level processing result
StatisticsCounts and validation details
ExportCopy-ready text plus structured data when available