mdedit.io
Markdown → PDF

Convert Markdown to PDF in the browser — no build chain required

mdedit.io exports print-ready PDF directly from your Markdown document. Get a title page, table of contents, page numbers, headers, and layout presets — without a CLI, a LaTeX installation, or a build pipeline.

How Markdown to PDF works in mdedit.io

Most Markdown-to-PDF tools require a command-line step: install Pandoc, configure wkhtmltopdf, run a build script, check output. That pipeline is fragile and not portable across machines.

mdedit.io handles the render pipeline in the browser. You write Markdown with a YAML frontmatter block, enable a layout preset, and use the print preview to check the output before exporting. The PDF comes back from the same session without a local install.

---
title: "Project Report"
author: "Jane Doe"
date: "2026-05-20"
layout: scientific
toc: true
number-sections: true
fontsize: 11pt
geometry: "margin=2.5cm"
---

# Introduction

This report covers...

## Background

$$E = mc^2$$

Layout presets for different print needs

Scientific

Title page, numbered sections, TOC, running headers, and citation-aware output. Designed for thesis, paper, and technical report submission.

Literature

Clean book-style layout with chapter breaks, drop caps optional, and minimal academic infrastructure. For manuscripts, essays, and long-form writing.

Compact

Dense single-column output for handouts, documentation, or reference sheets where vertical space matters more than visual structure.

Custom CSS

Override margins, fonts, spacing, header, and footer text with your own CSS rules applied directly in the layout editor — no separate stylesheet required.

What you control in frontmatter

Document metadata

Set title, author, date, subtitle, and abstract in YAML frontmatter — they appear on the title page and in the PDF metadata.

Page layout

Control geometry (margins), fontsize, linestretch, and papersize. Changes take effect in both the live print preview and the exported PDF.

Section numbering and TOC

Enable number-sections: true and toc: true to get a numbered table of contents and section numbers generated automatically from your headings.

Print preview before export

Use the live print preview to check pagination, heading breaks, and layout before committing to a PDF export — the preview uses the same rendering engine.

FAQ — Markdown to PDF

Do I need to install anything?

No. The PDF export pipeline runs entirely in the browser and on the server side. You do not need Pandoc, wkhtmltopdf, LaTeX, or Node.js installed locally.

Does it support math equations?

Yes. KaTeX math renders correctly in the exported PDF. Use $...$ for inline math and $$...$$ for display equations.

Does it support Mermaid diagrams?

Yes. Mermaid flowcharts, sequence diagrams, class diagrams, and other supported diagram types are rendered as vector output in the PDF.

Can I print long documents?

Yes. The print engine handles section breaks, page widows and orphans, footnotes, figure captions, and lists across pages — the same rendering used for academic documents.

Can I use citations in the PDF?

Yes. Use embedded bibliography data with Pandoc-style citation keys and the scientific layout — the reference list and in-text citations appear correctly in the PDF output.

Can I self-host the export pipeline?

Yes. mdedit.io is open source and self-hostable with Docker. The export dependencies (Chromium, Pandoc) are included in the Docker image.