{
  "markdown": "# FileToPDF MCP server\n\n[![npm](https://img.shields.io/npm/v/filetopdf-mcp)](https://www.npmjs.com/package/filetopdf-mcp)\n[![smithery badge](https://smithery.ai/badge/filetopdf/filetopdf)](https://smithery.ai/servers/filetopdf/filetopdf)\n[![Install MCP Server](https://cursor.com/deeplink/mcp-install-dark.svg)](https://cursor.com/en/install-mcp?name=filetopdf&config=eyJjb21tYW5kIjoibnB4IiwiYXJncyI6WyIteSIsImZpbGV0b3BkZi1tY3AiXSwiZW52Ijp7IkZJTEVUT1BERl9BUElfS0VZIjoic2tfbGl2ZV9ZT1VSX0FQSV9LRVkifX0%3D)\n\nA [Model Context Protocol](https://modelcontextprotocol.io) server for\n[FileToPDF](https://filetopdf.dev). It lets any MCP client — Claude Desktop, Claude Code,\nCursor, Cline, VS Code, ChatGPT, n8n, Make, or your own agent — convert **files, HTML,\nand Markdown to PDF** through natural language: invoices, reports, documentation,\nDOCX/XLSX/PPTX, images, web pages, and more.\n\n**Bring your own API key** — get one free, in one click, at\n<https://filetopdf.dev> (10 free conversions, no signup required).\n\n## Tools\n\n| Tool | What it does |\n|------|--------------|\n| `get_account` | Check the API key and show plan + remaining credits. Free, no credits used. |\n| `convert_file` | Convert a file from a **public URL** (DOCX, XLSX, PPTX, images, HTML, MD, PDF…) to PDF. |\n| `convert_html` | Render a raw **HTML** string (with optional CSS + layout options) to a pixel-perfect PDF via Chromium. |\n| `convert_markdown` | Render a raw **Markdown** string (with optional CSS + layout options) to a clean PDF. |\n\nEach convert tool returns a metadata summary **and** the PDF as an embedded\n`application/pdf` resource (base64), so capable clients can save the file. Set the\n`FILETOPDF_OUTPUT_DIR` env var, or pass `save_path`, to also write the PDF to disk.\n\nLayout options (`landscape`, `paperWidth/Height`, margins, `scale`, `pdfa`,\npasswords, …) are available on **Pro, Scale, and the free trial**; on Starter/Basic\nthey return an upgrade error. Each successful conversion costs **1 credit**; errors\nare free.\n\n## Quick start (local / stdio)\n\n**Cursor** — one-click install:\n[**Add to Cursor**](https://cursor.com/en/install-mcp?name=filetopdf&config=eyJjb21tYW5kIjoibnB4IiwiYXJncyI6WyIteSIsImZpbGV0b3BkZi1tY3AiXSwiZW52Ijp7IkZJTEVUT1BERl9BUElfS0VZIjoic2tfbGl2ZV9ZT1VSX0FQSV9LRVkifX0%3D)\n(then replace the placeholder with your key).\n\n**Claude Desktop / Cline / any stdio client** — add to the MCP config\n(`claude_desktop_config.json`, `cline_mcp_settings.json`, …):\n\n```json\n{\n  \"mcpServers\": {\n    \"filetopdf\": {\n      \"command\": \"npx\",\n      \"args\": [\"-y\", \"filetopdf-mcp\"],\n      \"env\": { \"FILETOPDF_API_KEY\": \"sk_live_YOUR_API_KEY\" }\n    }\n  }\n}\n```\n\n**Claude Code**:\n\n```bash\nclaude mcp add filetopdf -e FILETOPDF_API_KEY=sk_live_YOUR_API_KEY -- npx -y filetopdf-mcp\n```\n\n**VS Code** (`.vscode/mcp.json` or via *MCP: Add Server*):\n\n```json\n{\n  \"servers\": {\n    \"filetopdf\": {\n      \"type\": \"stdio\",\n      \"command\": \"npx\",\n      \"args\": [\"-y\", \"filetopdf-mcp\"],\n      \"env\": { \"FILETOPDF_API_KEY\": \"sk_live_YOUR_API_KEY\" }\n    }\n  }\n}\n```\n\n## Hosted / remote (Streamable HTTP) — no install\n\nA hosted endpoint is available at **`https://api.filetopdf.dev/mcp`**. Authenticate\nwith your own key via the `x-api-key` header, an `Authorization: Bearer` header, or\nan `?apiKey=` query parameter.\n\n```json\n{\n  \"mcpServers\": {\n    \"filetopdf\": {\n      \"type\": \"streamable-http\",\n      \"url\": \"https://api.filetopdf.dev/mcp\",\n      \"headers\": { \"x-api-key\": \"sk_live_YOUR_API_KEY\" }\n    }\n  }\n}\n```\n\nThis is also the URL to paste into any platform with an MCP client step —\n**n8n** (MCP Client Tool), **Make** (MCP Client), **Zapier** (MCP Client beta),\n**Relay.app** (Call MCP tool), Flowise, Langflow, Dify, LibreChat, AnythingLLM,\nor agent frameworks (OpenAI Agents SDK, LangChain, CrewAI, Vercel AI SDK).\n\nTo self-host instead:\n\n```bash\nnpm run build && npm run start:http   # listens on $PORT (default 8080) at /mcp\n```\n\nA `Dockerfile` is included for container hosting (Smithery, Fly, Render, Cloud Run).\n\n## Develop & test\n\n```bash\nnpm install\nnpm run build          # tsc -> dist/\nnpm test               # spawns the built stdio server, runs a live conversion\n```\n\n`npm test` reads `FILETOPDF_API_KEY`, or `API_KEY=` from a gitignored `.env`.\n\n## Links\n\n- Website & instant free API key: <https://filetopdf.dev>\n- API docs: <https://filetopdf.dev/documentation>\n- Official MCP registry name: `dev.filetopdf/filetopdf-mcp`\n\n## License\n\n[MIT](LICENSE)\n",
  "bytes": 4450,
  "sha": "fbd474e9ed4f0f0097334974ad90f803a01f0b6ce26cf99de68d8376ff2d9c74",
  "repo_slug": "filetopdf/filetopdf-mcp",
  "fonte": "repo",
  "truncated": false,
  "api": "https://agentalog.com/api/listings/mcp_dev_filetopdf_filetopdf_mcp_58fef4d6/readme"
}