Convert Markdown to PDF
Paste Markdown and download it as a PDF file. Free, no signup, no watermark. You see live progress while it is made, and the same conversion is available as an API call and to AI agents over MCP.
Input
Result
Choose a file and press Run.
Files you upload and the results are stored for one hour, then deleted. Anyone who has the link can open them, so don't upload anything private.
How to convert Markdown to PDF
- Paste your Markdown into the input box.
- Adjust the settings if you want to. The defaults suit most documents.
- Press Run and watch the progress bar.
- Download the PDF file, or copy its link to share it.
This page runs the markdown to pdf tool. Open the tool itself for every option.
What happens in this conversion
- Page and style
- Choose A4, Letter, A5 or Legal, the margin and the text size, and one of three styles: clean, serif or compact. Page numbers are optional.
- Code and tables
- Code blocks are coloured by language and tables are drawn with borders.
- Pictures
- Pictures linked from the web are never loaded. Their description is printed instead. Only pictures embedded in the text itself as data are drawn.
- Limits
- Up to 100,000 characters. A document that is mostly very large tables can run out of memory; split it in two if that happens. Chinese, Japanese and Korean characters and emoji are not drawn.
Markdown and PDF compared
| Format | What it is | Best for | Watch out for |
|---|---|---|---|
| Markdown Markdown text | Markdown is plain text with light marks for headings, lists, links and tables. GitHub, documentation sites, note apps and chat tools show it formatted, and it is the form AI models read most reliably. | Readmes, notes, documentation and text handed to an ai model. | It has no page layout: fonts, colours, columns and exact positions cannot be expressed. |
| PDF PDF document | PDF fixes a document to its pages, so it looks the same on every screen and printer. It is the usual format for invoices, contracts, reports and scans. | Documents that must look identical everywhere and be printed. | The text inside is hard to edit or reuse, and a scanned PDF holds only pictures of pages. |
Use it from code or an agent
curl -s https://setget.net/v1/tools/markdown-to-pdf \
-H 'Content-Type: application/json' \
-d '{"input":{"markdown":"# Report\n\nSales rose **12%** this quarter.\n\n| Region | Sales |\n|--------|------:|\n| North | 420 |\n| South | 380 |"},"wait":30}'
import json, urllib.request
body = {'input': {'markdown': '# Report\n\nSales rose **12%** this quarter.\n\n| Region | Sales |\n|--------|------:|\n| North | 420 |\n| South | 380 |'}, 'wait': 30}
request = urllib.request.Request("https://setget.net/v1/tools/markdown-to-pdf", json.dumps(body).encode(),
{"Content-Type": "application/json"})
print(json.load(urllib.request.urlopen(request))["result"])
const response = await fetch("https://setget.net/v1/tools/markdown-to-pdf", {
method: "POST",
headers: {"Content-Type": "application/json"},
body: JSON.stringify({"input":{"markdown":"# Report\n\nSales rose **12%** this quarter.\n\n| Region | Sales |\n|--------|------:|\n| North | 420 |\n| South | 380 |"},"wait":30}),
});
console.log((await response.json()).result);
Tool: run_tool
Arguments:
{
"slug": "markdown-to-pdf",
"input": {
"markdown": "# Report\n\nSales rose **12%** this quarter.\n\n| Region | Sales |\n|--------|------:|\n| North | 420 |\n| South | 380 |"
},
"wait": 30
}
{
"input": {
"markdown": "# Report\n\nSales rose **12%** this quarter.\n\n| Region | Sales |\n|--------|------:|\n| North | 420 |\n| South | 380 |"
},
"wait": 30
}
This is a file tool, so a call takes three steps: upload the file to get a reference, run the tool with that reference, then read the result and download its files. Uploads and results are public by link and expire after one hour.
Endpoint: POST /v1/tools/markdown-to-pdf. Over MCP: run_tool with slug: "markdown-to-pdf".
Machine-readable: input schema, Markdown. Connect an agent.
Inputs
| Name | Type | Required | What it does |
|---|---|---|---|
markdown |
string | yes | The Markdown to convert. |
page_size |
string | no | Paper size. One of: A4, Letter, A5, Legal. Default: "A4". |
margin |
integer | no | Empty space around the text on every page, in millimetres. Default: 20. From 5 to 50. |
font_size |
integer | no | Size of the body text in points. Default: 11. From 6 to 24. |
theme |
string | no | Look of the document: clean is sans-serif, serif is a book-like face with justified text, compact fits more on a page. One of: clean, serif, compact. Default: "clean". |
title |
string | no | Title stored in the PDF, shown by viewers in the window title. Defaults to the first heading. Default: "". |
page_numbers |
boolean | no | Print "page / pages" at the bottom of every page. Default: false. |
allow_html |
boolean | no | Keep harmless HTML tags written in the Markdown, such as <br>, <sub> and <div style="page-break-after: always">. Scripts, style sheets and frames are always removed. When off, HTML is shown as text. Default: false. |
Questions
- Is it free to convert Markdown to PDF?
- Yes. There is no signup, no watermark and no paid tier. A fair-use limit per day applies to keep the service available to everyone.
- How much Markdown can I convert at once?
- Up to 100,000 characters.
- What happens to the PDF file?
- It is stored for one hour so you can download it, then deleted. Anyone who has the link can open it during that hour, so do not convert anything private.
- Can a script or an AI agent convert Markdown to PDF?
- Yes. Call POST https://setget.net/v1/tools/markdown-to-pdf with JSON, or use the run_tool tool of the SetGet MCP server with slug "markdown-to-pdf". The code samples on this page are ready to copy.
More conversions
Related tools
- Markdown to HTMLConvert Markdown to clean HTML, with tables, task lists and code blocks, as a fragment or a full page.
markdown-to-html - Markdown to Word (DOCX)Turn Markdown into a Word document with real headings, lists, tables and code, ready to edit.
markdown-to-docx - PDF to MarkdownTurn a text PDF into clean Markdown: headings from letter size, joined paragraphs, lists and simple tables.
pdf-to-markdown - Merge PDFsJoin 2 to 20 PDF files into one PDF, in the order you give them. Bookmarks are kept.
pdf-merge - Compress a PDFMake a PDF file smaller by packing its contents tighter and, if you allow it, re-saving its pictures at a lower resolution.
pdf-compress - Anything to MarkdownTurn almost any document into Markdown: PDF, Word, PowerPoint, Excel, HTML, EPUB, e-mail, notebooks, CSV.
any-to-markdown