All cheat sheets

Markdown Cheat Sheet

Markdown reference: headings, emphasis, lists, links, code, tables, and extensions.

Data Formats
markdown
formatting

Markdown turns plain text into structured documents with lightweight punctuation. CommonMark defines the core syntax, while GitHub Flavored Markdown adds tables, task lists, and other extensions used by many developer tools.

Headings and emphasis

Use one leading # through six for heading levels. Keep one space after the marker and leave blank lines around larger blocks when portability matters.

markdown
# Page title

Section title

Subsection

bold italic bold italic strikethrough

code

| Syntax | Result |
| --- | --- |
| `` `code` `` | Inline code. |
| `**text**` | Strong emphasis. |
| `*text*` | Emphasis. |
| `~~text~~` | Strikethrough in GFM. |
| `\*literal\*` | Escaped punctuation. |

Lists and tasks

Unordered lists use -, *, or +; ordered lists use a number and period. Indent nested content consistently, commonly by two or four spaces.

markdown
- Install dependencies
- Configure the app
  - Set the port
  - Set the database URL

1. Draft
2. Review
3. Publish

- [ ] Write tests
- [x] Run lint

Task-list syntax is a GFM extension and may not render as checkboxes in every Markdown engine.

Code and blockquotes

Use inline code for short tokens and fenced blocks for multi-line examples. A language tag enables syntax highlighting when the renderer supports it.

markdown
Run `pnpm test` before opening a pull request.

```python
print("Hello, Markdown")

A blockquote can contain multiple paragraphs.

— Source or attribution

code

To show a literal fence inside a fenced example, use a longer fence around it.

Tables and separators

GFM tables require a header row and a delimiter row. Colons control alignment; the separator line is also visually useful as a horizontal rule when written with three hyphens alone.

markdown
| Name | Status | Count |
| :--- | :----: | ---: |
| API  | Ready  | 12   |
| Web  | Draft  | 3    |

---

Paragraphs and breaks

A blank line starts a new paragraph. Two trailing spaces create a hard line break in many implementations, but an explicit <br> or separate paragraphs can be more maintainable depending on the renderer.

markdown
First paragraph.

Second paragraph.

Line one  
Line two

Common extensions

Footnotes, task lists, tables, and autolinks are common extensions rather than universal Markdown features. Confirm the target renderer before depending on them.

markdown
A statement with a note.[^1]

[^1]: The note text appears in the footnotes area.

https://example.com

References