The key is to use code blocks. Although choosing between the Dark and Light themes is one of the most divisive Discord debates, color-based customization doesn’t extend far beyond this and setting custom function colours.

Discord, on the other hand, supports markdown. If you’re not familiar with markdown, it’s a basic symbol-based formatting system for adding effects like bolding and italicization to messages.
Code blocks may be the most flexible markdown sponsored by Discord. You don’t need to be a programmer to use code blocks, and many users are unaware that these blocky boxes allow them to colour their text.
Are you perplexed? Let’s talk about code blocks and how to use them to make Discord colour messages in this post.
What Are Discord Code Blocks?
Code blocks, also known as code boxes or simply boxes, are a type of markdown that Discord’s rendering engine supports.
If you’re unfamiliar with markdown, some of the most popular tricks are to italicise text with single asterisks (*like this*) or bold text with double asterisks (**like this**).
Underlines (_ _like this_ _), strikethroughs (~~like this~~), spoiler tags (||like this||), quotes (> like this), and single-line code blocks (`like this`) are all supported in Discord.
Discord, on the other hand, supports multi-line code blocks in addition to single-line code blocks. A single-line code block gives white, monospaced text a dark background, making it simple for Discord users to exchange short snippets of code in a readable format. Users can share more complex code that spans many lines with multi-line code blocks.
Wrap your text in triple backticks (“`like this“`) to make a multi-line code block. It will enclose your text in a wide, dark box, format it in a monospaced font, and keep all indentations.

The multi-line code blocks support syntax highlighting which sets them apart from other markdowns.
What Is Syntax Highlighting In Discord Code Blocks?
Syntax highlighting is a feature found in many text editors, including Notepad++ and Sublime Text. It enables coders to specify a document’s programming language, allowing essential code elements to be colorized for easier reading and comprehension.
Since Discord’s multi-line code block markup was created for this reason, there are several creative ways to use it to add colour to your messages.
After the first set of triple backticks, type a keyword to add syntax highlighting to your multi-line code blocks. Consider the following scenario:

When written as a message on Discord, that will appear like this:

Knowing which formatting styles bring out which colours is useless unless you have a comprehensive guide
Syntax Highlighting Styles for Discord Code Blocks
The following is a list of all recognised syntax highlighting keywords supported by Discord’s multi-line code block markup.
asciidoc

autohotkey

bash

coffeescript

cpp

cs

CSS

diff

fix

glsl

ini

json

md

ml

prolog

py

xl

xml

Discord will continue to add new syntax highlighting options as time goes on.
Although using Discord’s syntax highlighting isn’t as simple as simply changing the colour of your text, it’s still a very useful tool and the best choice for creating Discord colour messages right now.
If you ever have a big chunk of text that needs to be formatted for easier reading, such as a command list for your Discord music bot, code blocks are a great choice.
Leave a Reply