---
name: pdf-to-markdown
description: "Converts PDFs from URLs into clean Markdown for LLMs and RAG: headings, lists, tables, two-column papers in reading order, headers/footers removed, page-cited chunks, metadata and links, with optional OCR for scanned pages. Use when an agent must read, quote or index the content of one or many PDF documents (papers, reports, filings, manuals)."
license: MIT
compatibility: Needs the Apify MCP server (https://mcp.apify.com) or the Apify API, and an Apify account (runs are paid per event).
metadata:
  publisher: xsi
  actor: xsi/pdf-to-markdown
  store-url: https://apify.com/xsi/pdf-to-markdown
  pricing-checked: "2026-11-29 17:16 Europe/Brussels"
---

# PDF to Markdown for AI & RAG: Tables, OCR, Chunks

Apify Actor `xsi/pdf-to-markdown` by xsi. Store page: https://apify.com/xsi/pdf-to-markdown

PDF to Markdown for LLMs and RAG: give PDF URLs, get clean Markdown with headings, lists, tables, 2-column papers in reading order, headers/footers removed, page-cited chunks, metadata and links. OCR for scans at $0.005/page. $2 per 1,000 PDFs (100 pages included), no start fee, failures free.

## When to use it

- An agent needs the text and tables of PDFs reachable by URL, as Markdown or as page-cited chunks for a vector store.
- Scanned PDFs (OCR is automatic for image-only pages, billed per OCR page).

## When not to use it

- The PDF is only on the user's disk and has no URL: the Actor takes `urls`.
- Handwriting, or documents where exact math and complex merged-cell tables matter: the README says these can come out simplified.

## How to call it through the Apify MCP server

Connect the Apify MCP server with this Actor pinned as its own tool: `https://mcp.apify.com?tools=xsi/pdf-to-markdown` (it then appears as the tool `xsi--pdf-to-markdown`), or use the default tools and run it with `call-actor`.

1. Optional: `fetch-actor-details` with `{"actor": "xsi/pdf-to-markdown"}` to read the current input schema, README and pricing.
2. Run it with `call-actor`. Run limits go in `callOptions`, not in the Actor input; `maxTotalChargeUsd` caps what the run can charge.

```json
{
  "actor": "xsi/pdf-to-markdown",
  "input": {
    "urls": [
      "https://arxiv.org/pdf/1706.03762"
    ],
    "chunkSizeTokens": 800
  },
  "waitSecs": 30,
  "callOptions": {
    "maxTotalChargeUsd": 0.5
  }
}
```

3. `call-actor` returns the run status and storage IDs, not the results. Read them with `get-dataset-items` and the run's `datasetId` (supports `limit`, `offset`, `fields`). If the run is not finished within `waitSecs` (0-45 s), poll it with `get-actor-run`; for long jobs start with `waitSecs: 0`.

Required input fields: `urls`. The example uses only fields from the Actor's input schema (default build, read 2026-11-29).

Plain HTTP alternative: `POST https://api.apify.com/v2/acts/xsi~pdf-to-markdown/run-sync-get-dataset-items` with the same input as JSON and `Authorization: Bearer <APIFY_TOKEN>`.

## Price (pay per event)

Read from the public Apify API (`https://api.apify.com/v2/acts/xsi~pdf-to-markdown`, `pricingInfos`) on 2026-11-29 17:16 Europe/Brussels. Pricing model `PAY_PER_EVENT`, in effect since 2026-11-26. Prices are per event, in USD, by Apify plan (FREE, BRONZE, SILVER, GOLD, PLATINUM, DIAMOND). There is no start event. Minimum value for `maxTotalChargeUsd`: $0.01.

| Event | Title | Price per event | What is charged / free |
|---|---|---|---|
| `pdf-converted` | PDF converted | FREE $0.002 / BRONZE $0.0018 / SILVER $0.0016 / GOLD $0.0015 / PLATINUM $0.0015 / DIAMOND $0.0015 | One PDF converted to Markdown + page-cited chunks + metadata, first 100 pages included. Failed downloads, non-PDF links, password-protected, corrupt and empty PDFs are free. |
| `pages-100` | Extra 100 pages | FREE $0.002 / BRONZE $0.002 / SILVER $0.002 / GOLD $0.002 / PLATINUM $0.002 / DIAMOND $0.002 | Only for long documents: each started block of 100 pages beyond the first 100 (a 250-page PDF = 2 blocks). Pages you exclude with "pages" or "maxPagesPerPdf" are not counted. |
| `ocr-page` | Scanned page read (OCR) | FREE $0.005 / BRONZE $0.0045 / SILVER $0.004 / GOLD $0.0035 / PLATINUM $0.0035 / DIAMOND $0.0035 | One image-only (scanned) page read with OCR and returned as text. Pages with a normal text layer are never OCRed nor charged; pages where OCR finds no text are free. |

On the FREE plan, 1,000 `pdf-converted` events cost $2. Prices can change with Apify's notice period: check the Store page or `fetch-actor-details` before a large run.

## Limits

- Structure is rebuilt with layout heuristics: complex tables (merged cells, multi-line cells, rotated headers) and math formulas can come out simplified; superscripts are written inline (`10^20` reads `1020`).
- OCR quality depends on the scan; Tesseract supports the 7 languages listed. Handwriting isn't supported.
- Password-protected PDFs need the `password`; we never try to break protections.

## Facts about this tool

- Public on the Apify Store; users in the last 30 days: 0 (API, 2026-11-29). It is a new tool without reviews yet.
- Source of every fact in this file: the Actor's Store page and README, and the public Apify API. Report errors at https://github.com/xsi-hq/xsi-agent-tools/issues
