Skip to main content

Menu

LEVEL 0
0/5 XP
HomeAboutTopicsPricingMy VaultStatsPractice TestsCertifications

Categories

πŸŽ“ Certifications
πŸ€– Artificial Intelligence
☁️ Cloud and Infrastructure
πŸ’Ύ Data and Databases
πŸ’Ό Professional Skills
🎯 Programming and Development
πŸ”’ Security and Networking
πŸ“š Specialized Topics
CheatGrid
HomeAboutTopicsPricingMy VaultStatsPractice TestsCertifications
LVLEVEL 0
0/5 XP
GitHub
Β© 2026 CheatGridβ„’. All rights reserved.
Privacy PolicyTerms of UseAboutContact

Markdown Cheat Sheet

Markdown Cheat Sheet

Tables
Back to Developer Tools
Updated 2026-04-28
Next Topic: Notepad++ Cheat Sheet

Markdown is a lightweight markup language created by John Gruber in 2004 for writing formatted text using plain-text editors. It's designed to be easy to read and write, converting seamlessly to HTML while remaining human-readable in its raw form. Markdown has become the de facto standard for documentation, README files, note-taking apps, static site generators, and content management systems. The CommonMark specification standardizes Markdown syntax, while GitHub Flavored Markdown (GFM) extends it with tables, task lists, strikethrough, alerts, math expressions, and Mermaid diagrams β€” features now widely adopted across development platforms.

Quick Index141Β entriesΒ Β·Β 26Β tables
Mind Map

26 tables, 141 concepts. Select a concept node to jump to its table row.

Preparing mind map...

Table 1: Headings

Headings give a document its structure, and Markdown offers two ways to write them. The hash-prefix ATX style (# through ######) is by far the most common and covers all six levels, while the older Setext style underlines text for the top two. Custom IDs let you link straight to a specific section.

SyntaxExampleDescription
ATX headings
# Heading 1
## Heading 2
### Heading 3
β€’ Use 1–6 hash symbols # followed by a space
β€’ number of hashes determines heading level (H1–H6).
Setext headings
Heading 1
=========
Heading 2
---------
β€’ Underline text with = for H1 or - for H2
β€’ alternative syntax for top two levels only.
Heading IDs
### My Heading {#custom-id}
β€’ Add custom anchor ID using {#id} syntax
β€’ enables linking directly to specific sections.

Table 2: Text Emphasis

The everyday formatting that makes prose readable β€” bold, italic, and their combination, all built from asterisks or underscores. A handful of these go beyond core Markdown: strikethrough is a GFM extension, while highlight, subscript, and superscript usually rely on extended syntax or a fall-back to raw HTML tags.

TechniqueExampleDescription
Bold
**bold text** or __bold text__
Wrap text in double asterisks ** or double underscores __ for strong emphasis.
Italic
*italic text* or _italic text_
Wrap text in single asterisks * or single underscores _ for emphasis.
Bold and italic
***bold italic*** or ___bold italic___
Use triple asterisks *** or triple underscores ___ for combined emphasis.
Strikethrough
~~strikethrough~~
β€’ Wrap text in double tildes ~~ to display crossed-out text
β€’ GFM extension.
Underline
<ins>underlined text</ins>
β€’ Use HTML <ins> tag for underlined text
β€’ no native Markdown syntax exists for underline.
Highlight
==highlighted text==
β€’ Wrap text in double equals signs == to mark/highlight
β€’ extended syntax, not universally supported.
Subscript
H~2~O or H<sub>2</sub>O
Use single tildes ~ or HTML <sub> tags for subscript text.
Superscript
X^2^ or X<sup>2</sup>
Use single carets ^ or HTML <sup> tags for superscript text.

Table 3: Paragraphs and Line Breaks

One of Markdown's most common surprises is that pressing Enter doesn't always create a new line β€” paragraphs are separated by blank lines, and a line break within a paragraph needs explicit help. These options show the three ways to force that break: trailing spaces, a backslash, or an HTML <br> tag.

ElementExampleDescription
Paragraph
First paragraph.

Second paragraph.
β€’ Separate paragraphs with a blank line
β€’ consecutive lines without blank lines merge into one paragraph.
Hard line break
First line
Second line
End a line with two or more spaces then press Enter to force a line break within a paragraph.
Line break with backslash
First line\
Second line | End a line with a backslash \ to create a hard line break; more visible alternative to trailing spaces.
HTML break tag
First line<br>Second line
Insert <br> HTML tag for explicit line breaks; works when HTML is supported.

Table 4: Lists

From simple bullets to nested hierarchies and GitHub's interactive checkboxes, lists are everywhere in Markdown. The detail that trips people up most is indentation β€” sub-items and continuation paragraphs need 4 spaces or a tab to stay attached to their parent item.

TypeExampleDescription
Unordered list
- Item 1
- Item 2
- Item 3
β€’ Start lines with -, *, or + followed by a space
β€’ use consistent markers within a list.
Ordered list
1. First
2. Second
3. Third
β€’ Start lines with a number, period . or ), and a space
β€’ numbering auto-corrects in rendered output.
Nested list
1. Item
- Sub-item
- Sub-item
β€’ Indent sub-items by 4 spaces or 1 tab to create nested lists
β€’ mix ordered and unordered.
Task list
- [ ] Unchecked
- [x] Checked
β€’ Use - [ ] for unchecked and - [x] for checked checkboxes
β€’ GFM extension; interactive on GitHub issues and PRs.
Multi-paragraph list items
1. First paragraph.

Second paragraph.
Indent continuation paragraphs by 4 spaces or 1 tab to keep them within the same list item.

Table 5: Links

Links come in more flavors than most people realize. Inline links are the workhorse, but reference-style links keep dense text readable by moving URLs out of the way, relative links keep repository docs portable across branches and forks, and autolinks turn a bare URL into a clickable one automatically.

TechniqueExampleDescription
Inline link
[Link text](https://example.com)
β€’ Wrap text in [] and URL in ()
β€’ most common link syntax.
Link with title
[Link](https://example.com "Title")
β€’ Add optional title attribute in quotes after URL
β€’ shows on hover.
Reference-style link
[Link][ref]
[ref]: https://example.com
β€’ Define link reference separately
β€’ keeps text clean and readable.
Relative link
[Contributing](docs/CONTRIBUTING.md)
β€’ Link to files relative to the current file
β€’ preferred over absolute links inside repositories.
Autolink
<https://example.com>
Wrap URL or email in <> to create automatic clickable link.
Autolink literals
https://example.com
GFM automatically converts bare URLs to clickable links without angle brackets.
Email link
<email@example.com>
Wrap email address in <> to create mailto link.
Anchor link
[Link](#heading-id)
β€’ Link to headings using # followed by auto-generated or custom ID
β€’ creates internal page navigation.

Table 6: Images

Image syntax mirrors link syntax with a leading !, and the same reference-style and relative-path tricks apply. Two practical notes stand out: always write meaningful alt text for accessibility, and because Markdown can't resize images, reach for a raw <img> tag when you need to control width.

TechniqueExampleDescription
Inline image
![Alt text](image.jpg)
β€’ Use ! before link syntax
β€’ alt text describes image for accessibility and appears if image fails.
Image with title
![Alt](image.jpg "Title")
β€’ Add optional title attribute in quotes
β€’ displays as tooltip on hover.
Reference-style image
![Alt][img-ref]
[img-ref]: image.jpg
Define image reference separately for reusability and cleaner text.
Linked image
[![Alt](image.jpg)](https://example.com)
Wrap image syntax in link syntax to make image clickable.
HTML image with sizing
<img src="image.jpg" alt="Alt" width="300">
β€’ Use HTML <img> tag to control image dimensions
β€’ Markdown has no native sizing syntax.
Relative path image
![Alt](./assets/img.png)
β€’ Reference images using relative paths to the current file
β€’ preferred for repository images.

Table 7: Code

Showing code is one of Markdown's most-used jobs. Single backticks handle inline snippets, while fenced blocks with triple backticks wrap whole listings β€” and adding a language identifier after the opening fence unlocks syntax highlighting. The older indented-block style still works but fenced code is almost always the better choice.

TypeExampleDescription
Inline code
`code`
Wrap text in single backticks ` for inline code within text.
Inline code with backticks
`` code with `backtick` ``
Use double backticks to include a literal backtick inside inline code.
Fenced code block
```
code line 1
code line 2
```
β€’ Wrap code in triple backticks ``` or tildes ~~~
β€’ cleaner than indenting; supports syntax highlighting.
Syntax highlighting
```python
def hello():
print("Hello")
```
β€’ Add language identifier after opening fence
β€’ enables syntax highlighting for that language.
Indented code block
code line 1
code line 2
β€’ Indent every line by 4 spaces or 1 tab to create a code block (legacy style
β€’ prefer fenced).

Table 8: Blockquotes

A leading > turns a line into a quote, useful for citing sources or setting text apart. Blockquotes can span multiple paragraphs, nest several levels deep, and even contain other Markdown like headings and lists.

TechniqueExampleDescription
Basic blockquote
> This is a quote.
Start line with > followed by a space to create a blockquote.
Multi-paragraph blockquote
> First paragraph.
>
> Second paragraph.
Add > on blank lines between paragraphs to keep them in the same blockquote.
Nested blockquote
> Level 1
>> Level 2
Use additional > symbols to create nested blockquotes.
Blockquote with other elements
> ### Heading
> - List item
Blockquotes can contain headings, lists, code, and other Markdown elements.

Table 9: Horizontal Rules

A horizontal rule draws a divider line to separate sections of a document. Three or more hyphens, asterisks, or underscores on their own line all produce the same thematic break β€” pick whichever you find most readable in the raw source.

SyntaxExampleDescription
Three hyphens
---
Use three or more hyphens - on a line by themselves to create a horizontal rule.
Three asterisks
***
Use three or more asterisks * for a horizontal divider.
Three underscores
___
Use three or more underscores _ for a thematic break.

Table 10: Tables

Tables are a GFM extension built from pipes and hyphens, with a separator row defining the header. Colons in that separator control column alignment β€” left, center, or right β€” and an HTML entity lets you slip a literal pipe character into a cell without breaking the structure.

ElementExampleDescription
Basic table
| H1 | H2 |
|----|----|
| A | B |
β€’ Use pipes | to separate columns and hyphens - to create header row
β€’ GFM extension.
Left alignment
| :--- |
Add colon : on the left side of hyphens in header row to left-align column.
Center alignment
| :---: |
Add colons : on both sides of hyphens to center-align column.
Right alignment
| ---: |
Add colon : on the right side of hyphens to right-align column.
Pipe in table cell
| A | B |
β€’ Use HTML entity &#124<br>&bull; to display a literal pipe character inside a table cell.

Table 11: Escaping Characters

Sometimes you want a character that Markdown treats as syntax to show up literally β€” an asterisk that isn't italics, or a backtick that isn't code. A backslash before the character escapes it, and wrapping symbols in backticks is an alternative that displays them verbatim.

TechniqueExampleDescription
Backslash escape
\*not italic\*
Use backslash \ before special characters to display them literally instead of formatting. |
Escapable characters
\ ` * _ {} [] () # + - . ! | | These ASCII punctuation characters can be escaped with a backslash. |
Inline code for symbols
`*`
Wrap symbols in backticks to display them literally without escaping.

Table 12: HTML Embedding

When Markdown alone can't do what you need, you can drop raw HTML right into the document. This unlocks features with no native syntax β€” styled spans, collapsible <details> sections, and hidden comments β€” though block-level HTML needs blank lines around it to render correctly.

TechniqueExampleDescription
Inline HTML
This is <mark>highlighted</mark> text.
β€’ Insert HTML tags directly into Markdown
β€’ works for features Markdown doesn't support natively.
HTML block
<div style="color: red;">
Red text
</div>
β€’ Use block-level HTML elements for advanced formatting
β€’ must be separated by blank lines.
Collapsible section
<details>
<summary>Toggle</summary>

Hidden content

</details>
β€’ Use <details> and <summary> HTML elements for collapsible sections
β€’ add blank lines before/after Markdown inside.
Comments
<!-- This is a comment -->
Use HTML comment syntax <!-- --> to add hidden notes that won't appear in output.

Table 13: YAML Front Matter

Front matter is a YAML block fenced by triple dashes at the very top of a file, carrying metadata about the document rather than its content. Static site generators and tools like Pandoc, Jekyll, and Hugo read these fields β€” title, author, date, tags β€” to drive page titles, exports, and site behavior, and you can add arbitrary custom keys for your own tooling.

ElementExampleDescription
Front matter block
---
title: My Document
author: Jane Doe
---
β€’ Place YAML block at the very start of a file between triple dashes ---
β€’ provides document-level metadata consumed by tools like Pandoc, Jekyll, Hugo.
title field
title: "My Post Title"
Sets the document title used in exports, page <title>, and table-of-contents generation.
author field
author:
- Jane Doe
- John Smith
β€’ Specifies document authors
β€’ accepts a string or list
β€’ used in PDF/DOCX title pages via Pandoc.
date field
date: 2026-04-28
β€’ Sets the document date
β€’ used in rendered output such as PDF/DOCX and by static site generators.
tags / keywords
tags: [markdown, docs]
β€’ Specifies searchable tags or keywords
β€’ recognized by Obsidian, Zettlr, and many static site generators.
lang field
lang: en-US
Sets document locale for Pandoc exports β€” controls quotation marks, citation style, and punctuation.
custom fields
draft: true
weight: 10
β€’ Any arbitrary key-value pair
β€’ consumed by the site generator or tooling that processes the file.

Table 14: Extended Syntax β€” Footnotes

Footnotes let you attach a reference marker in your text to a note that renders at the bottom of the page β€” invaluable for citations and asides in long-form writing. You place the [^id] marker inline and define its content separately, using either numbers or word labels, and a footnote can even span multiple indented paragraphs.

ElementExampleDescription
Footnote reference
Here is a footnote[^1].
Add [^number] or [^label] to create a superscript footnote reference.
Footnote definition
[^1]: Footnote content.
β€’ Define footnote content anywhere in document using [^number]: followed by text
β€’ renders at bottom.
Named footnote
Here[^note].
[^note]: Named ref.
β€’ Use a word label instead of a number
β€’ still renders as sequential number in output.
Multi-paragraph footnote
[^1]: First paragraph.

Second paragraph.
Indent continuation paragraphs by 4 spaces to include multiple paragraphs in a footnote.

Table 15: Extended Syntax β€” Definition Lists

Definition lists pair a term with one or more definitions β€” the format you'd use for a glossary. The definition line starts with a colon, and a single term can carry several definitions. It's an extended-syntax feature, so not every parser supports it.

ElementExampleDescription
Definition list
Term
: Definition
β€’ Create term-definition pairs by starting definition line with : followed by spaces
β€’ extended syntax, not in CommonMark.
Multiple definitions
Term
: Definition 1
: Definition 2
A single term can have multiple definitions listed on separate lines.

Table 16: Extended Syntax β€” Abbreviations

Define an abbreviation once and every occurrence of it in the document gets a hover tooltip spelling out the full term β€” handy for keeping acronym-heavy technical docs readable. It's an extended-syntax feature supported by parsers like Python-Markdown.

TechniqueExampleDescription
Abbreviation definition
*[HTML]: Hyper Text Markup Language
β€’ Define abbreviations using *[abbr]: definition
β€’ creates tooltip on hover showing full text wherever that abbreviation appears.

Table 17: Extended Syntax β€” Emoji

There are two ways to get emoji into Markdown: type a shortcode like :rocket: that the platform converts, or paste the actual Unicode character. Shortcodes are convenient but their names vary between platforms, whereas pasted Unicode emoji work everywhere.

MethodExampleDescription
Emoji shortcode
:smile: :+1: :rocket:
β€’ Type emoji names between colons :: to insert emojis
β€’ shortcode names vary by platform.
Unicode emoji
πŸ˜€ πŸ‘ πŸš€
β€’ Copy and paste actual emoji characters directly into Markdown
β€’ works universally across platforms.

Table 18: Math Expressions

Many platforms now render LaTeX math inside Markdown via MathJax or KaTeX β€” single dollar signs for inline expressions, double for centered display blocks. The rest of the entries are a quick LaTeX primer for the notation you'll reach for most: fractions, roots, summations and integrals, and Greek letters.

SyntaxExampleDescription
Inline math
$E = mc^2$
Wrap expression in single dollar signs $...$ for inline math rendered by MathJax or KaTeX.
Display math (block)
$$
\sum_{k=1}^n a_k
$$
Wrap expression in double dollar signs $$...$$ on its own line for centered block math.
Code-fence math block
```math
\int_0^1 x^2 dx
```
GitHub also supports a ```math fenced block as an alternative to $$ for display math.
Inline math (backtick delimiter)
$`\sqrt{3x-1}`$
GitHub alternate inline syntax using $`...`$ to avoid conflicts with dollar-sign currency.
Fractions
$\frac{a}{b}$
Use \frac{numerator}{denominator} for fraction notation.
Square root
$\sqrt{x^2 + y^2}$
β€’ Use \sqrt{expr} for square roots
β€’ \sqrt[n]{expr} for nth roots.
Summation / integral
$\sum_{i=1}^{n} x_i$
Use \sum, \int, \prod with subscript/superscript bounds for series and integrals.
Greek letters
$\alpha \beta \gamma \pi$
LaTeX commands \alpha, \beta, \Gamma, \pi, etc. render Greek letter symbols.

Table 19: Mermaid Diagrams

Mermaid lets you describe diagrams as plain text inside a fenced code block, and platforms like GitHub, GitLab, and Obsidian render them as real graphics. It's a remarkably versatile toolkit β€” the diagram types here range from flowcharts and sequence diagrams to Gantt charts, class and ER diagrams, pie charts, and state machines.

TypeExampleDescription
Flowchart
```mermaid
flowchart TD
A[Start] --> B{Yes?}
```
β€’ Declare flowchart TD (top-down) or LR (left-right)
β€’ rendered in GitHub, GitLab, VS Code, Obsidian, and more.
Sequence diagram
```mermaid
sequenceDiagram
Alice->>Bob: Hello
```
β€’ Shows message flow between actors
β€’ uses ->> for arrows, Note over for annotations.
Gantt chart
```mermaid
gantt
section Phase1
Task :a1, 2024-01-01, 7d
```
Renders project timeline with tasks, sections, and dependencies.
Class diagram
```mermaid
classDiagram
Animal <|-- Dog
```
Models OOP class relationships with inheritance, composition, and interfaces.
Entity relationship diagram
```mermaid
erDiagram
CUSTOMER ||--o{ ORDER : places
```
Defines database entity relationships using ERD notation with cardinality symbols.
Pie chart
```mermaid
pie title Pets
"Dogs" : 40
"Cats" : 60
```
Renders a labeled pie chart from simple key-value pairs.
State diagram
```mermaid
stateDiagram-v2
Idle --> Active : click
```
Models finite state machines with states, transitions, and fork/join nodes.

Table 20: GitHub Flavored Markdown (GFM) Extensions

These are GitHub-specific niceties that only work within GitHub itself. Typing @username pings a person, #123 links to an issue, and a pasted commit SHA becomes a link β€” small touches that make conversations in issues and PRs flow. Note that GFM also strips certain raw HTML tags for security.

FeatureExampleDescription
Username mentions
@username
β€’ Type @username to mention a GitHub user or team
β€’ triggers a notification and creates a profile link.
Issue references
#123
Type # followed by issue number to link to GitHub issues or pull requests.
Color model display
`#0969DA` `rgb(9,105,218)`
β€’ Backtick-wrapped hex, RGB, or HSL color values render a color swatch preview
β€’ only in issues, PRs, and discussions.
Commit SHA references
16c999e8c71134401a78d4d46435517b2271d6ac
Paste full commit SHA to auto-create a link to that commit.
Disallowed raw HTML
Filters <title> <script> <style> etc.
β€’ GFM restricts certain HTML tags for security
β€’ they're rendered as plain text.

Table 21: GitHub Alerts (Callouts)

Alerts are colored callout boxes that draw the eye to something important. Built on blockquote syntax with a [!TYPE] marker, the five flavors each carry their own color and tone β€” from a neutral blue NOTE up to a red CAUTION warning of real risk β€” so readers can gauge severity at a glance.

TypeExampleDescription
NOTE alert
> [!NOTE]
> Useful information.
β€’ Displays a blue info box
β€’ use for general information users should know.
TIP alert
> [!TIP]
> Helpful advice.
β€’ Displays a green tip box
β€’ use for optional advice that helps users do things better.
IMPORTANT alert
> [!IMPORTANT]
> Key information.
β€’ Displays a purple box
β€’ use for information critical to achieving a goal.
WARNING alert
> [!WARNING]
> Urgent info.
β€’ Displays a yellow/orange box
β€’ use for urgent information needing immediate attention.
CAUTION alert
> [!CAUTION]
> Risky action.
β€’ Displays a red box
β€’ advises about risks or negative outcomes of certain actions.

Table 22: Markdown Variants and Flavors

There's no single Markdown β€” the original spec left gaps, and different communities filled them in different ways. CommonMark is the unambiguous baseline most tools now follow, GFM is the dominant developer dialect, and the rest (Pandoc, MultiMarkdown, MDX, and others) each add features for academic writing, document conversion, or interactive React components.

VariantExampleDescription
CommonMark
Standard specification
β€’ Unambiguous Markdown specification resolving inconsistencies in original Markdown
β€’ widely adopted as baseline by most tools.
GitHub Flavored Markdown
GFM
β€’ GitHub's extension adding tables, task lists, strikethrough, autolinks, alerts, math, and Mermaid
β€’ most popular developer flavor.
GitLab Flavored Markdown
GLFM
GitLab's superset of GFM adding math, diagrams, color chips, multiline blockquotes, and GitLab-specific references.
Markdown Extra
PHP Markdown Extra
Extends Markdown with footnotes, definition lists, tables, fenced code blocks, and abbreviations.
Pandoc Markdown
Pandoc flavor
Pandoc's extensive extension set including superscript, subscript, LaTeX math, YAML metadata blocks, and citations.
MultiMarkdown
MMD
Adds metadata, tables, footnotes, citations, math for academic and long-form writing.
MDX
Markdown + JSX
β€’ Combines Markdown with JSX/React components
β€’ used in Next.js, Docusaurus, and Astro for interactive documentation.

Table 23: Best Practices

Markdown that renders correctly isn't always Markdown that's pleasant to maintain. These habits β€” blank lines around headings, consistent list markers, fenced code over indented, alt text on every image, and semantic line breaks for cleaner diffs β€” keep your source readable and portable across the widest range of parsers.

PracticeExampleDescription
Blank lines around headings
text

# Heading

text
Put blank lines before and after headings for maximum compatibility and readability.
Consistent list markers
Use - consistently
Stick to one bullet character (-, *, or +) throughout a document for unordered lists.
Fenced code over indented
Use ``` instead of indents
Prefer fenced code blocks with triple backticks; clearer and supports syntax highlighting.
Reference links for readability
[text][ref] at end
Use reference-style links when text has many links; keeps source readable.
Alt text for images
![Descriptive alt text](img.jpg)
Always provide meaningful alt text for images; critical for accessibility and SEO.
Semantic line breaks
Break at sentence/clause
Breaking lines at sentence or clause boundaries improves version control diffs.
Relative links in repos
[Docs](./docs/guide.md)
Use relative links for files within a repository so links work across branches and forks.
Avoid hard wrapping
Let editors wrap
Let text editors handle soft wrapping; hard wrapping at arbitrary column widths creates maintenance issues.

Table 24: Common Pitfalls and Gotchas

The subtle traps that make Markdown "not render right" β€” and they catch experienced writers too. A missing blank line before a list, too-shallow nested indentation, underscores triggering accidental italics inside snake_case, blank lines breaking a table, or a dollar sign mistaken for math: knowing these failure modes saves a lot of confused debugging.

IssueExampleDescription
Missing blank line before list
text
- list won't render
Lists require a blank line before them when following a paragraph in many parsers.
Incorrect nested list indentation
- Item
- Wrong
β€’ Nested lists need 4 spaces or 1 tab indentation
β€’ 1–2 spaces may silently fail in strict parsers.
Underscore in words
snake_case_variable
β€’ Underscores within words can trigger unintended italics
β€’ use asterisks or code formatting instead.
Trailing spaces for line breaks
Not visible in editors
Two trailing spaces are invisible; consider using backslash \ or <br> for clarity. |
Ordered list auto-numbering
1. First
1. Second renders as 1, 2
β€’ Markdown auto-corrects list numbers
β€’ using 1. for all items is valid but explicit numbering is clearer.
Inconsistent empty lines in tables
Tables break with empty lines
β€’ Table rows must be consecutive
β€’ blank lines terminate the table.
Math dollar sign conflict
$50 items may trigger math
β€’ Dollar signs used as currency can conflict with inline math delimiters
β€’ escape with \$50 or use <span>$</span>50.
HTML in list items
Requires careful spacing
HTML elements in lists need proper indentation and blank lines or they break list structure.
Markdown inside HTML blocks
<div>**bold**</div> fails
Markdown formatting does not process inside HTML block elements β€” add blank lines around Markdown content within HTML.

Table 25: Advanced Techniques

Once you're comfortable with the basics, these techniques squeeze more out of the syntax β€” collapsed reference links, definitions placed anywhere in the file, lazy blockquote continuation, hand-built tables of contents from heading anchors, and Obsidian-style wikilinks. They're the touches that separate workmanlike Markdown from genuinely polished documents.

TechniqueExampleDescription
Nested formatting
***bold and italic***
Combine multiple emphasis markers for layered formatting effects.
Collapsed reference links
[GitHub][]
[GitHub]: https://github.com
β€’ Omit reference label when link text matches reference
β€’ shorthand syntax.
Link reference definitions anywhere
[text][ref]
[ref]: url at bottom
β€’ Reference definitions can be placed anywhere in document
β€’ commonly at end for organization.
Blockquote continuation
> Line 1 continues
on this line
Markdown allows lazy continuation of blockquotes without > on each wrapped line.
Mixing HTML with Markdown
<div>

**Markdown** works here

</div>
Markdown inside HTML blocks requires blank lines around the Markdown content.
Raw URLs in angle brackets
<https://example.com>
Angle brackets ensure URLs with special chars are recognized as links.
Table of contents via anchor links
[Intro](#introduction)
β€’ Manually create a TOC using heading anchors
β€’ GitHub/GitLab auto-generate heading IDs from heading text.
Wikilinks (Obsidian-style)
[[Note Name]]
Obsidian and some platforms support double-bracket internal links to other notes by filename.

Table 26: Editor and Tool Support

Markdown's reach comes from its ecosystem. This roundup spans the tools you'll actually write and ship with β€” VS Code and Typora for editing, Obsidian for linked notes, Pandoc for converting to anything, and static site generators like Jekyll, Hugo, and Quarto for publishing β€” so you can match the right tool to whether you're taking notes, building docs, or producing scientific output.

ToolExampleDescription
VS Code Markdown Preview
Built-in preview
β€’ Side-by-side preview with syntax highlighting
β€’ extensive extension ecosystem including Mermaid, math, and linting.
Obsidian
Note-taking app
Knowledge base tool with bidirectional wikilinks, graph view, callouts, math, and Markdown-first approach.
Typora
WYSIWYG editor
β€’ Live preview editor that hides Markdown syntax while typing
β€’ seamless WYSIWYG experience.
Pandoc
Document converter
Universal converter supporting Markdown to/from dozens of formats including PDF, DOCX, HTML, and EPUB.
Material for MkDocs
Documentation site
β€’ Documentation theme with admonitions, tabs, grids, math, and Mermaid support
β€’ widely used for open-source project docs.
HackMD / CodiMD
Collaborative editor
Real-time collaborative Markdown editing with math, Mermaid, presentation mode, and multi-user support.
Zettlr
Research writing
Academic Markdown editor with YAML front matter, Pandoc citations, Zotero integration.
Jekyll
Static site generator
β€’ Blog-aware static site generator using Markdown for content
β€’ powers GitHub Pages.
Hugo
Fast static generator
Extremely fast static site generator with Markdown support, Mermaid, math, and rich theming.
Quarto
Scientific publishing
β€’ Publishing system built on Pandoc supporting executable code, math, Mermaid, and cross-references
β€’ used in data science and academia.
Back to Developer Tools
Next Topic: Notepad++ Cheat Sheet

More in Developer Tools

  • Linear Project Management for Engineering Teams Cheat Sheet
  • Notepad++ Cheat Sheet
  • AI-LLM Code Generation Cheat Sheet
  • Docker Desktop for Developers Cheat Sheet
  • Jupyter Notebooks Cheat Sheet
  • Sublime Text Cheat Sheet
View all 55 topics in Developer Tools

References

Official Documentation

  1. CommonMark Specification (Current Version 0.31.2)
  2. GitHub Flavored Markdown Spec
  3. Original Markdown Syntax by John Gruber
  4. Markdown Guide - Basic Syntax
  5. Markdown Guide - Extended Syntax
  6. Markdown Guide - Cheat Sheet
  7. Markdown Guide - Best Practices and Hacks
  8. Python Markdown Extensions Documentation
  9. Pandoc Markdown Manual
  10. Pandoc YAML Metadata Blocks
  11. MultiMarkdown Documentation
  12. GitHub - Basic Writing and Formatting Syntax
  13. GitHub - Writing Mathematical Expressions
  14. GitHub - Creating and Highlighting Code Blocks
  15. GitHub - Organizing Information with Tables
  16. GitHub - Organizing Information with Collapsed Sections
  17. GitHub - Autolinked References and URLs
  18. GitHub - Alerts (Callouts) Documentation
  19. GitLab Flavored Markdown (GLFM)
  20. KaTeX Supported Functions
  21. KaTeX Documentation
  22. MathJax Documentation
  23. MathJax TeX and LaTeX Support
  24. Mermaid.js Official Documentation
  25. Mermaid Diagram Syntax Reference
  26. Mermaid Flowchart Syntax
  27. Mermaid Sequence Diagram Syntax
  28. Mermaid Gantt Chart Syntax
  29. Mermaid Class Diagram Syntax
  30. Mermaid ER Diagram Syntax
  31. MDX Official Documentation
  32. CommonMark - Official Website
  33. Quarto Markdown Basics
  34. Quarto Tables
  35. R Markdown: The Definitive Guide
  36. MyST Markdown - Glossaries and Terms
  37. Jupyter Notebook Markdown
  38. Obsidian Internal Links (Help)
  39. Obsidian Advanced Syntax Help

Technical Blogs & Tutorials

  1. Markdown Cheat Sheet (2026) - md2word.com
  2. KaTeX Math in Markdown - Unmarkdown Blog
  3. Markdown Syntax & Features: A Comprehensive 2025 Guide - DEV Community
  4. GitHub Flavored Markdown: Task Lists, Alerts, Footnotes - The Product Guy
  5. How to Use Mermaid in Markdown Documents - Medium
  6. GitHub Markdown Shortcuts - Lickability
  7. Markdown Syntax Complete Guide 2026 - Qubit Tool
  8. The Markdown Cheat Sheet You'll Actually Use - Unmarkdown Blog
  9. Markdown Best Practices - Microsoft FluidFramework Wiki
  10. Markdown Documentation Best Practices - IBM Community
  11. Markdown "Best Practices" - CommonMark Discussion
  12. Best Practices and Tips in Markdown - Technical Writing MP
  13. Markdown Guide - iA Writer
  14. The Ultimate Guide to Writing & Publishing with Markdown - Ghost
  15. Markdown Style Guide - Google Developer Documentation Style Guide
  16. How to Use Markdown in VSCode - freeCodeCamp
  17. Markdown for Note-Taking Complete Beginner's Guide 2025 - Luma
  18. Creating Instructions with Markdown Syntax - Skillable
  19. Markdown Reference Guide - Fuchsia
  20. Mathematics in Markdown - Hugo
  21. Math - Material for MkDocs
  22. Admonitions - Material for MkDocs
  23. Icons, Emojis - Material for MkDocs
  24. Math Rendering (re-visited) - CommonMark Discussion
  25. The Best Way to Support LaTeX Math in Markdown with MathJax - Yihui
  26. New Alerts Extension on GitHub Markdown - MkDocs Material Discussion
  27. Collapsible Markdown on GitHub - DEV Community

GitHub Resources & Code Examples

  1. adam-p/markdown-here Markdown Cheatsheet
  2. Complete List of GitHub Markdown Emoji Markup
  3. ikatyang/emoji-cheat-sheet - GitHub
  4. GitHub Flavored Markdown Cheat Sheet
  5. Using details/summary Expandable Content on GitHub
  6. How to Add a Collapsible Section in Markdown
  7. GitHub Markdown Heading Anchors
  8. HTML Tags You Can Use on GitHub
  9. remarkjs/remark-gfm - GitHub
  10. micromark/micromark-extension-gfm - GitHub
  11. Mermaid Chart Extension for VS Code - GitHub
  12. rehype-github-alerts - rehype Plugin for Alerts
  13. Kernix13/markdown-cheatsheet - Comprehensive Guide
  14. jonschlinkert/markdown-toc - TOC Generator
  15. hukkin/mdformat - CommonMark Compliant Formatter

Stack Overflow & Community Resources

  1. Comments in Markdown - Stack Overflow
  2. Cross-reference (named anchor) in Markdown - Stack Overflow
  3. How to apply color on text in Markdown - Stack Overflow
  4. Text highlight in Markdown - Stack Overflow
  5. How to insert a line break in Markdown - Stack Overflow
  6. Markdown and line wrapping - Stack Overflow
  7. Markdown list indentation with 3 or 4 spaces - Stack Overflow
  8. How to write nested numbered lists - Meta Stack Exchange
  9. Left-align headers in Markdown table - Stack Overflow
  10. How to write superscript and subscript in Markdown - Stack Overflow
  11. Get underlined text with Markdown - Stack Overflow
  12. GitHub Flavored Markdown: How to make a styled admonition box - Stack Overflow
  13. How to render a Markdown file with LaTeX inline math - TeX Stack Exchange
  14. Markdown to create pages and table of contents? - Stack Overflow

CommonMark Discussion Forum

  1. Anchors in Markdown - CommonMark Discussion
  2. Abbreviations (and acronyms) - CommonMark Discussion
  3. Default line break handling - CommonMark Discussion
  4. Nested ordered lists indented with 2 spaces - CommonMark Discussion
  5. Preserve tabs in code blocks - CommonMark Discussion
  6. Current rule on backslash escapes - CommonMark Discussion
  7. How to show generic email address without hyperlink - CommonMark Discussion

Markdown Tools & Extensions

  1. VS Code Markdown All in One Extension - Visual Studio Marketplace
  2. Auto Markdown TOC - Visual Studio Marketplace
  3. Markdown Preview Mermaid Support - Visual Studio Marketplace
  4. Generate Table of Contents for Markdown Online - BitDownToc
  5. Markdown Table Formatter - Finite Field
  6. MarkdownTOC - Package Control
  7. Fenced Code Blocks - Python-Markdown Extension
  8. Abbreviations - Material for MkDocs
  9. Markdown Tables Generator
  10. Markdown Live Preview with Cheat Sheet

Academic & Specialized Markdown

  1. Quarto Inline Code
  2. R Markdown Cookbook - Escape Special Characters
  3. MyST Markdown - Frontmatter
  4. Escape Special Characters - R Markdown Cookbook

Documentation Platforms

  1. GitLab Flavored Markdown (GLFM)
  2. Markdown Syntax - JetBrains Hub
  3. Advanced Formatting Syntax - Obsidian Help
  4. Formatting text with Markdown - Zendesk
  5. Markdown Text 101 - Discord
  6. Markdown Quick Reference - WordPress.com Support
  7. Markdown for Hugo - Emojis
  8. YAML Front Matter - Zettlr User Manual
  9. Using YAML frontmatter - GitHub Docs
  10. Frontmatter - Zuplo Docs
  11. Frontmatter - Markdoc
  12. Content Frontmatter Options - MyST Markdown

WordPress and CMS Resources

  1. PHP Markdown Extra
  2. Markdown Extra Syntax - UM Catalog

Specific Feature Tutorials

  1. Markdown Tutorial - Code - CommonMark
  2. Markdown Tutorial - Lists - CommonMark
  3. Markdown Tutorial - Nested Lists - CommonMark
  4. Markdown Tutorial - Blockquotes - CommonMark
  5. CommonMark Reference - Help
  6. Links and Footnotes in Markdown - Infinite Ink
  7. Markdown Footnotes Guide - Tiiny.host
  8. Tables, Block quotes and Horizontal Lines - Markdown Intro
  9. Mermaid Diagram: A Complete Guide to Diagrams as Code in 2026
  10. The Essential Guide to Mermaid Chart Plugin for VS Code

Blog Posts and Articles

  1. Markdown's Gentle Encouragement Towards Accessible Images
  2. Markdown Image Titles and Alt Text - DEV Community
  3. Superscript And Subscript With Markdown - DEV Community
  4. Complete Markdown guide - Medium
  5. The Ultimate Markdown Cheat Sheet - Medium
  6. Markdown Codeblocks - Cheatsheet and Examples - Medium
  7. The Ultimate Guide to Markdown - Medium
  8. Learn How Markdown Links Work - Medium
  9. MDX: Markdown for the Component Era - Docsie Glossary
  10. A Guide to Markdown on Discord
  11. Add Markdown Callouts/Alerts/Admonitions - Meta Stack Exchange
  12. Markdown parser feature comparison - Ditig

Additional Resources

  1. How to Link to Headings in Markdown - simonewebdesign
  2. 4 + 1 wrapping styles for Markdown - MTSknn
  3. Hard vs. Soft Line Wrap - Martin Ueding
  4. To Wrap or Not to Wrap in Markdown - code.dblock.org
  5. Indentation in Markdown - Manski's Dev Log
  6. Line Break in Markdown - Szymon Krajewski
  7. Markdown Code Style Settings - PhpStorm
  8. How to Write Code Blocks and Inline Code in Markdown - Mike F Robbins

Video Resources

  1. Getting Started with Markdown on GitHub - YouTube
  2. How To Write Markdown In Notion - YouTube
  3. Markdown Tips - Auto-links for URLs and Email - YouTube
  4. Markdown Tips - Adding code samples with syntax highlighting - YouTube
  5. Visual Studio 2026 New Features - Mermaid Chart Rendering - YouTube
  6. Mermaid Charts in Visual Studio 2026 - YouTube

History and Standardization

  1. Markdown - Wikipedia
  2. CommonMark: A Formal Specification For Markdown - Smashing Magazine
  3. How we migrated to CommonMark - GitLab Blog
  4. We're switching to CommonMark - Meta Stack Exchange
  5. CommonMark only wants to help - David Zych

Style Guides

  1. Markdown | Emojis - Codecademy
  2. Markdown | Links - Codecademy
  3. Markdown | Tables - Codecademy
  4. Markdown | Blockquotes - Codecademy
  5. Emphasis - Markdown - Codecademy

Extended Markdown Discussions

  1. Extended Markdown Syntax - Tables, Footnotes, Task Lists
  2. Markdown Tables - Alignment, Formatting, Best Practices
  3. The Dead Simple Markdown Guide to Escaping Characters - HackerNoon
  4. Markdown Styling: Bold, Italic, Strikethrough - Eddie's Log