2026-07-237 min·#how-to#doc

Как конвертировать Markdown в PDF (2026): три надёжных способа

Zephyr WhimsyEditorial · 2026-07-23

Три надёжных способа конвертировать Markdown в PDF (Pandoc, печать из браузера, онлайн-инструменты), что сохраняет каждый, плюс web-first вариант: поделитесь ссылкой, а PDF экспортируйте только при необходимости.

The short answer
Three reliable ways to turn Markdown into PDF: Pandoc (most control, command line), Print to PDF from a previewer (fastest, no install), and online converters (convenient, less private). All produce a fixed file. If the document will change or be shared widely, consider the web-first option - a link that stays current, with PDF kept as a fallback. That is the path Plain takes.

Markdown is great for writing; PDF is what people ask you to send. The gap between the two is a quick conversion - but which method you pick decides how well your headings, code, and tables survive. Here are the three reliable routes, what each preserves, and one option most guides skip.

1. Pandoc: the most control

Pandoc is the standard for Markdown conversion. With a PDF engine installed, the command is simply:

pandoc input.md -o output.pdf

It maps Markdown headings, lists, tables, and fenced code blocks into a formatted PDF. You control the look with a template and options like --pdf-engine=wkhtmltopdf (HTML-based, good for web-styled docs) or a LaTeX engine (best typography). The cost is setup: you need Pandoc plus an engine (TinyTeX is a light LaTeX option). For repeatable, styled output at scale, Pandoc wins.

2. Print to PDF: the fastest, no install

Open the Markdown in anything that shows a rendered preview - VS Code with a Markdown extension, Typora, Obsidian, or a browser editor - then use Print and choose Save as PDF. The PDF captures exactly what the preview renders, including fonts and code styling. It takes seconds and needs no command line. The tradeoff is less control over page breaks, margins, and headers than Pandoc, and wide tables can clip at the page edge.

3. Online converters: convenient, mind the privacy

Plenty of web tools take a pasted Markdown or an uploaded .md and hand back a PDF. They are convenient when you are on a machine you cannot install software on. Two cautions: your content is uploaded to someone else's server (avoid for anything sensitive), and formatting fidelity varies a lot between tools. Fine for a quick, non-confidential doc; not ideal for a contract or internal report.

PandocPrint to PDFOnline toolPlain (web-first)
Best forStyled, repeatable outputA quick one-offNo-install convenienceA doc that stays current
Install neededYes (+ engine)NoNoNo
Keeps code / tablesYesYes (from preview)VariesYes
PrivacyLocalLocalUploadedYour account
OutputPDF filePDF filePDF fileLink + PDF export
The first three produce a fixed file. The web-first option keeps the document as a live link and exports PDF only when a file is required.

The option most guides skip: a link instead of a file

Every method above ends in a PDF - a fixed snapshot. That is exactly right when you need an archival, print-ready file: a signed document, a conference upload, a formal report. But a lot of the time a PDF is just the habit. Someone asked for "a file," so you flatten a living document into pages, email it, and then re-send a new version the next time a number changes.

The web-first alternative is to keep the document as a page you share as a link. With Plain, you write in Markdown (or let AI draft it) and it renders a formatted web document you hand around as a URL. It stays current for everyone on the link, opens on any device with no install, and can hold live charts and working links a PDF cannot. When a receiver genuinely needs a file, Plain exports Word or PDF as a fallback - the same destination the tools above start from, kept as the exception rather than the default.

How to choose

You want...                          -> Reach for
-----------------------------------------------------------
Styled, repeatable, scriptable PDF   -> Pandoc
A quick one-off, no install          -> Print to PDF
Convenience on a locked-down machine -> Online converter
A doc that stays current + PDF later -> Plain (web-first)

Pick by the last mile. If the PDF is the final, unchanging artifact, Pandoc or Print to PDF is all you need. If the document will keep changing and be shared with others, a link that stays current beats re-sending files - and you can still export a PDF the moment someone insists on one.