# Markdown Pdf Export

> Markdown Pdf Export is an open-source MCP server for files and documents. Exports Markdown files to styled PDFs via Chromium, from editors, AI assistants. It runs locally on your machine and is started by your AI client.

- **Kind:** MCP server
- **Pricing:** Open source
- **Platforms:** CLI, VS Code, macOS, Windows, Linux
- **Repository:** https://github.com/matinfo/markdown-pdf-export
- **MCP Registry name:** io.github.matinfo/markdown-pdf-export
- **Categories:** [files and documents](https://ai-powered.com/categories/files-and-documents), [content publishing](https://ai-powered.com/categories/content-publishing)
- **Listing updated:** 2026-11-20

## About

The README describes a tool that turns Markdown files into PDFs using a locally installed Chrome or Edge browser, with a settings file shared across editors, AI assistants and the command line. Output can be styled through five page layouts, custom CSS, fonts and code colour themes, plus headers and footers that carry the title, page numbers, date and a logo.

Math is rendered with KaTeX for inline and display formulas, and a [[toc]] marker generates a linked contents list. Individual documents can override the shared settings through front matter, so one report can differ from the rest of a project.

It suits developers and writers who keep documentation or reports in Markdown and want print-ready PDFs without leaving their editor. It is distributed as an npm package run with npx, and the registry entry exposes it as an MCP server over stdio.

## Features

- **Five page styles:** Offers Clean, Report, Academic, Compact and Technical layouts for the exported document.
- **Headers and footers:** Adds titles, page numbers, dates and a logo to header and footer zones.
- **KaTeX math support:** Renders inline and display maths written in standard dollar-sign notation.
- **Generated contents list:** Builds a linked table of contents from a marker placed in the Markdown.
- **Per-document settings:** Lets front matter override the shared settings for a single file.
- **Shared settings file:** Uses one configuration across VS Code, Zed, Cursor, AI assistants and the terminal.
- **Browser diagnostics:** Includes a doctor command that checks the browser and settings in one step.

## Good for

- Converting project documentation or READMEs into shareable PDFs
- Exporting technical reports with equations and a contents list
- Letting an AI assistant produce a PDF from a Markdown file during a chat
- Batch-styling PDFs with a consistent company header and footer

## Install

### Claude Code: Add with the CLI (Terminal)

```sh
claude mcp add markdown-pdf-export -- npx -y markdown-pdf-export
```

Add --scope user to use it in every project, or --scope project to share it in .mcp.json.

### Claude Code: Or share it with your project (.mcp.json)

```json
{
  "mcpServers": {
    "markdown-pdf-export": {
      "command": "npx",
      "args": [
        "-y",
        "markdown-pdf-export"
      ]
    }
  }
}
```

### Claude Desktop (claude_desktop_config.json)

```json
{
  "mcpServers": {
    "markdown-pdf-export": {
      "command": "npx",
      "args": [
        "-y",
        "markdown-pdf-export"
      ]
    }
  }
}
```

Settings → Developer → Edit Config, then quit and reopen Claude Desktop.

### Cursor (~/.cursor/mcp.json)

```json
{
  "mcpServers": {
    "markdown-pdf-export": {
      "command": "npx",
      "args": [
        "-y",
        "markdown-pdf-export"
      ]
    }
  }
}
```

Use .cursor/mcp.json in a project to share it with the project.

### VS Code (~/.copilot/mcp-config.json)

```json
{
  "mcpServers": {
    "markdown-pdf-export": {
      "type": "stdio",
      "command": "npx",
      "args": [
        "-y",
        "markdown-pdf-export"
      ]
    }
  }
}
```

Or put the same entry in .mcp.json at your workspace root to share it.

### Codex: Add with the CLI (Terminal)

```sh
codex mcp add markdown-pdf-export -- npx -y markdown-pdf-export
```

### Codex: Or add to config.toml (~/.codex/config.toml)

```toml
[mcp_servers.markdown-pdf-export]
command = "npx"
args = ["-y", "markdown-pdf-export"]
```

### Gemini CLI and Antigravity: Gemini CLI (~/.gemini/settings.json)

```json
{
  "mcpServers": {
    "markdown-pdf-export": {
      "command": "npx",
      "args": [
        "-y",
        "markdown-pdf-export"
      ]
    }
  }
}
```

Or run: gemini mcp add -s user markdown-pdf-export npx -- -y markdown-pdf-export

### Gemini CLI and Antigravity: Antigravity (~/.gemini/config/mcp_config.json)

```json
{
  "mcpServers": {
    "markdown-pdf-export": {
      "command": "npx",
      "args": [
        "-y",
        "markdown-pdf-export"
      ]
    }
  }
}
```

Use .agents/mcp_config.json to add it to one workspace only.

### Devin Desktop (~/.config/devin/mcp_config.json)

```json
{
  "mcpServers": {
    "markdown-pdf-export": {
      "command": "npx",
      "args": [
        "-y",
        "markdown-pdf-export"
      ]
    }
  }
}
```

On Windows the file is %APPDATA%\\devin\\mcp_config.json. Use .devin/mcp_config.json to share it with a project.

### Cline (cline_mcp_settings.json)

```json
{
  "mcpServers": {
    "markdown-pdf-export": {
      "command": "npx",
      "args": [
        "-y",
        "markdown-pdf-export"
      ]
    }
  }
}
```

Open it from the MCP Servers icon → Configure → Configure MCP Servers.

### Zed (Zed settings.json)

```json
{
  "context_servers": {
    "markdown-pdf-export": {
      "command": "npx",
      "args": [
        "-y",
        "markdown-pdf-export"
      ]
    }
  }
}
```

Open it with zed: open settings file. Merge context_servers into the settings you already have.

### JetBrains AI Assistant and Junie: AI Assistant (Settings → Tools → AI Assistant → Model Context Protocol (MCP) → Add)

```json
{
  "mcpServers": {
    "markdown-pdf-export": {
      "command": "npx",
      "args": [
        "-y",
        "markdown-pdf-export"
      ]
    }
  }
}
```

### JetBrains AI Assistant and Junie: Junie (~/.junie/mcp/mcp.json)

```json
{
  "mcpServers": {
    "markdown-pdf-export": {
      "command": "npx",
      "args": [
        "-y",
        "markdown-pdf-export"
      ]
    }
  }
}
```

Use .junie/mcp/mcp.json to share it with a project.

### Kiro (~/.kiro/settings/mcp.json)

```json
{
  "mcpServers": {
    "markdown-pdf-export": {
      "command": "npx",
      "args": [
        "-y",
        "markdown-pdf-export"
      ]
    }
  }
}
```

Use .kiro/settings/mcp.json to add it to one workspace only.

### Other clients (your client's MCP settings (most use this shape))

```json
{
  "mcpServers": {
    "markdown-pdf-export": {
      "command": "npx",
      "args": [
        "-y",
        "markdown-pdf-export"
      ]
    }
  }
}
```

## Tools

From the tool list in its README, going by the names, 1 name doesn't say. From the server's own tool labels and tool names; not verified by us.

- `doctor_markdown_pdf`: Checks the browser and settings for the PDF export tool.

## FAQ

### Which browser does Markdown Pdf Export need?

The README says it needs Google Chrome or Microsoft Edge, or a Chromium install via the install-browser command, which downloads about 200 MB.

### What are the requirements to run Markdown Pdf Export?

The README lists Node.js 20 or newer, since the package is run with npx.

### Is Markdown Pdf Export free?

Yes. Markdown Pdf Export is open source, so you can use and self-host it for free.

### How do I add Markdown Pdf Export to Claude Code?

Run this command in your terminal: claude mcp add markdown-pdf-export -- npx -y markdown-pdf-export

### What are the best alternatives to Markdown Pdf Export?

The closest alternatives to Markdown Pdf Export are Markdown Formatter, MintPDF, RenderMark, Markdown and md2pdf.

## Where this comes from

- Description: written from the project's README and its MCP Registry entry.
- Install steps: from the official MCP Registry entry.

## Alternatives

- [Markdown Formatter](https://ai-powered.com/mcp/markdown-formatter): Markdown Formatter is an open-source MCP server for files and documents.
- [MintPDF](https://ai-powered.com/mcp/mintpdf): MintPDF is a freemium MCP server for files and documents.
- [RenderMark](https://ai-powered.com/mcp/rendermark): RenderMark is an MCP server for files and documents.
- [Markdown](https://ai-powered.com/mcp/markdown-4): Markdown is an open-source MCP server for files and documents.
- [md2pdf](https://ai-powered.com/mcp/md2pdf): md2pdf is a free MCP server for files and documents.
- [PDFik](https://ai-powered.com/mcp/pdfik): PDFik is a freemium MCP server for files and documents.
- [Md Business](https://ai-powered.com/mcp/md-business): Md Business is an open-source MCP server for files and documents.
- [LoveMarkdown](https://ai-powered.com/mcp/lovemarkdown): LoveMarkdown is an open-source MCP server for files and documents.

---
Source: https://ai-powered.com/mcp/markdown-pdf-export
