Markdown Cheatsheet: The Only Syntax Guide You’ll Ever Need
📖 Free access to the full article
1. Headers
Headers are created using the #
symbol followed by a space. The number of #
symbols indicates the level of the header.
# H1 Header
## H2 Header
### H3 Header
#### H4 Header
##### H5 Header
###### H6 Header
2. Emphasis
You can emphasize text in Markdown using asterisks (*
) or underscores (_
).
- Italic: Single
*
or_
around text - Bold: Double
*
or_
around text - Bold and Italic: Triple
*
or_
around text
*Italic* or _Italic_
**Bold** or __Bold__
***Bold and Italic*** or ___Bold and Italic___
3. Lists
Markdown supports ordered and unordered lists.
- Unordered Lists: Use
*
,-
, or+
followed by a space. - Ordered Lists: Use numbers followed by a period and a space.
* Unordered list item
- Another unordered list item
+ Yet another unordered list item
1. Ordered list item
2. Another ordered list item
3. Yet another ordered list item
You can also nest lists by indenting them with spaces:
1. First item
— Subitem
— Subitem
2. Second item
* Subitem
1. Sub-subitem
2. Sub-subitem
4. Links
Create links using square brackets for the link text and parentheses for the URL.
[Link text](http://www.example.com)
Reference-style links use a similar syntax but can be defined later in the document.
[Link text][1]
[1]: http://www.example.com
5. Images
Images are similar to links but include an exclamation mark (!
) before the brackets.

6. Block quotes
Create block quotes using the >
symbol followed by a space.
> This is a blockquote.
>
> It can span multiple lines.
7. Code
Inline code is created using backticks (`
). For block code, use triple backticks (```
).
`inline code`
```
This is a block of code
spanning multiple lines.
```
You can also specify the language for syntax highlighting:
```python
def hello_world():
print(“Hello, world!”
```
8. Horizontal Rules
Create horizontal rules with three or more asterisks (***
), dashes (---
), or underscores (___
).
***
---
___
9. Tables
Create tables using pipes (|
) and hyphens (-
). Colons (:
) can be used to align columns.
| Header 1 | Header 2 | Header 3 |
| — — — — — |: — — — — : | — — — — -:|
| Row 1 | Centered | Right |
| Row 2 | Content | Content |
10. Task Lists
Task lists use square brackets. An x
inside the brackets indicates a completed task.
- [x] Completed task
- [ ] Incomplete task
- [ ] Another incomplete task
Advanced Markdown Features
1. Footnotes
Footnotes are created using square brackets and a caret (^
).
Here is a footnote reference[^1].
[^1]: Here is the footnote itself.
2. Strikethrough
Use double tildes (~~
) to strikethrough text.
~~This text is struck through~~
3. HTML in Markdown
You can include raw HTML in Markdown documents for more control.
<p>This is a paragraph in HTML.</p>
4. Escaping Characters
Use a backslash (\
) to escape Markdown characters.
\* This text is not italic \*