With the update to 1.16, text colours have been overhauled. This means instead of being stuck with the old colour format codes, full RGB can be used in chat, for player nicknames and on signs.
As a reminder, you can colour code and format your message by using the chat code of the colour you want before your message. If you want to use font and colour formatting, the colour format code must come before the font format code. For example, if I wanted to type a message in gold with bold font, I would type
This quick and easy formatting is all you need in most cases as typing out RGB hex codes for every chat message can be time-consuming. However, if you want more customisability for your nickname or placed signs. To start, choose a colour your like using an RGB colour picker. The formatting is very similar to the old system, just replace the single number or letter with your hex code prefaced with ‘#’. For example, if I wanted to colour my nickname with the colour #FF0061, I would type
Of course, multiple colour codes and formatting codes can be used together in the same message or nickname, it can just take a while to type in. I recommend using a simple text editor to draft your nickname command so you can copy and paste it into chat and make adjustments as needed without needing to fully re-enter the command. For example, If I wanted to make the first part of my nickname red, the second part green and the third part blue, I would type
If you want to use an RGB gradient in your nickname, here is a useful tool for getting hex codes in as many steps as you want.
Despite looking complicated and hard to understand, hex codes for RGB are very simple. They are written in hexadecimal (base 16), which means there are 16 symbols for numbers rather than the regular 10 arabic numerals we are used to. These symbols are 0-9 and A-F. The first two characters of a hex code is for the red channel. 00 meaning no red and FF meaning as much red as possible. The same is true for the remaining green and blue channels. In RGB, these channels can range from 0 to 255, the range of values that can be represented with two digits of hexadecimal.