MCP server

Give your AI agents professional PDF tools

The iLoveAPI MCP server lets Gemini, Claude and AI agents compress, merge, split, convert, OCR and watermark documents on your computer, powered by the same engines as the iLoveAPI REST API.

Open source (MIT). Runs locally with Node.js 18+. 2,500 free credits every month.

Merge contract.pdf and annex.pdf, then add page numbers
ilovepdf_merge_pdf✓ contract.pdf + annex.pdf → merged.pdf
ilovepdf_pagenumber✓ merged.pdf → contract-final.pdf
Done. contract-final.pdf (14 pages, numbered) is in your workspace.
9
PDF tools
MIT
open source
Local
stdio server
npx
no global install
Any
MCP client

How it works

Your AI assistant chooses the tool, iLoveAPI does the processing, and the result lands in your folder.

Ask

Ask in plain language: "compress this contract and add a watermark".

Call

Your MCP client calls the right iLoveAPI tool with its options.

Process

iLoveAPI processes the file as an API task.

Save

The result is saved in your working folder.

Works with the AI tools you already use

Gemini, Claude and AI agents: any MCP client that supports the stdio transport can use it.

Learn more →

iLovePDF in ChatGPT, Claude or Gemini for iLovePDF Premium accounts is a separate hosted connector (mcp.ilovepdf.com) with nothing to install.

Claude Desktop and Gemini CLI

Add the server to your client configuration and restart the client. The tools then appear in it.

Any MCP client

Standard MCP over stdio, so it works with any compatible client or agent framework.

Local files or URLs

Use files from your computer or public https:// links as inputs.

Up and running in three steps

No code to write: your AI assistant does the calling.

1

Get your key

Create a free account and copy your project public key from API keys.

project_public_…
2

Add the server

Paste the configuration into Claude Desktop, Gemini CLI or your MCP client.

npx -y @ilovepdf/mcp
3

Ask

"Merge these PDFs and add page numbers" and get the file back in your folder.

ilovepdf_merge_pdf

Set it up in a couple of minutes

Pick your client and paste the configuration. Only your project public key is needed; the server starts even without it and asks for it on the first tool call.

// claude_desktop_config.json
// macOS: ~/Library/Application Support/Claude/
// Windows: %APPDATA%\Claude\
{
  "mcpServers": {
    "ilovepdf": {
      "command": "npx",
      "args": [
        "-y",
        "@ilovepdf/mcp"
      ],
      "env": {
        "ILOVEPDF_PUBLIC_KEY": "project_public_xxxxxxxx",
        "ILOVEPDF_MCP_WORKDIR": "/Users/you/pdf-workspace"
      }
    }
  }
}

Your files, under your control

The server runs on your machine and only touches the folders you allow.

Deny-by-default file access

Inputs and outputs must be inside your working folder or an allowed folder. Path traversal and escaping symlinks are blocked.

Only a public key

The server needs your project public key, never your secret key, and download links stay private by default.

Processed like any API task

Files go to iLoveAPI only to be processed, with the same security as the REST API.

Free server, the credits you already have

The MCP server is free and open source. Each tool call uses credits from your iLoveAPI project, like any API request.

  • 2,500 free credits every month
  • One credit balance for the API and the MCP server
  • Prepaid packages and monthly plans

Put professional document tools in your AI workflow

  • Open source, MIT
  • 2,500 free credits every month
  • Works with any MCP client

Frequently asked questions

Can't find your answer? Our engineers are ready to help.

Contact us →
What is MCP?

The Model Context Protocol is an open standard that lets AI assistants and agents use external tools. The iLoveAPI MCP server exposes iLoveAPI document tools to any MCP client.

Which AI clients does it work with?

Gemini, Claude and AI agents: any MCP client that supports the stdio transport.

Which tools are available?

Compress, merge, split, Office to PDF, image to PDF, PDF to JPG, OCR, watermark and page numbers. Image tools, signature tools and more PDF tools are coming soon.

How much does it cost?

The server is free and open source (MIT). Each tool call uses credits from your iLoveAPI project, like an API request, and the free plan includes 2,500 credits every month.

Which key do I need?

Only your project public key (project_public_…), from API keys in your iLoveAPI console. Your secret key is never needed.

Where do my files go?

The server reads and writes files on your computer, inside the folders you allow. Files are sent to iLoveAPI only to be processed, with the same security as any API task.

Can I limit which folders it can access?

Yes. Set ILOVEPDF_MCP_WORKDIR to your working folder and add more folders with ILOVEPDF_MCP_ALLOWED_DIRS. Anything outside them is refused.

What happens with tools that return several files?

Split PDF and PDF to JPG save their results as a single .zip in your folder.

Is this the same as iLovePDF in ChatGPT, Claude or Gemini?

No. That is a hosted connector for iLovePDF Premium accounts, added from the third-party AI app (https://mcp.ilovepdf.com). The iLoveAPI MCP server runs on your machine with your iLoveAPI project key, for developers and AI agents.

Do I need to know how to code?

No. You add a short configuration to your AI client once, then ask in plain language.