/// CONVERT
1 credit

Markdown to PDF API — from .md to shareable PDF

READMEs, release notes and runbooks — styled PDFs in one call.

/// Quick answer

Markdown to PDF converts a .md file into a styled, shareable PDF in one REST call. Headings, nested lists, pipe tables, fenced code blocks with syntax highlighting and images all survive the conversion, and YAML front matter is stripped automatically. No pandoc, LaTeX toolchain or headless browser install is required — rendering happens server-side and costs one credit.

Try Markdown to PDF API — free →Read the docs

How does the Markdown to PDF API work?

One HTTP request from any language. Every ASHDOCS endpoint uses the same X-API-Key header.

curl -X POST https://www.ashdocs.com/api/v1/tools/markdown-to-pdf \
  -H "X-API-Key: ash_live_..." \
  -F "files=@release-notes.md" \
  -F 'options={"format":"A4"}'

How do I use Markdown to PDF API in Make, Zapier or n8n?

MAKE

Add an HTTP "Make a request" module, attach the .md file, and turn off Parse response so the PDF binary arrives intact.

Make setup guide →
ZAPIER

Use Webhooks by Zapier with a POST action — a "new file in Google Drive → convert → email the PDF" flow needs no code at all.

Zapier setup guide →
n8n

Use the HTTP Request node with Response Format set to File and map the binary response to your storage step.

n8n setup guide →
AIRTABLE

Trigger on a record with a Markdown attachment, convert it, and write the PDF back to an attachment field.

Airtable setup guide →

Common problems and fixes

SymptomCauseFix
Long tables or code blocks split awkwardly across pagesMarkdown has no concept of pagespage-break-inside: avoid is applied to tables and code blocks by default; restructure very long blocks that exceed a full page.
Code lines run off the page edgePDFs cannot scroll horizontallyLong lines are wrapped automatically; shorten lines in source for the cleanest output.
YAML front matter prints as raw textThe metadata block was passed through as body contentASHDOCS strips leading YAML front matter automatically — no action needed.
Images are missing from the PDFRelative paths like ./img/diagram.png resolve on your machine, not on a serverInline images as data URIs or reference them by absolute public URL.

Common use cases

Frequently asked questions

Can I convert Markdown to PDF without installing anything?+

Yes — send the file to the endpoint via curl or any HTTP client. No pandoc, LaTeX or headless browser install is needed; the rendering happens server-side.

Does the conversion keep code syntax highlighting?+

Yes. Fenced code blocks are rendered with highlighting before printing, so the PDF shows what your editor shows.

How do tables come out?+

Standard pipe tables render as proper bordered tables. Very wide tables should be restructured — a PDF page is narrower than a browser window.

Is there a free tier?+

Yes — 100 credits per month, no card required, and sandbox keys never consume credits.

RELATED TOOLS