Labsco
MCP SERVER

MCP-MD-PDF: Markdown to Word/PDF Converter

by sham-devs

Turn a markdown file into a Word document that already carries your company styling — and a PDF from the same source.

Document Conversion, PDF & TranslationVerified
Summary
Markdown to a branded Word document, with the PDF coming out of the same template.

The template is what this is for: apply a .dotx once and every document delivered afterwards matches it, instead of restyling by hand each time. Two things to plan around — PDF output depends on LibreOffice or Word being installed locally, and link text renders without being clickable in the output.

What it is

A converter from Markdown to .docx and .pdf, built on python-docx. Point it at a .dotx Word template and the output picks up that template's fonts, styles and layout.

What you get
  • One markdown file converted to .docx, .pdf, or both, written to an output path you choose
  • A .dotx Word template applied for consistent styling; without one, a clean default design is used
  • Batch conversion of a list of markdown files under the same template and format, named after the inputs and written into one directory
  • The supported input and output formats and features listed on request
  • Headings, emphasis, lists, tables, code blocks and blockquotes rendered, with backgrounds and borders on code blocks and quotes
Requirements

No account and no key — it reads and writes files on your machine. Python 3.10 or newer; run it with uvx mcp-md-pdf, or pip install mcp-md-pdf and run python -m md_pdf_mcp.server. The PyPI package is mcp-md-pdf, currently 0.1.0. Producing Word documents needs nothing further, but PDF conversion needs a renderer on the machine: LibreOffice on macOS (brew install --cask libreoffice) or Linux (sudo apt-get install libreoffice), or Microsoft Word on Windows through COM automation, which also wants pywin32. There is no Docker image on purpose — the server takes absolute host paths, which a container cannot resolve.

Setup effort

One command — uvx mcp-md-pdf