Learning the Markdown Syntax

What is Markdown?

Markdown is a tool that converts simple text characters into HTML. It was created to facilitate writing on the web. It is very similar in purpose to BBCode, being created later (in 2004).

Unlike BBCode, Markdown aims to avoid the use of tags wherever possible, as if the writing was just plain text. So generally Markdown writing is even simpler than BBCode, although it is more focused on text formatting.

Markdown was created by John Gruber with the audacious goal of becoming the writing format for the web. However, the idea was never to replace HTML, rather Markdown has always functioned as a complement, something that works alongside HTML, because everything that cannot be written in Markdown can be written in HTML.

Markdown’s popularity has grown a lot over time, to the point where major platforms like Github, Reddit and Stack Exchange use variations of Markdown in their internal forums. Messaging applications such as Whatsapp have also incorporated Markdown through the use of special characters.

Markdown vs BBCode

In general, Markdown is not necessarily a competitor to BBCode, just a different and complementary way of writing on the web, which may be more suitable in certain contexts.

In general, the writing difficulty can be ordered like this:

Text < Markdown < BBCode < HTML

The further to the right, the more features, and the further to the left, the simpler.

Basic Markdown Syntax

Let us summarize some basic Markdown syntax below. You can compare them later with this BBCode reference table.


To use bold or italics you do not need to open and close tags but simply insert an asterisk (*) or underline (_) markup.

Example: Writing the word **Markdown** in bold.

Alternative: Writing the word __Markdown__ in bold.

Result: Writing the word Markdown in bold.


Example: Writing the word *Markdown* in italics.

Alternative: Writing the word _Markdown_ in italics.

Result: Writing the word Markdown in italics.

Combining formatting

Special tip: To use bold and italic at the same time, just use three markers: *** or ___, or even a combination of these two markers, such as: __* or **_.

Example: Writing the word **_Markdown_** in bold and italics.

Result: Writing the word Markdown in bold and italics.

Block quotation

To make a block quotation, just use the > symbol.

Example: >This sentence is a block quote.


That sentence is a block quote.

Ordered Lists

Creating ordered lists in Markdown is so intuitive that it doesn’t even seem like an external resource is being used. Just put a dot next to the numbers. You can even indent items by restarting the count.

Example of a sorted list:

1. Apple
2. Banana
3. Avocado
4. Strawberry


  1. Apple
  2. Banana
  3. Avocado
  4. Strawberry
Example of a sorted list with sub-items (indentation):

1. Apple
2. Banana
    a. Cavendish
    b. Blue Java
3. Avocado
4. Strawberry

To create unordered lists, just use the marker -, + or even *. Examples:

– Apple
– Banana
– Avocado

+ Apple
+ Banana
+ Avocado

* Apple
* Banana
* Avocado


  • Apple
  • Banana
  • Avocado

Special tip: If the list starts with a number, to avoid confusion you must insert a backslash.

Example: – 2022\ is a promising year.

Creating blocks of code

To highlight a code block, simply indent the content with four spaces.


    print(“Hello, world!”)

Inserting images

You can insert not only an image but also alternative text for an image using Markdown. The syntax is as follows:
![Alt text](/path/to/img.jpg)

Example: ![markdown logo](


markdown logo

Inserting a Horizontal Line

You can insert a horizontal line with Markdown in three different ways: using 3 asterisks (***), 3 dashes (—) or 3 underscores (___).




Inserting Links

You can enter the target URL and anchor text for a link in a single command:
[anchor text](URL)

Example: [Home page](

Result: Home page

To just turn a URL into a clickable link, just use angle brackets.

Example: <>


This can also be done with an email address:

Example: <>


How to learn more

For more details about Markdown as a text-to-HTML tool, check the original documentation.