md-to-pdfby SuperMD

// md-to-pdf

Convert markdown to a styled PDF.

Paste your markdown below. SuperMD renders it with clean typography — headings, code blocks, tables, and lists — then opens a print dialog so you can save it as PDF.

getting-started.pdf

99 words · 586 chars

How it works

Clicking “Download PDF” opens your rendered document in a new tab and triggers the browser's print dialog. Choose “Save as PDF” as the destination. The rendered document uses web fonts and precise CSS — the resulting PDF matches what you see in the preview.

// supported markdown

What renders in the PDF.

Text

  • Headings h1–h6
  • Bold & italic
  • Blockquotes
  • Horizontal rules

Code

  • Fenced code blocks
  • Inline code
  • Language hints
  • Monospace font

Structure

  • Ordered lists
  • Unordered lists
  • Nested lists
  • Tables

Media

  • Links
  • Images
  • HTML tags
  • GFM checkboxes

// faq

Frequently asked questions

Does my markdown get uploaded to a server?

No. Conversion runs entirely in your browser. Your markdown is rendered locally with React, then printed via the browser's native print engine. Nothing is sent to a server.

Why does it use the print dialog instead of a direct download?

The browser's PDF engine produces much higher-quality output than JavaScript PDF libraries. Fonts, hyphenation, page breaks, and table rendering are all handled natively — resulting in a PDF that looks exactly like the preview.

Can I control page margins or font size?

The layout uses sensible defaults (48px padding, 14px body text, 740px max-width). For custom styles, you can use the browser's print settings (Ctrl/Cmd+P) to adjust margins, paper size, and scale before saving.

Does it support GitHub Flavored Markdown (GFM)?

Yes — the renderer supports tables, strikethrough, task list checkboxes, and inline HTML via rehype-raw. Most GFM documents render correctly out of the box.