npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

filetopdf-mcp

v0.1.1

Published

Model Context Protocol (MCP) server for FileToPDF — convert files, HTML, and Markdown to PDF from any MCP client (Claude, Cursor, etc.). Bring your own API key.

Readme

FileToPDF MCP server

npm smithery badge Install MCP Server

A Model Context Protocol server for FileToPDF. It lets any MCP client — Claude Desktop, Claude Code, Cursor, Cline, VS Code, ChatGPT, n8n, Make, or your own agent — convert files, HTML, and Markdown to PDF through natural language: invoices, reports, documentation, DOCX/XLSX/PPTX, images, web pages, and more.

Bring your own API key — get one free, in one click, at https://filetopdf.dev (10 free conversions, no signup required).

Tools

| Tool | What it does | |------|--------------| | get_account | Check the API key and show plan + remaining credits. Free, no credits used. | | convert_file | Convert a file from a public URL (DOCX, XLSX, PPTX, images, HTML, MD, PDF…) to PDF. | | convert_html | Render a raw HTML string (with optional CSS + layout options) to a pixel-perfect PDF via Chromium. | | convert_markdown | Render a raw Markdown string (with optional CSS + layout options) to a clean PDF. |

Each convert tool returns a metadata summary and the PDF as an embedded application/pdf resource (base64), so capable clients can save the file. Set the FILETOPDF_OUTPUT_DIR env var, or pass save_path, to also write the PDF to disk.

Layout options (landscape, paperWidth/Height, margins, scale, pdfa, passwords, …) are available on Pro, Scale, and the free trial; on Starter/Basic they return an upgrade error. Each successful conversion costs 1 credit; errors are free.

Quick start (local / stdio)

Cursor — one-click install: Add to Cursor (then replace the placeholder with your key).

Claude Desktop / Cline / any stdio client — add to the MCP config (claude_desktop_config.json, cline_mcp_settings.json, …):

{
  "mcpServers": {
    "filetopdf": {
      "command": "npx",
      "args": ["-y", "filetopdf-mcp"],
      "env": { "FILETOPDF_API_KEY": "sk_live_YOUR_API_KEY" }
    }
  }
}

Claude Code:

claude mcp add filetopdf -e FILETOPDF_API_KEY=sk_live_YOUR_API_KEY -- npx -y filetopdf-mcp

VS Code (.vscode/mcp.json or via MCP: Add Server):

{
  "servers": {
    "filetopdf": {
      "type": "stdio",
      "command": "npx",
      "args": ["-y", "filetopdf-mcp"],
      "env": { "FILETOPDF_API_KEY": "sk_live_YOUR_API_KEY" }
    }
  }
}

Hosted / remote (Streamable HTTP) — no install

A hosted endpoint is available at https://api.filetopdf.dev/mcp. Authenticate with your own key via the x-api-key header, an Authorization: Bearer header, or an ?apiKey= query parameter.

{
  "mcpServers": {
    "filetopdf": {
      "type": "streamable-http",
      "url": "https://api.filetopdf.dev/mcp",
      "headers": { "x-api-key": "sk_live_YOUR_API_KEY" }
    }
  }
}

This is also the URL to paste into any platform with an MCP client step — n8n (MCP Client Tool), Make (MCP Client), Zapier (MCP Client beta), Relay.app (Call MCP tool), Flowise, Langflow, Dify, LibreChat, AnythingLLM, or agent frameworks (OpenAI Agents SDK, LangChain, CrewAI, Vercel AI SDK).

To self-host instead:

npm run build && npm run start:http   # listens on $PORT (default 8080) at /mcp

A Dockerfile is included for container hosting (Smithery, Fly, Render, Cloud Run).

Develop & test

npm install
npm run build          # tsc -> dist/
npm test               # spawns the built stdio server, runs a live conversion

npm test reads FILETOPDF_API_KEY, or API_KEY= from a gitignored .env.

Links

License

MIT