Windows cmd GBK to UTF8 encoding

The default format displayed by cmd at noon is GBK. If it is different from the encoding of the program, it will be garbled, so it is recommended to change it to UTF8 encoding

  1. First, right-click the properties to view the current encoding, usually 936 GBK

Enter chcp in cmd to see the number of the current code page

  1. We can manually enter chcp 65001 to switch UTF-8 encoding

Press enter to run, you can see that the active code page has been switched

  1. But if we want to set it to UTF8 encoding by default every time we open cmd, we can refer to the following operations

(1) Search for Registry Editor, or win+R to open regedit

Just create a new string autorun

Guess you like

Origin blog.csdn.net/qq_54120557/article/details/129685470