Discord Colored Text: Every Color Trick (diff, ini, fix, ANSI)
How colored text works in Discord
Discord has no color button. Every colored message you’ve seen uses one trick: code blocks with a language tag. Discord syntax-highlights code, so if your text happens to look like code in the right language, it takes that language’s colors. (The preview left shows the structure; the actual colors appear in Discord.)
The color cheat sheet
| Color | Block | How |
|---|---|---|
| Green | ```diff |
Start the line with + |
| Red | ```diff |
Start the line with - |
| Blue | ```ini |
Wrap the text in [brackets] |
| Yellow/orange | ```fix |
All text in a fix block renders yellow |
| Cyan | ```yaml |
Write the text before a colon: text: |
| Grey | ```bash |
Start the line with # |
Full-color ANSI blocks
On desktop, ```ansi blocks support real color codes — u001b[31m for red, 32 green, 33 yellow, 34 blue, and 1;xx for bold variants. Powerful, but mobile support is inconsistent, so for anything mobile users must read, stick to the cheat-sheet blocks above.
Colored text questions
Why is my colored text showing plain on my phone?
ANSI blocks don’t render colors on all mobile clients. The diff/ini/fix tricks are the mobile-safe options.
Can I color normal text outside a code block?
No — outside code blocks Discord renders one text color, period. Colors only exist through syntax highlighting.
Can I color my username?
Not with text tricks — name color comes from server roles. Ask a server admin for a colored role.
Code blocks themselves: the code block guide.