Skip to content

Instantly share code, notes, and snippets.

@lucs
Last active October 4, 2023 15:12
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save lucs/ed1cce0c132474504b4a3c146dcca231 to your computer and use it in GitHub Desktop.
Save lucs/ed1cce0c132474504b4a3c146dcca231 to your computer and use it in GitHub Desktop.
Discord-pastable text using ANSI highlighting codes.
```ansi
Resetting to normal color and style is done by inserting ``⟨esc⟩[0m``.
Basic colors, foreground and background (meh):
 30 Black  40 Black 
 31 Red  41 Red 
 32 Green  42 Green 
 33 Yellow  43 Yellow 
 34 Blue  44 Blue 
 35 Magenta  45 Magenta 
 36 Cyan  46 Cyan 
 37 White  47 White 
Discord appears not to support these
foreground or background colors:
 90 Dark grey  100 Dark grey 
 91 Light red  101 Light red 
 92 Light green  102 Light green 
 93 Yellow  103 Yellow 
 94 Light blue  104 Light blue 
 95 Light purple  105 Light purple 
 96 Turquoise  106 Turquoise 
 97 White  107 White 
ANSI styles, some work (here, 0, 1, and 4):
Default colour 0  moo 
Bold 1  moo 
Italic 3  moo 
Underlined 4  moo 
Flashing text 5  moo 
Reverse field 7  moo 
Crossed out 9  moo 
An example combining some of the above:
 Magenta foreground and cyan "background", underlined 
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment