This Cheat Sheet can be found at The Markdown Guide.

This Markdown cheat sheet provides a quick overview of all the Markdown syntax elements. It can’t cover every edge case, so if you need more information about any of these elements, refer to the reference guides for basic syntax and extended syntax.

For a GitHub friendly Markdown Cheat Sheet, check out GitHub’s wiki.

Basic Syntax

These are the elements outlined in John Gruber’s original design document. All Markdown applications support these elements.

Element Markdown Syntax Output

Headings

# H1

H1

## H2

H2

### H3

H3

#### H4

H4

##### H5
H5
###### H6
H6

Bold

**bold text** bold text
__bold text__ bold text

Italic

_italic text_ italic text
*italic text* italic text

Blockquote

> blockquote
blockquote

Ordered Lists

1. First item
1. Second item
1. Third item
  1. First item
  2. Second item
  3. Third item

Unordered Lists

- First item
- Second item
- Third item
  • First item
  • Second item
  • Third item

Code

`code` code

Horizonal Rule

---

Link

[link title](https://www.linkurl.com) Link title

Image

![alt text](https://picsum.photos/200 "random image") random image

Extended Syntax

These elements extend the basic syntax by adding additional features. Not all Markdown applications support these elements.

Table

Syntax:

| Element | Description |
| — | — |
| Header | Title |
| Paragraph | Text |

Output:

Element Description
Header Title
Paragraph Text

Fenced Code Block

Syntax:

```
{
  “firstName”: “John”,
  “lastName”: “Smith”,
  “age”: 25
}
```

Output:

{
  "firstName": "John",
  "lastName": "Smith",
  "age": 25
}

Footnote

Syntax:

Here’s a sentence with a footnote. [^1]

[^1]: This is the footnote.

Output:

Here’s a sentence with a footnote. 1

Heading ID

Syntax:
To get desired output in GitHub, use HTML

### My Great Heading {#custom-id}

Output:

My Great Heading

Definition List

Syntax:
To get desired output in GitHub, use HTML

First Term
: This is the definition of the first term.

Second Term
: This is one definition of the second term.
: This is another definition of the second term.

Output:

First Term
This is the definition of the first term.
Second Term
This is one definition of the second term.
This is another definition of the second term.

Strikethrough

Syntax:

~~The world is flat.~~

Output:

The world is flat.

Task List

Syntax:

- [x] Completed Task
- [ ] Incomplete Task

Output:

  • Completed Task
  • Incomplete Task

Emoji

(See also Copying and Pasting Emoji)

Syntax:

That is so funny! :joy:

Output:

That is so funny! 😂

Highlight

GitHub does not support highlighting text

Syntax:

I need to highlight these ==very important words==.

Subscript

Syntax:
To get desired output in GitHub, use HTML

H~2~O

Output:

H2O

Superscript

Syntax:
To get desired output in GitHub, use HTML

X\^2\^

Output:

X2

  1. This is the footnote. 

Posts

subscribe via RSS