PDF to Markdown, Tables & RAG Chunks

Turn PDF, Word (DOCX) and image files into clean Markdown, tables (rows and CSV) and RAG-ready chunks with page numbers. Scanned pages are read automatically with OCR. No API keys, no LLM calls, nothing to configure.

Run it on ApifyUse it from an agent

What you get for each document

FieldWhat it is
markdownThe whole document as Markdown: headings, paragraphs, bullet lists, tables and <!-- page N --> markers
tablesEvery detected table with its page, rows (list of lists) and csv
chunksText split for embeddings: text, page_start, page_end, nearest heading, char_count
metadataTitle, author, subject and dates from the file properties
warnings, errorPlain-language notes and stable error codes such as PDF_ENCRYPTED, DOWNLOAD_FAILED or NO_TEXT_FOUND

Each document's Markdown is also saved as a .md file in the run's key-value store. One bad file never stops the rest of the batch.

Example: RAG ingestion

One dataset item per chunk, ready for a vector database:

{"documentUrls": ["https://example.com/handbook.pdf", "https://example.com/policy.docx"],
 "outputMode": "chunks",
 "chunkMaxChars": 1200,
 "chunkOverlapChars": 150,
 "includeMarkdown": false}

Agents and back ends that already hold the file can send it inline: {"documents": [{"name": "invoice.pdf", "content_base64": "..."}]}.

Options

Use it

In the Apify Console

Open the Actor page on Apify, fill in the input form and click Start. Results land in the run's dataset (JSON, CSV or Excel download).

From an AI agent (MCP)

Apify's hosted MCP server exposes the Actor as a tool to Claude, Cursor, VS Code and other MCP clients. Server URL:

https://mcp.apify.com/?tools=errandkit/pdf-to-markdown-tables

For example, in Claude Code (sign in to Apify when asked, or add --header "Authorization: Bearer YOUR_APIFY_TOKEN"):

claude mcp add --transport http errandkit "https://mcp.apify.com/?tools=errandkit/pdf-to-markdown-tables"

Copy-paste config for Claude Desktop, Cursor, VS Code, Windsurf and ChatGPT →

From code (Apify API)

curl -X POST "https://api.apify.com/v2/acts/errandkit~pdf-to-markdown-tables/run-sync-get-dataset-items" \
  -H "Authorization: Bearer YOUR_APIFY_TOKEN" -H "Content-Type: application/json" \
  -d '{"documentUrls":["https://www.irs.gov/pub/irs-pdf/fw9.pdf"],"outputMode":"documents"}'

Errandkit doesn't run its own hosted API yet. Every way of using this tool goes through your Apify account.

Pricing

EventPricePer 1,000
Page processed (text layer; DOCX counts 1 page per 3,000 characters)$0.0005$0.50
Page or image read with OCR$0.003$3.00
Actor start (Apify standard)$0.00005$0.05

Examples: a 10-page digital PDF costs $0.005; a 10-page scan costs $0.03. Blank pages, failed downloads, encrypted or broken files aren't charged. Set a maximum cost per run and the tool stops before going over it, keeping everything already finished.

Launch prices. The price shown on the Apify Store page is the one you are charged, and Apify shows it before every run.

Good to know

Your data

Files are processed inside your own Apify run. Nothing is sent to any third-party service or AI model, and nothing is kept by us. Output lives in your run storage under your account's retention settings. Details: privacy.

Questions

Does it work on scanned PDFs?

Yes. With OCR set to auto, only pages without a text layer are read with OCR, at $0.003 per page. Typed documents read well; handwriting reads poorly.

Does it send my documents to an AI model?

No. There are no API keys and no LLM calls. Files are processed inside your own Apify run and nothing is sent to any third-party service or AI model.

What does it cost, and am I charged for failures?

$0.0005 per text page and $0.003 per OCR page, so a 10-page digital PDF costs $0.005. Blank pages, failed downloads and encrypted or broken files aren't charged.

Which files are not supported?

Password-protected PDFs, legacy .doc, PowerPoint, spreadsheets and web pages. For CSV and Excel files, use Spreadsheet Doctor.

Can it turn bank statement PDFs into a CSV?

Yes, when the transactions sit in a table with drawn cell borders: each table comes back as rows and as CSV. Tables made only of aligned text come through as paragraphs. To merge several months into one clean CSV, pass the table CSVs to Spreadsheet Doctor to standardize dates and amounts and remove duplicate rows. Twelve 3-page text statements cost about $0.03 in total for both steps.

How do I check that a converted bank statement is complete?

Run three quick checks before you import it: the number of transaction rows matches the statement, the opening balance plus credits minus debits equals the closing balance, and the rows just before and after each page break are all there. If a check fails, compare that page with the original PDF.