Report a problem

Markdown to PDF Converter

Paste Markdown or upload a .md file, watch it render live, and save a clean PDF with your browser's print engine. Free, no sign-up, and everything runs locally on your device.

Drop a .md file here or click to browse
UTF-8 .md, .markdown or .txt files. Or paste directly below

Your Markdown never leaves your browser

Rendering is local (marked + DOMPurify). Only the rendered document on the right is sent to the printer; this page's header, controls and footer are hidden automatically.

How this Markdown to PDF converter works

Paste your Markdown into the source box or drop a .md file onto the upload area. The text is parsed into HTML by marked, sanitized by DOMPurify so no raw HTML or scripts can leak through, and rendered in the live preview with clean document typography: styled headings, code blocks on a soft background, bordered tables, blockquotes and lists. Pick a font size and margin preset, then click Download as PDF. Your browser's print dialog opens; choose Save as PDF (or Microsoft Print to PDF on Windows) as the destination, and only the rendered document is printed. The site header, controls and footer are hidden by a dedicated print stylesheet.

Why print-to-PDF beats server-side converters

Online converters send your text to a server, re-render it with that server's fonts, engine and page defaults, and hand you back a file you have no control over. Line breaks shift, code blocks lose their formatting, tables overflow, and fonts get substituted. Print-to-PDF is different: the PDF is produced by the same browser engine that drew the preview on your screen, so fonts, spacing, table borders and code formatting carry over with full layout fidelity. What you see in the preview is exactly what lands on the page.

Privacy, honestly: nothing is uploaded. Parsing, sanitizing and printing all happen locally in your browser's memory, so this tool is safe for drafts, contracts, internal notes and anything else you would not email to a stranger. Once the page has loaded, it even works offline.

Frequently asked questions

How do I convert Markdown to PDF?

Paste Markdown or drop a .md file onto the upload area. A live preview renders instantly. Click Download as PDF, then in the print dialog choose Save as PDF (or Microsoft Print to PDF) as the destination and save.

Why use print-to-PDF instead of an online converter?

Server converters re-render with their own fonts and defaults, shifting line breaks and mangling code blocks. Print-to-PDF uses your browser's print engine on the exact preview you see, so fonts, spacing, tables and code formatting carry over with full fidelity.

Is my Markdown uploaded anywhere?

No. Rendering and sanitization happen locally in your browser with marked and DOMPurify. Your text never leaves your device, and the page works offline once loaded.

Which Markdown features are supported?

Headings, bold, italic, links, images, lists, blockquotes, inline code, fenced code blocks, tables and horizontal rules, with GitHub-flavored Markdown via marked. Output is sanitized with DOMPurify so raw HTML cannot inject scripts.

Can I change the paper size or margins?

Yes. Use the font size presets (small, medium, large) and margin presets (compact, normal, wide) above. Paper size (A4 or Letter) and orientation are chosen in your browser's print dialog.

Related tools