MarkdownViewer

Markdown Bold and Italic: The Exact Syntax

Bold and italic are the two emphasis styles in Markdown, and both are written with asterisks (or underscores). The syntax is tiny, but a few patterns — asterisks inside words, mismatched markers, too many asterisks — cause output that does not look like what you typed.

The syntax

  1. Bold — `**bold**` or `__bold__`
  2. Italic — `*italic*` or `_italic_`
  3. Bold italic — `***both***`
  4. Strikethrough (GFM) — `~~struck~~`

Asterisks or underscores?

Both work, but asterisks are safer. Underscores are only treated as emphasis at word boundaries in many parsers, so `snake_case_word` stays literal, while `*` never appears in ordinary words. When in doubt, use asterisks.

Escaping and literal characters

To show a literal asterisk, escape it: `\*`. To bold text that itself contains asterisks, wrap it in underscores instead, or escape the inner ones. Mismatched markers — a `**` opened and a single `*` closed — are the commonest reason bold text fails to render.

Emphasis inside other elements

Bold and italic work inside headings, list items, table cells and blockquotes. They do not work inside code spans or fenced code blocks, where everything is literal — that is by design, so code keeps its asterisks.

Frequently Asked Questions

How do I bold text in Markdown?
Wrap it in two asterisks or two underscores: `**bold**` or `__bold__`. Most style guides prefer asterisks.
How do I make text both bold and italic?
Use three markers: `***text***`. Some renderers also accept `**_text_**` or `_**text**_`.
Why is my bold not working?
Usually a mismatched marker — an opening `**` closed with a single `*`. Make sure the number of markers matches, and that there is no space between the marker and the text.
Does bold work in a table cell?
Yes. Emphasis works inside table cells and headings; it does not work inside inline code or fenced code blocks.

Related Markdown Tools