Skip to content
Runs local · no upload

Markdown to PDF

Generates PDF from markdown via the browser print path — vector output, embedded fonts, no server.

100 % in the browser. Nothing is uploaded.

Markdown
Local images (optional)

Add the images your markdown references — relative paths get embedded as data URLs.

Nested paths like assets/screens/foo.png? Pick the whole image folder — the structure is preserved.

Profile

We open the browser print dialog. Choose "Save as PDF" there.

How It Works

  1. 01

    Bring in the markdown

    Paste field or file drop. Up to 25 MB per file.

  2. 02

    Profile and format

    Four profiles, A4 or Letter, margin between 0 and 50 mm. Optional: auto page-break before every H1 or H2.

  3. 03

    Open the print dialog

    The tool opens a popup with the print-ready HTML and triggers the browser print dialog after a short delay. Choose the Save-as-PDF option there.

Privacy

Markdown stays in your browser tab. The popup print window is same-origin (about:blank) and never talks to a remote server. Embedded images go into the HTML as data URLs, not uploads.

Markdown is portable — but the moment that text needs to land on someones desk, they want a PDF. This tool takes markdown and produces a printable document: four profiles, page breaks via marker, live internal links, optional table of contents. The browser print dialog finishes the job — pick Save-as-PDF, get a vector file with embedded fonts.

01 — How to Use

How do you use this tool?

  1. Paste markdown or load a .md file — both paths land in the same converter.
  2. Pick a profile, page size (A4 or Letter), margin, and whether auto page-breaks before every H1 or H2 should kick in.
  3. Optional: add local images, enable the table of contents, number lines in code blocks.
  4. Click the Open-PDF-print-dialog button and choose the Save-as-PDF option in the browser print dialog that appears.

Why markdown to PDF?

Markdown is the shortest form people write content in today — in the AI chat, the note tool, the pull request, the static-site generator. The moment that same text needs to reach people who do not read markdown — leadership, customers, school office, regulators — you need a PDF.

Browsers have generated PDFs for years — through the print dialog, backed by CSS Paged Media and stable layout guarantees. This tool turns the unspectacular print path into a proper markdown-to-PDF converter with four profiles, explicit page-break control and a clickable table of contents.

How does the conversion work?

Markdown gets parsed via a well-established open-source library and turned into HTML. Heading IDs are assigned (slug from heading text), the table of contents is built and the profile CSS is injected. The finished HTML lands in a new browser window (window.open() to about:blank). After a short delay — giving fonts a moment to settle — window.print() fires.

The browser print dialog appears, you pick Save as PDF. The resulting PDF is vector, contains the right fonts (Inter and JetBrains Mono via @font-face), respects the page breaks from your markers and keeps anchor links as clickable hyperlinks. Page-media features (@page, break-before, break-inside: avoid, table-header repeat) all work in the browser engine itself.

What are common use cases?

  • Reports and briefings. A spec or a weekly report becomes a PDF ready for the email-attachment convention.
  • Invoices and quotes. Markdown templates with variables become PDFs that ship straight away.
  • Term papers and theses. The Academic profile uses Times typography, justified text and a page break before every H1.
  • Print AI-chat output. The long answer from the AI chat becomes a hand-out for the meeting.
  • Tutorial print-outs. Code samples stay monospaced, long lines wrap softly, optionally with line numbers.

What stays intact?

Preserved: heading structure with auto-generated IDs (for anchor links and TOC), paragraphs with profile-specific typography, ordered and unordered lists, GFM tables with <thead> repeating across page breaks (Chromium standard), inline formatting, code blocks in monospace with optional line numbering, block quotes, local images as data URLs, live internal links.

Intentionally not mapped: math (KaTeX), diagrams (Mermaid), external image URLs (CORS / privacy policy), Word-specific formatting quirks. Footnotes appear as inline markers, not as laid-out footnotes at the bottom of the page — phase-two candidate when there is real demand.

Page-break options address the most common pain point of other tools: random page breaks at ugly spots. Three levers here: the pagebreak marker, automatic break before every H1, automatic break before every H2. Table rows do not break in the middle (break-inside: avoid).

How does the tool keep my markdown private?

If your markdown is an employee briefing or a customer quote, the last thing you want is for it to be uploaded somewhere. None of that happens here.

Markdown is parsed in your browser tab. The print-ready HTML lives in a same-origin popup window. The print dialog is a browser-owned feature and never talks to the tool backend. Embedded images go into the HTML as data URLs — they are not routed through an external server either. Open the Network panel of the developer tools and check.

More tools from the converter ecosystem worth knowing:

  • Markdown to HTML — same markdown input, finished HTML as standalone or body fragment.
  • Markdown to DOCX — Word file with real heading styles for tracked changes.
  • PDF to Markdown — the reverse direction with OCR fallback for scanned documents.

Last updated:

You might also like