PDF to Word API: convert a PDF to an editable DOCX

Updated 2026-11-10

Use when an agent must convert a PDF to Word (.docx) for editing. Add output=url for a 24 h link.

From an MCP client, add https://tanod.dev/mcp and call convert_pdf_to_word; calls are paid per use with x402, no key or signup.

This endpoint converts a PDF (base64, upload or URL) to DOCX with LibreOffice in a sandbox and returns the file as base64. The example converts a one-page test PDF.

Request

curl (an x402 client pays the 402; shown without the payment header)
curl -s -X POST https://tanod.dev/v1/pdf/to-docx \
  -H 'content-type: application/json' \
  -d '{"url": "https://www.w3.org/WAI/ER/tests/xhtml/testfiles/resources/pdf/dummy.pdf"}'

Response

Response (from the live code, trimmed)
{
  "operation": "pdf-to-docx",
  "input_bytes": 13264,
  "input_pages": 1,
  "converted_pages": 1,
  "pages_without_text": [],
  "warnings": [],
  "fidelity_note": "LibreOffice imports the PDF as drawing objects and text boxes, so the Word file looks like the PDF but is not reflowable text: each line of text is its own positioned text box, tables are not rebuilt as Word tables and links are not kept. Fidelity varies, and complex layouts, multi-column pages, forms and heavy vector graphics may convert poorly. A scanned page (an image with no text layer) stays an image: run OCR first (/v1/pdf/ocr).",
  "output_bytes": 5007,
  "file": {
    "name": "converted.docx",
    "content_type": "application/vnd.openxmlformats-officedocument.wordprocessingml.document",
    "bytes": 5007,
    "data_base64": "UEsDBBQACAgIAMysSF0A... (base64, 5007 bytes)"
  }
}

Limits and caveats

Add "output": "url" to the request and the file is stored for 24 hours and returned as a link (url, expires_at, sha256) instead of base64, which keeps it out of your context window. The price is the same. How the links work.

Price and free allowance

USD 0.01 per call, paid in USDC on Base, Polygon, Solana, BNB Chain or Arbitrum with x402. Over HTTP 2 calls per IP per UTC day are free with the header X-Tanod-Free: 1, for a PDF sent inline as base64 of at most 1 MB (one pool with document to Markdown and PDF compress). MCP tool: convert_pdf_to_word at https://tanod.dev/mcp (or the focused text server at https://tanod.dev/mcp/text), with no free tier over ordinary MCP. No signup and no API key.

To pay by card, run the same conversion as an Apify actor, tanod/pdf-to-word-converter, billed through your Apify account at USD 0.03 per converted document (failed files are free); give it a list of file URLs and get the converted files back in the run's storage.

Use it from Claude without writing code: in claude.ai or Claude Desktop, add https://tanod.dev/mcp/docs?via=pdf-to-word-api as a custom connector (steps), then ask in plain words, for example "Convert this PDF to a Word document." Eligible Claude.ai connectors use a shared daily docs allowance; ordinary MCP calls are paid. Outside that allowance, a call needs an x402 payment, which these clients can make.

Updated 2026-11-10. Related guides: Document to Markdown API, PDF OCR API, PDF to text API. All guides, or back to tanod.dev.