Markdown Preview
Preview Markdown (MD) as rendered HTML while keeping the generated HTML source available in a syntax-highlighted output panel.
What this tool does
Type or paste Markdown into the editor and this tool renders the live HTML preview as you type, alongside the generated HTML source you can copy. It supports CommonMark plus GitHub-Flavoured Markdown extras — tables, task lists, strikethrough — and runs the output through a sanitizer before rendering.
What UseAdvancedExtensions() actually enables beyond the basics
The Markdig pipeline uses UseAdvancedExtensions(), which bundles significantly more than the CommonMark baseline or the GFM features listed in the FAQ. The full bundle includes: tables, footnotes, definition lists, abbreviations (word-to-tooltip expansion), autolinks, task lists, strikethrough, emphasis extras (superscript, subscript, marked text), smart typography (converting -- to em dash, ... to ellipsis, quotes to curly quotes), citation references, figure captions, media link handling (auto-embedding YouTube/Vimeo URLs as iframes, though that may be stripped by the sanitizer), YAML front matter blocks, custom containers (:::warning-style div wrappers), and math blocks. Try ::: warning\nThis is a callout\n::: in the editor — it renders as a <div class="warning"> block. The FAQ description is accurate for what most users will use; this is what's available if you want to go further.
After Markdig renders the HTML, it's passed through Ganss.Xss.HtmlSanitizer with default settings — an allowlist-based sanitizer. The allowlist covers standard HTML elements and safe attributes, which strips anything potentially unsafe: script elements, inline event handlers, iframe elements, form elements, and also any custom or unknown elements. Write Markdown that uses raw HTML passthrough for a web component like <my-chart> and it will silently disappear from the rendered output because it's not in the sanitizer's allowlist.
What is Markdown?
Markdown is a lightweight markup language created by John Gruber in 2004. It lets you write formatted documents using plain text with minimal syntax — a hash for headings, asterisks for bold, hyphens for lists — and converts to clean HTML. Because Markdown files are plain text, they work perfectly with version control, can be edited in any text editor, and remain readable even without rendering. It has become the universal format for README files, developer documentation, static site generators, and note-taking applications.
CommonMark vs GitHub Flavoured Markdown
There is no single Markdown standard — different platforms implement slightly different extensions. The two most important variants are:
- CommonMark: A strict, unambiguous Markdown specification created in 2014 to resolve inconsistencies between implementations. Defines precise parsing rules for every edge case.
- GitHub Flavoured Markdown (GFM): GitHub's extension of CommonMark that adds tables, task lists (
- [x]), strikethrough (~~text~~), autolinks, and fenced code blocks with syntax highlighting. GFM is the most widely used Markdown flavour for developer documentation.
Essential Markdown syntax reference
- Headings:
# H1,## H2,### H3 - Bold:
**text**or__text__ - Italic:
*text*or_text_ - Inline code:
`code` - Code block: Three backticks, optionally followed by a language name for syntax highlighting
- Unordered list: Lines starting with
-,*, or+ - Ordered list: Lines starting with
1.,2., etc. - Link:
[link text](https://url.com) - Image:
 - Blockquote: Lines starting with
> - Horizontal rule: Three or more hyphens
---on their own line - Table (GFM): Pipe-separated columns with a header row separated by
| --- |
How to use this tool
- Type or paste Markdown text in the input editor.
- Click Preview to render the HTML output.
- View the rendered result in the preview panel.
- The Generated HTML tab shows the underlying markup.
- Copy the HTML to paste directly into a web page or CMS.
When to use Markdown vs HTML directly
Markdown is the right choice when content is written and maintained by humans — documentation, README files, blog posts, wikis. It is faster to write than HTML, easier to read in source form, and produces clean semantic HTML output. Use HTML directly when you need fine-grained layout control, custom attributes, or elements that Markdown cannot express. Many content platforms accept both: write in Markdown for text content and drop into HTML only where needed.
Markdown input
# DevToolsHub Build fast tools with **Blazor**.
Rendered preview
DevToolsHub
Build fast tools with Blazor.
Generated HTML
HTML output
<h1>DevToolsHub</h1> <p>Build fast tools with <strong>Blazor</strong>.</p>