Color Codes
Formatting Codes
Custom Hex Color
Java 1.16+ supports any RGB color in JSON text components.
Live Preview
§fHello Minecraft!&fHello Minecraft!\u00A7fHello Minecraft!{"text":"Hello Minecraft!","color":"white"}How to Type § (Section Sign)
Alt+0167Option+6Ctrl+Shift+U 00A7Most server plugins accept & as a substitute for §. For MOTDs in server.properties, use \u00A7.
Quick Reference
| Code | Name | Hex | Copy |
|---|---|---|---|
| §0 | Black | #000000 | |
| §1 | Dark Blue | #0000AA | |
| §2 | Dark Green | #00AA00 | |
| §3 | Dark Aqua | #00AAAA | |
| §4 | Dark Red | #AA0000 | |
| §5 | Dark Purple | #AA00AA | |
| §6 | Gold | #FFAA00 | |
| §7 | Gray | #AAAAAABedrock #C6C6C6 | |
| §8 | Dark Gray | #555555 | |
| §9 | Blue | #5555FFBedrock #447FFF | |
| §a | Green | #55FF55 | |
| §b | Aqua | #55FFFF | |
| §c | Red | #FF5555 | |
| §d | Light Purple | #FF55FF | |
| §e | Yellow | #FFFF55 | |
| §f | White | #FFFFFF | |
| §gBE | Minecoin Gold | #EFCE16 | |
| §hBE | Quartz | #D9CCB8 | |
| §iBE | Iron | #A9B4B7 | |
| §jBE | Netherite | #8F727D | |
| §mBE | Redstone | #EE222C | |
| §nBE | Copper | #C87363 | |
| §pBE | Gold | #FFBF1E | |
| §qBE | Emerald | #13A045 | |
| §sBE | Diamond | #5FECFF | |
| §tBE | Lapis | #577BFF | |
| §uBE | Amethyst | #B66CDD | |
| §vBE | Resin | #FF6A00 | |
| §k | Obfuscated | - | |
| §l | Bold | - | |
| §mJE | StrikethroughOn Bedrock this code is a material color | - | |
| §nJE | UnderlineOn Bedrock this code is a material color | - | |
| §o | Italic | - | |
| §r | Reset | - |
Minecraft Color Codes: Complete Reference
Minecraft uses 16 color codes (0-9, a-f) and 6 formatting codes (bold, italic, underline, strikethrough, obfuscated, reset) to style text in chat, signs, books, commands and server MOTDs. Each color maps to a specific hex value used for rendering.
The Minecraft color code reference above shows all 22 formatting codes with their hex values, a visual color swatch and a live preview. Type text and apply colors to see exactly how it will appear in-game. Copy the codes for use in server configurations, plugin setups or command blocks.
Color codes work in both Java and Bedrock Edition, though the input method differs. Java Edition primarily uses them in JSON text components and server plugins, while Bedrock Edition supports the section sign directly in chat and signs.
Minecraft Color Codes for Java and Bedrock
| Code | Name | Hex | Preview |
|---|---|---|---|
| 0 | Black | #000000 | |
| 1 | Dark Blue | #0000AA | |
| 2 | Dark Green | #00AA00 | |
| 3 | Dark Aqua | #00AAAA | |
| 4 | Dark Red | #AA0000 | |
| 5 | Dark Purple | #AA00AA | |
| 6 | Gold | #FFAA00 | |
| 7 | Gray | #AAAAAABedrock #C6C6C6 | |
| 8 | Dark Gray | #555555 | |
| 9 | Blue | #5555FFBedrock #447FFF | |
| a | Green | #55FF55 | |
| b | Aqua | #55FFFF | |
| c | Red | #FF5555 | |
| d | Light Purple | #FF55FF | |
| e | Yellow | #FFFF55 | |
| f | White | #FFFFFF | |
| gBE | Minecoin Gold | #EFCE16 | |
| hBE | Quartz | #D9CCB8 | |
| iBE | Iron | #A9B4B7 | |
| jBE | Netherite | #8F727D | |
| mBE | Redstone | #EE222C | |
| nBE | Copper | #C87363 | |
| pBE | Gold | #FFBF1E | |
| qBE | Emerald | #13A045 | |
| sBE | Diamond | #5FECFF | |
| tBE | Lapis | #577BFF | |
| uBE | Amethyst | #B66CDD | |
| vBE | Resin | #FF6A00 |
Tips and Use Cases
Server MOTDs: Server owners use color codes in the server.properties MOTD field or in server plugins to create colorful server descriptions on the multiplayer server list. Many plugins accept & as a section sign substitute.
JSON text components: Commands like /tellraw and /title accept JSON with custom hex colors. Use "color":"#FF5555" for any RGB value, not just the 16 preset colors.
Sign coloring: On Bedrock Edition, type the section sign before a color code on a sign to color subsequent text. On Java Edition (1.20+), signs support JSON text components through commands for colored text.
Formatting order: When combining color and formatting codes, always apply the color first, then the formatting (bold, italic and so on). Applying a new color code resets all active formatting, so you need to reapply formatting after each color change.
Java Edition vs Bedrock Edition
| Feature | Java Edition | Bedrock Edition |
|---|---|---|
| Section sign in chat | Not supported (use commands) | Supported directly |
| Section sign on signs | Use JSON via commands (1.20+) | Type it directly on the sign |
| Custom hex colors | Yes, via JSON (#RRGGBB) | Not supported |
| Minecoin Gold (code g) | Not available | Yes (1.19.80+) |
| Material colors (§h to §v) | Not available | 11 colors, quartz to resin |
| Strikethrough and underline | §m and §n | Not available; §m and §n are redstone and copper |
| Formatting reset | New color resets all formatting | New color resets all formatting |
| MOTD colors | § in server.properties | Section sign in server settings |
Frequently Asked Questions
How do you type color codes in Minecraft?
Use the section sign followed by a code character. In Java Edition, JSON text components in commands support both preset codes and custom hex colors. Server plugins typically accept & as a shortcut for the section sign.
How many color codes are in Minecraft?
Java has 16 color codes (0-9, a-f) and 6 formatting codes (bold, italic, underline, strikethrough, obfuscated, reset), 22 in all. Bedrock has the same 16 colors plus 12 of its own (§g Minecoin Gold and 11 material colors), but only 4 formatting codes, because §m and §n are colors there.
What is the hex color for Minecraft green?
Minecraft has two greens: Dark Green (code 2, hex #00AA00) and Green (code a, hex #55FF55). The brighter green is more commonly used in plugin configurations and server UIs.
Can you use hex colors in Minecraft?
Yes, in Java Edition. JSON text components (used in /tellraw, books, signs via commands) support custom hex colors like #FF5555. Server plugins like EssentialsX also support hex via the &#RRGGBB format.
How do you type the section sign?
On Windows, hold Alt and type 0167 on the numpad. On Mac, press Option + 6. On Linux, press Ctrl+Shift+U, type 00A7, then Enter. Most server plugins also accept & as a substitute.
What is the difference between Java and Bedrock color codes?
Both editions share the 16 color codes 0 to f, though Bedrock draws gray (§7) as #C6C6C6 and, since 26.50, blue (§9) as #447FFF. Bedrock adds 12 colors of its own: Minecoin Gold (§g) and 11 material colors from §h quartz to §v resin. Because Bedrock spends §m and §n on redstone and copper, strikethrough and underline only exist on Java. Bedrock lets you type the section sign directly in chat and on signs, while Java uses JSON text components, and only Java supports custom hex colors.
Browse more Minecraft tools: