How to Use Code Blocks in Discord

Most Discord users type and send their messages without knowing much about coding. After all, you don't need fancy coding to talk to someone else. There are, however, a few benefits to learning the basic codes to make your messages stand out.

How to Use Code Blocks in Discord

Have you ever wondered how others send messages with fancy colored backgrounds? These unusual messages and quotes are possible using code blocks.


Code blocks are codes that make your posts stand out by changing the background. With Markdown, you can go one step further and make formatting changes through simple code usages. However, changing the background is usually enough to get readers to sit up and take notice.


Keep reading to find out how to make your posts stand out from the crowd using code blocks.

What is a code block?

A code block is a section of text in Discord that has a different color. The other color helps the text appear more obvious to all readers and also for aesthetic purposes. A code changes the background surrounding the text, even in the same message.

In other words, text not affected by a code block will appear normal, but text to which you apply a code block will appear different. These code blocks also leave the formatting alone, keeping everything in the same default font.

Code blocks are created by entering backticks at the beginning and end of messages. The '`' button is just below the Esc key and the '1' key is to the left.


How to Use Code Blocks in Discord

If your code block only contains one line of text, you just have to type a backtick at the beginning and end of the text, like this:


« Falcon Punch ! »

Code blocks with more than one line of text require triple backticks. This is what a multi-line code block looks like:

"`

Hi

Goodbye

Nice `` 

There are no spaces between triple backticks, and for the first triple backticks in multi-line code blocks, start a new line before typing your message. The "Hello" above will not appear if it is on the same line as the first triple backticks.

It's easy to confuse "Code Blocks" with "Markdown." While both can change how your text appears in Discord chat windows, the former changes the background while the latter deals with text formatting. Now let's see how you can use code blocks on different devices.

How to Use Code Blocks in Discord on PC

Whether you use the Discord client installed on your Windows PC or a browser, the use of the code block is the same. We will first focus on the basic code blocks in these instructions.

  1. Launch Discord on your PC.
    How to Use Code Blocks in Discord
  2. Go to any server.
    How to Use Code Blocks in Discord
  3. Choose a text channel where you have message permissions.
    How to Use Code Blocks in Discord
  4. Move your mouse over the text box.
    How to Use Code Blocks in Discord
  5. Enter a backtick.
    How to Use Code Blocks in Discord
  6. Type the content of your message.
    How to Use Code Blocks in Discord
  7. End the message with a backtick.
    How to Use Code Blocks in Discord
  8. Press Enter to send the message.
    How to Use Code Blocks in Discord
  9. If you format the code block correctly, you will notice that the text has a different background color than the other messages.
  10. Repeat if necessary.

If you want to enter multi-line blocks of code, these steps are for you.



  1. Go to Discord on your PC.
    How to Use Code Blocks in Discord
  2. Head to a server that allows you to type.
    How to Use Code Blocks in Discord
  3. Choose a text channel.
    How to Use Code Blocks in Discord
  4. Make sure you can type in the text box.
    How to Use Code Blocks in Discord
  5. Type three backticks with no spaces between them.
    How to Use Code Blocks in Discord
  6. Press Shift + Enter to start a new line.
    How to Use Code Blocks in Discord
  7. Type multiple lines of text.
    How to Use Code Blocks in Discord
  8. At the end of the last line, type three more backticks.
    How to Use Code Blocks in Discord
  9. Send the code block with the Enter key.
  10. If you type everything correctly, you will see a multi-line block of code.
    How to Use Code Blocks in Discord
  11. Repeat if desired.

These steps also work on Macs since Discord for macOS is pretty much the same as it is with PC users, so following the above two sets of instructions will also do the trick.


How to Use Code Blocks in Discord on the iPhone App

Discord on iPhone also works with code blocks. This way you don't have to switch devices when you want to send a message with a code to other users.

However, most keyboards on mobile devices do not display the backtick without digging. You'll need to find the backtick on your symbol keyboard, which only takes a few taps. Once you get familiar with its location, typing blocks of code will become second nature on iPhones.

Here's how to use Code Blocks on Discord for iPhone:

  1. Open your Discord app on your iPhone.
    How to Use Code Blocks in Discord
  2. Tap the icon for a server that allows typing.
    How to Use Code Blocks in Discord
  3. Go to any channel.
    How to Use Code Blocks in Discord
  4. Tap the text box to show your keyboard.
    How to Use Code Blocks in Discord
  5. Press the symbols button, usually on the left side of the keyboard.
    How to Use Code Blocks in Discord
  6. Find the backtick key and press it once.
    How to Use Code Blocks in Discord
  7. Type a message.
    How to Use Code Blocks in Discord
  8. Finish it off with another backtick.
    How to Use Code Blocks in Discord
  9. Send your message to the channel.
    How to Use Code Blocks in Discord
  10. The code block will appear if you typed everything correctly.
    How to Use Code Blocks in Discord
  11. Repeat if necessary.

Multi-line code blocks also work on iPhone. Here's how to use them:


  1. Launch your Discord app for iPhone.
    How to Use Code Blocks in Discord
  2. Go to a server.
    How to Use Code Blocks in Discord
  3. Open any text channel you can type.
    How to Use Code Blocks in Discord
  4. Bring up your keyboard by tapping the text box.
    How to Use Code Blocks in Discord
  5. Find and enter three backticks.
    How to Use Code Blocks in Discord
  6. Start a new line by pressing the button below the backspace button.
    How to Use Code Blocks in Discord
  7. Enter multiple lines of text.
    How to Use Code Blocks in Discord
  8. Finish with three more backticks just after the last line.
    How to Use Code Blocks in Discord
  9. Send the message to the channel.
    How to Use Code Blocks in Discord
  10. You will see a multi-line block of code if your backticks are formatted appropriately.
    How to Use Code Blocks in Discord
  11. Repeat as needed.

Some iPhone users may have backticks in different places if they use third-party keyboards. If your backticks are already showing, you're in luck and you don't have to find them. These instructions were for the default keyboard layouts.

Next, let's talk about performing the same task but on an Android device.

How to Use Code Blocks in Discord on an Android Device

Android phones and tablets can support Discord, and there are even more third-party keyboard apps available. Some may display backticks directly on the first keyboard screen, depending on your settings.

Code blocks also work in direct messages, which means you can emphasize messages you send outside of a public chat.

Here are the steps to use Code Blocks on Android devices:

  1. Launch Discord for Android.
    How to Use Code Blocks in Discord
  2. Access one of your servers.
    How to Use Code Blocks in Discord
  3. Head to a text channel.
    How to Use Code Blocks in Discord
  4. Tap the text box to show your keyboard.
    How to Use Code Blocks in Discord
  5. Enter a single backtick.
    How to Use Code Blocks in Discord
  6. Type your message and end it with another backtick.
    How to Use Code Blocks in Discord
  7. Send your message.
    How to Use Code Blocks in Discord
  8. Proper formatting will result in a perfect block of code.
    How to Use Code Blocks in Discord

For multi-line code blocks, you'll need to follow these other instructions:

  1. Open the Discord app on your Android phone or tablet.
    How to Use Code Blocks in Discord
  2. Tap and open a server.
    How to Use Code Blocks in Discord
  3. Go to a text channel that you can type.
    How to Use Code Blocks in Discord
  4. Tap the text box and get ready to type.
    How to Use Code Blocks in Discord
  5. Type three backticks.
    How to Use Code Blocks in Discord
  6. Start a new line and type several lines of text.
    How to Use Code Blocks in Discord
  7. Finish with three backticks just after the last line.
    How to Use Code Blocks in Discord
  8. Send the text message to the channel and the message with a new background will appear.
    How to Use Code Blocks in Discord
  9. You can repeat the process as many times as you want.
    How to Use Code Blocks in Discord

Be sure to read this

If you want your text messages to stand out on Discord, code blocks are one of the best ways to do it. They're easy to use, and you'll find yourself typing quickly with enough practice. Just a few more keystrokes, and suddenly you have a message that adds emphasis with no extra effort.

Have you seen any friends using code blocks before reading this? Do you find the various Discord text formatting tips interesting? Let us know what you think in the comments section below.

add a comment of How to Use Code Blocks in Discord
Comment sent successfully! We will review it in the next few hours.