Keywords: garbled character, encoding

# Characters aren't displayed correctly

Characters can be garbled if CotEditor fails to detect the file's encoding correctly. In such cases, change the character encoding as described below:

1. Choose Format > File Encoding, and select an encoding from the list.
2. When a dialog appears, click Reinterpret.

The behavior of each button in this dialog is as follows:

Reinterpret
  Reopens the file with the new encoding.
Convert
  Converts the text from the current encoding to the new one.
Cancel
  Cancels the operation. The document is left unmodified.

- You can also use the “File Encoding” toolbar item to change the character encoding.
- Changing the priority of auto-detection may help to reduce the occurrences of garbled characters.
  => Setting the priority of encoding auto-detection
- If you select “Refer to encoding declaration” in the Format preferences pane, in-document encoding declarations such as “charset=” or “encoding=” or “@charset” will take precedence when CotEditor auto-detects the character encoding.
  => Using encoding declarations (charset=, encoding=, @charset) for auto-detection

## See also

- Setting the priority of encoding auto-detection
- Using encoding declarations (charset=, encoding=, @charset) for auto-detection
- What is the difference between the four kinds of Shift JIS?