How to convert Markdown to PDF

  1. Paste Markdown into the editor, open a .md file, or drop one anywhere on this page.
  2. Check the preview. Read shows the document alone, with a contents list built from its headings.
  3. Press Save as PDF. The browser's print dialog opens with the document and nothing else from this page.
  4. Choose Save as PDF as the destination (Firefox calls it Save to PDF) and save the file.

The PDF is made by your browser's own print engine, the same one that prints web pages, so the text in it is real text: you can search it, copy from it, and click its links.

Settings for a clean PDF

  • Headers and footers. Turn them off for pages that hold only your document. Chrome and Edge keep the switch under More settings. Left on, the browser prints its own lines at the top and bottom of every page.
  • Paper size. Pick Letter or A4 in the dialog. The document fits either.
  • Margins. The document asks for 18 mm at the top and bottom and 16 mm at the sides. Leave the dialog's margins on Default to keep them.
  • Background graphics. You do not need it. Code blocks and table shading are set to print either way.

What the PDF looks like

  • Body text prints at 11 pt in your system's sans-serif font, such as Segoe UI on Windows and San Francisco on a Mac.
  • A heading stays on the same page as the text after it. Code blocks, quotes, table rows and images are kept whole when they fit on one page.
  • Fenced code that names its language, such as ```python, is highlighted, and the colours print.
  • Task lists keep their ticks, tables keep their rules, and links keep working.
  • YAML front matter at the top of the file is left out.
  • Images with a full https:// address print. A relative path such as ./images/chart.png points into a folder this page cannot see, so those images print as text.

The PDF's title is the document's first top-level (#) heading, or the file's name when it has none, and Chrome saves a tagged PDF, the structure that assistive technology reads (we checked Chrome 158 on 3 December 2026). The browser also writes its own name and the date into the file's metadata. To see or remove that before you send the file, open it in our PDF metadata remover.

After the PDF: page numbers, covers and merging

The print dialog makes one PDF from one document. To add page numbers or exhibit covers, merge it with other PDFs or make it smaller, use Minute Notary's PDF editor, a free tool from the online notary platform we build and run. It also works in the browser and keeps the file on your device.

Converting Markdown to PDF on the command line

Pandoc converts a file with one command:

pandoc notes.md -o notes.pdf

By default Pandoc makes the PDF through LaTeX, so it needs a LaTeX engine installed; its --pdf-engine option can go through HTML instead. That suits scripts and build pipelines. For one document, this page is quicker and needs nothing installed.

Your file stays on your device

The converter is JavaScript that does all of its work in this browser tab.

  • The file is read by your browser and drawn here. No request carries your text, which you can confirm in the browser's network panel. Like every page on this site, the page records an anonymous visit, which sends its own address and nothing you open.
  • The text is kept in this browser's local storage, so it is still there when you come back, here or in the Markdown viewer. Clear removes it.
  • The preview runs in a sandboxed frame with scripts turned off, and raw HTML in the file is cleaned before it is shown, so a file cannot run code on this page.
  • Images with a full https:// address load from their own servers, as they would in any viewer.