Set UTF-8 encoding on Netbeans

Update Netbeans file encoding

If you use an operating system which default file encoding is not UTF-8 (e.g. Windows) it is sometimes beneficial to change the file encoding NetBeans IDE will use.

Logo by netbeans.org
NetBeans IDE Logo

NetBeans IDE will use, as all Java applications, the operating system’s file encoding by default. To force the ide to use UTF-8, the following configuration needs to be added to the netbeans_default_options parameter

The parameter netbeans_default_options is defined in the file

Before the update the parameter definition could look like

After the change it should then look like

After a restart UTF-8 is used as file encoding.