Markdown in, a real PDF out — one click, no print dialog, no upload
.md file), pick Letter, A4, or A5, and click Download PDF. The document renders locally into a real PDF — headings scaled properly, tables with borders, shaded code blocks, clickable links, page numbers — with no print-dialog detour and no server. Page math is exact: a 187-word README with lists, a table, and a code block runs 2 pages at 11pt on Letter, 1 page at 10pt, and drops back to 1 page on A4, whose extra 1.76cm of height catches the overflow.
| Paper | Inches | Millimeters | PDF points | Text column at 1in margins |
|---|---|---|---|---|
| Letter (US) | 8.5 × 11 | 215.9 × 279.4 | 612 × 792 | 6.50 in (468 pt) |
| A4 | 8.27 × 11.69 | 210 × 297 | 595.28 × 841.89 | 6.27 in (451.28 pt) |
| A5 | 5.83 × 8.27 | 148 × 210 | 419.53 × 595.28 | 3.83 in (275.53 pt) |
A4 beats Letter by 49.89 points (1.76cm) of height and gives up 16.72 points (0.64cm) of width. Margin presets: narrow 0.5in (36pt), normal 1in (72pt), wide 1.5in (108pt) per side. There are 72 points in an inch — the unit every PDF engine lays out in.
Three stages, all local. Your markdown is parsed by remarkable into HTML — the same engine the popular open-source md2pdf app uses. The HTML is walked into a structured document definition: headings become scaled text blocks, tables become bordered table layouts, code blocks become shaded boxes, links attach their URLs so they stay clickable in the PDF. Finally pdfmake paginates that definition — measuring every line against the real page width — and writes the PDF bytes.
Because pagination is a real layout pass, the page count you see is the count you get, and the numbers below are verifiable: they were generated by this exact pipeline.
Load the sample — a 187-word project README with two heading levels, a bullet list, an ordered list, a fenced code block, a blockquote, a 3-column table, and a horizontal rule. On Letter at 11pt with 1-inch margins it renders to 2 pages (29,562 bytes). Same document:
| Setting | Result | Why |
|---|---|---|
| Letter, 10pt, normal margins | 1 page | Smaller type fits the table and code block on page 1 |
| Letter, 11pt, normal margins | 2 pages (default) | Block margins (headings +14pt, code +4/+10pt) push the table over |
| Letter, 12pt, normal margins | 2 pages | Worse overflow, more white on page 2 |
| A4, 11pt, normal margins | 1 page | A4's extra 49.89pt of height catches the overflow lines |
| Letter, 11pt, narrow margins | 1 page | Reclaims 72pt of vertical space (0.5in top + bottom) |
Three different knobs get you to one page — type size, paper, margins — and the cheapest depends on where the document is going. Emailing a contract? A4 at 11pt keeps readable type. Slide-deck handout? 10pt Letter. This is also the honest answer to "how many words per page": 11pt on Letter holds roughly 450–550 words of plain paragraphs (600 words spills to 2 pages), but every heading, list, and code block eats lines that words would have used. Structure is the variable, not just word count.
The pipeline adapts realdennis/md2pdf (MIT) — same markdown engine, same local-first philosophy — with the browser print dialog swapped for a direct pdfmake 0.2.20 (MIT) download. remarkable 1.7.4 (MIT) parses. All three are vendored under /vendor/ with license texts, and nothing executes anywhere but your tab.
Paste or open the markdown on the left, pick a page size, and click Download PDF — one click, no print dialog, no upload. The document is rendered to a real PDF with headings, tables, code blocks, and clickable links. Alternatively, print-to-PDF from any markdown preview works but hands you margins, headers, and filenames chosen by the browser, not you.
At 11pt body text with 1-inch margins on Letter paper (a 6.5-inch text column), a page holds roughly 450-550 words of plain paragraphs — 600 words spills onto a second page. Structure eats space fast: a 187-word README with headings, lists, a code block, a table, and a blockquote runs 2 pages at 11pt but squeezes onto 1 page at 10pt.
Letter is 8.5 by 11 inches (612 by 792 points); A4 is 210 by 297 millimeters (595.28 by 841.89 points). A4 is 1.76 cm taller and 0.64 cm narrower. In practice: the same document that fills 2 Letter pages can fit 1 A4 page, because the extra height catches the overflow — worth switching if your last page holds only a few lines.
No. The markdown parser and the PDF engine both ship with this page and run in your browser tab. Nothing is transmitted, which makes this safe for contracts, internal docs, notes, and anything you would not paste into someone else's converter.
Yes — tables render with header rows and borders, code blocks get a shaded background box, blockquotes indent in gray italics, and links stay clickable in the PDF. Raw HTML inside your markdown is deliberately shown as text rather than rendered, so generated PDFs stay predictable. Images embedded as data URIs are included; remote image URLs become labeled links.