Convert PDFs to Markdown for RAG and LLMs
Klarto
Turns PDF links into clean Markdown and plain text with headings, lists and ruled tables kept, ready for RAG pipelines, vector databases and LLM prompts. Pages with a text layer are read directly; scanned pages are OCR'd automatically. This example converts the IRS W-9 form.
Input
Output fields
Sign up on Apify or log in
The PDF & Image OCR to Text and Markdown Actor is ready to run with the inputs already set for "Convert PDFs to Markdown for RAG and LLMs". Sign up or log in and you'll land in Apify Console with a copy of this exact task.
Start the "Convert PDFs to Markdown for RAG and LLMs" task
The PDF & Image OCR to Text and Markdown Actor will start running based on the input automatically. You can also change all the input fields, like file urls and OCR mode, to match your specific use case.
Receive the "Convert PDFs to Markdown for RAG and LLMs" output
Monitor the progress in real time. You will be notified as soon as your dataset is complete and ready for review. Each result includes data such as file, status, markdown, and more.
Integrate into your workflow
The final output is delivered in JSON, CSV, or Excel format, ready to be plugged into your workflow. You can also run the "Convert PDFs to Markdown for RAG and LLMs" task via API.

Integrate "Convert PDFs to Markdown for RAG and LLMs" into your workflow
Connect "Convert PDFs to Markdown for RAG and LLMs" with 100+ integrations, or run it via API or MCP.
Webhook
n8n
Make
Zapier
Airbyte
Keboola
IFTTT
Hubspot
GDrive
Gmail
Apify MCP
GitHub
Slack
LangChain
LlamaIndex
Flowise
Pinecone
OpenAI
Mastra
Clay
The PDF to Markdown task returns one item per file with the Markdown text, plain text, page counts, OCR languages and a status. A run summary is saved as the OUTPUT record in the run's key-value store.
Yes. The PDF to Markdown task reads the text layer where there is one and runs Tesseract OCR only on pages without usable text, so mixed PDFs work in one run.
Converting a PDF to Markdown costs $0.001 per page read from the text layer and $0.005 per OCR page. Blank and failed pages are free. Apify adds a start event of $0.0001 per run at 2 GB.
The PDF to Markdown task accepts up to 1,000 direct file links per run, including Dropbox and Google Drive share links that are converted to direct downloads.