CursiveTexty

Discord Code Block: Inline Code, Blocks + Syntax Highlighting

Inline code

Wrap text in single backticks: `like this`. The backtick is the key under Esc on most layouts — not an apostrophe. Inline code gets the grey chip look and, usefully, disables all other markdown inside it.

Code blocks

  1. Type three backticks ``` and press Shift+Enter for a new line.
  2. Paste or write your code.
  3. Close with three backticks on their own line and send.

Syntax highlighting

Add a language right after the opening backticks — ```js, ```python, ```html, ```css, ```json, ```sql, ```cpp and dozens more — and Discord colors the code. This same mechanism powers the colored text tricks.

Code block questions

How do I make a new line inside the block without sending?

Shift+Enter. Plain Enter sends the message — the number one code-block frustration.

How do I show backticks inside code?

For inline, wrap with double backticks: “ `text` “. Inside a triple-backtick block, single backticks are already safe.

Is there a character limit?

Code blocks live inside normal messages, so the standard message limit applies — for long code, attach a file instead and Discord previews it with highlighting.