web_dev_markdown_to_html
Convert Markdown to HTML for web display. Uses regex to parse headings, bold, italic, code, lists, tables, blockquotes, and links. Returns rendered HTML and stats.
Instructions
Markdown to HTML Converter. Convert Markdown text into HTML using fast regex-based rules: ATX headings (h1-h5), bold/italic/bold-italic, strikethrough, inline code and fenced code blocks (with language class), links, images, ordered and unordered lists, blockquotes, horizontal rules, GFM pipe tables, and paragraphs. Use this to render Markdown for display; use web_dev_html_to_markdown for the inverse (HTML to Markdown), and webdev_html_minifier to shrink HTML rather than generate it. Runs locally on the input you provide: read-only, non-destructive, deterministic, offline, contacts no external service, and is rate-limited (anonymous 60 req/min, 500/hr). Returns the rendered HTML, a stats object counting produced elements, and a sanitised preview HTML with disallowed tags stripped. Note: the three options are accepted for forward compatibility but do not currently change the output.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| markdown | Yes | The Markdown source to convert. Required and must be non-empty, or a 400 is returned. | |
| options | No | Reserved options. Currently accepted but ignored; output is identical whether or not they are set. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| html | No | The rendered HTML output. | |
| stats | No | Counts derived from the input Markdown and resulting HTML. | |
| preview_safe | No | Copy of the HTML with tags outside an allow-list stripped, safe for preview. |