Search code examples
encodingutf-8sublimetext3sublimetext2byte-order-mark

Set Encoding of File to UTF8 With BOM in Sublime Text 3


When I open a file in Sublime Text 3, at the bottom I have an option to set the Character Encoding as shown in the screenshot.

setting encoding

There is the option to set it to UTF-8 , which after doing some research means UTF-8 Without BOM, but I want to set it to UTF-8 With BOM like shown below:

UTF-8 with BOM

How can I do this from within ST3?


Solution

  • I can't set "UTF-8 with BOM" in the corner button either, but I can change it from the menu bar.

    "File"->"Save with encoding"->"UTF-8 with BOM"