ToolMelt

Markdown Cheat Sheet

Markdown cheat sheet with syntax vs result tables: headings, bold, lists, links, code blocks, GFM tables, task lists and footnotes, plus 5 copy-ready snippets.

This guide pairs with a free tool:

Open the Markdown Preview

Markdown is the plain-text formatting syntax behind READMEs, docs, wikis, forum posts and chat apps. This markdown cheat sheet covers the syntax you reach for every day — headings, emphasis, lists, links, images and code, plus the GitHub Flavored Markdown (GFM) extras like tables and task lists — with rendered results, five copy-ready snippets and the gotchas that silently break layouts.

Basic syntax: what you type vs what you get

You typeYou get
# HeadingTop-level heading; # through ###### give six levels in total
**bold**bold — two underscores work too
*italic*italic — single underscores also work
***bold italic***bold italic
~~strikethrough~~strikethrough — a GFM extension, not part of original Markdown
- itemBulleted list; * and + are equivalent markers
1. itemNumbered list; indent nested items to align with the parent's text
[text](https://example.com)A clickable link — add "title" after the URL for a hover tooltip
![alt](image.png)An embedded image; the alt text appears if the image can't load

Headings need a space after the hashes — #Title stays plain text in most parsers. For a hard line break inside a paragraph, end the line with two spaces; a single Enter usually collapses into a space.

Code and blockquotes

Inline code

Wrap short code in single backticks: typing `const x = 1;` renders as const x = 1; in a monospace span. If the code itself contains a backtick, wrap the whole thing in double backticks instead.

Fenced code blocks

```js
function greet(name) {
  return "Hello, " + name;
}
```

Three backticks (tildes work too) open and close the block. The language tag right after the opening fence — js, python, bash — switches on syntax highlighting in renderers that support it.

Blockquotes

Start a line with > to quote it: > cited text. Use >> for a quote nested inside another. Blockquotes can hold other Markdown, including lists and code blocks.

GFM extensions: tables, task lists, rules, footnotes

Tables

Markdown table syntax uses pipes for the columns and a mandatory separator row of hyphens under the header. Colons in that separator set the alignment: :--- left, :---: center, ---: right.

| Name  | Role |  Score |
| :---- | :--: | -----: |
| Ada   | Dev  |     98 |
| Grace | Ops  |     91 |

The outer pipes are optional, but keeping them makes the source easier to scan. A pipe inside a cell's content must be escaped as \|.

Task lists

Inside a list, [ ] renders an empty checkbox and [x] a checked one. On GitHub these become real checkboxes in issues and pull requests:

- [x] Ship the parser
- [x] Write the docs
- [ ] Profit

Horizontal rules

Three or more hyphens, asterisks or underscores on their own line — ---, *** or ___ — render a horizontal rule. Keep blank lines around a hyphen rule so the line above isn't swallowed into a heading (the older Setext underline syntax).

Footnotes

Mark a spot with [^1] and define the note anywhere with [^1]: your note text. Renderers collect the definitions into a numbered list at the bottom of the page, with jump links in both directions.

Five copy-ready snippets

1. README badge

![status: stable](https://img.shields.io/badge/status-stable-brightgreen)

The Shields.io static badge pattern is badge/LABEL-MESSAGE-COLOR — swap the three parts to taste.

2. Table with alignment

| Feature | Free |  Pro |
| ------- | :--: | ---: |
| Users   | 1    |   10 |
| Support | —    | 24/7 |

3. Task list

- [x] Outline the post
- [x] Draft the sections
- [ ] Add screenshots
- [ ] Publish

4. Collapsible details

<details>
<summary>Build log (click to expand)</summary>

All 42 tests passed in 3.2 s.
</details>

Raw HTML like this works inside Markdown on GitHub and many other renderers. Leave the blank line after the <summary> tag, or the content inside won't be parsed as Markdown.

5. Clickable image

[![Chart of weekly active users](chart.png)](https://example.com/report)

The whole image syntax nests inside the link's text slot — the brackets of the image sit exactly where the link text would go.

Common gotchas

Paste any of the examples above into the Markdown Preview editor and watch the HTML render live as you type — it runs entirely in your browser, so nothing you write is uploaded.

More guides