Locate Unicode characters with a source line and column
Admin ·
Copied text can contain an invisible separator or an emoji made of more than one encoding unit. Use a code point and its source location to identify the character and find it in an editor or data export.
Find one accent, an emoji and two invisible spaces
Choose Load example and Find non-ASCII characters. The example contains four non-ASCII occurrences. Line 1 ends with the é in Café. Line 2 has ID followed by a colon, a no-break space, a rocket and a zero-width space.
Choose the button for line 2, column 6. The context highlights the escaped U+200B value, making the character visible after the rocket. Filter Unicode category to Cf to show the format character alone.
| Code point | Line and column | UTF-8 byte offset | UTF-16 unit offset |
|---|---|---|---|
| U+00E9 | 1, 6 | 5 | 5 |
| U+00A0 | 2, 4 | 11 | 10 |
| U+1F680 | 2, 5 | 13 | 11 |
| U+200B | 2, 6 | 17 | 13 |
IETF RFC 6365, internationalization terminologyUnicode Standard Annex 44, Unicode Character Database
Compare the offset after the rocket
The rocket occupies four UTF-8 bytes and two UTF-16 units. The next entry is therefore at UTF-8 offset 17 and UTF-16 offset 13. The rocket counts as one code point, so its following column is 6.
Line and column numbers begin at one. Offsets begin at zero in the decoded text. A file saved with CRLF uses both code units and both UTF-8 bytes for the separator, while it still advances the physical line once.
RFC 3629, UTF-8 definitionThe Unicode Standard, Unicode encoding forms
Keep the frequency and location evidence
Download the JSON report while a filter is active. The file still includes all four occurrences, the Unicode data version, and the frequency of each code point. Use the positions to review the original text before applying any changes.
If you opened a Unicode file with a byte-order mark, check the file metadata in the report. The decoded-text offsets exclude that file marker. A U+FEFF typed inside the text is still an inspectable code point.
Unicode Standard Annex 44, Unicode Character DatabaseThe Unicode Standard, Unicode encoding forms
Common questions
How are tab columns counted?
A tab is one source code point. Column numbers are independent of the tab width shown by an editor.
Do combined emoji always appear as one row?
The finder reports one occurrence for each non-ASCII code point. A joined emoji may produce several rows.
Sources
Put it into practice.
- Non-ASCII Character Finder
- Mojibake Detector and Fixer
- Unicode Code Point Viewer
- Unicode Character Lookup