Convert Markdown to PDF
The quickest way to get a PDF from a .md file is to print it from the browser and choose Save as PDF. You keep real text you can select and search, not a screenshot of the page.
Three steps
- Open MDFrame and drag the
.mdfile into the window, or pressCtrl + Oto pick it. - Press
Ctrl + P, or click the printer icon in the toolbar. - In the print dialog, choose Microsoft Print to PDF on Windows or Save as PDF on macOS and Linux. Name the file and save.
No Word or account is required. Offline use needs the reader and any diagram/math assets to have loaded in the current PWA cache version. Web images need a connection: select Load external images for the current document and wait for the required images to load before printing. Blocked images remain absent from the PDF.
Why the PDF stays sharp
The browser prints the HTML it already rendered, so what you saw on screen carries over to the page almost exactly:
- Text stays text, so zooming in never blurs it.
- Accents come out correctly, because system fonts are used.
- Tables, lists and code blocks keep their layout.
- Links usually remain clickable in PDF readers.
The print stylesheet does the cleaning up. The toolbar, tabs, table of contents and status bar hide themselves, so the page contains only the document.
Paper size and margins
Open More settings in the print dialog:
- Paper: A4 for normal documents, Landscape when tables have many columns.
- Margins: Default is fine. Choose Minimum if you want the text to run wider.
- Background graphics: turn this on to keep the grey code-block background and table fills.
Check before you send it
Open the finished PDF, press Ctrl + F and search for a word from the document. If it comes up, the PDF has real text rather than an image.
Select a paragraph to confirm you can copy it.
For documents with Mermaid diagrams, print from MDFrame and stop worrying. In dark mode the app re-renders diagrams with the light theme before printing, so the lines stay clear on white paper.
When the print goes wrong
- Code blocks lost their grey background: enable Background graphics.
- Tables are cut off on the right: switch to landscape or drop a column or two.
- A blank page at the end: usually a tall table or code block. Try shrinking the font with
Ctrl + -and print again. - Blurry diagrams: print from MDFrame rather than from an editor's preview, so the diagrams get re-rendered with the light theme.
If the recipient needs to edit
A PDF is not editable. In that case, export to Word (.docx) instead.
Read .md files in your browser
Drop a file into MDFrame to see the formatted document, search it, print it, or export PDF/Word. Your file never leaves your device.
Open the app