PDF to Markdown API for bulk conversion
For one or a few PDFs use the free PDF to Markdown converter on this site: it runs in your browser and uploads nothing. For batches, automation, ruled-table detection and automatic OCR of scanned pages, use the pdf-to-markdown robot on Apify: pass a list of PDF URLs and get Markdown back. It costs $0.003 per PDF, plus $0.01 per OCR page.
Browser tool or API?
The browser converter is private and free but handles one file at a time, keeps table text line by line and cannot OCR scans. The robot processes lists of URLs in parallel, detects ruled tables and outputs real Markdown tables, and OCRs pages that have no text layer.
Options
pdfUrls, extractTables, ocrScannedPages with ocrLanguage (for example eng, fra, deu, spa), maxPages to cap long documents, and maxConcurrency.
Example call
curl -X POST "https://api.apify.com/v2/acts/extas_corp~pdf-to-markdown/run-sync-get-dataset-items?token=YOUR_TOKEN" \
-H "Content-Type: application/json" \
-d '{"pdfUrls":[{"url":"https://example.com/report.pdf"}],"extractTables":true,"ocrScannedPages":true}'Typical uses
Feeding contracts, manuals or papers into a RAG pipeline (see PDF to Markdown for RAG), archiving scanned invoices as searchable text, or preparing a document set for ChatGPT or Claude. The same engine is also offered on RapidAPI as the Document to Markdown API.
Pricing
$0.003 per PDF, and $0.01 per page only for pages that needed OCR. The free converters on this site run in your browser; the Apify robots are for automation and volume. You pay only per result, with no monthly fee for the robot itself.
What one result looks like
The robot returns one dataset item per PDF. Besides the Markdown it reports what it did, so a pipeline can check each file without opening it:
{
"url": "https://example.com/report.pdf",
"status": "ok",
"markdown": "# Annual report\n\n## Revenue\n\n| Year | Revenue |\n|---|---|\n| 2024 | 1.2M |...",
"pageCount": 24,
"pagesProcessed": 24,
"ocrPages": 3,
"tableCount": 5,
"charCount": 48210,
"title": "Annual report",
"author": null
}
A PDF that cannot be downloaded or read gives "status": "error" with the reason, and the other files in the run continue. Failed PDFs are not charged.
Cost of a real batch
Take 1,000 PDFs where 50 are scans of about 4 pages each. Text PDFs: 1,000 × $0.003 = $3. OCR pages: 200 × $0.01 = $2. Total: about $5 for the batch. If you know all files are digital (exported from Word or a reporting tool), turn ocrScannedPages off and the cost is the $3 per-PDF fee only. Use maxPages when you only need the first pages of long documents, for example the summary of each report.
Checks before you feed the output to an LLM
- Filter on status. Drop or retry items with
"status": "error". - Watch charCount. A 20-page PDF with a few hundred characters is a scan that was not OCR'd, or an image-only file.
- Compare pageCount and pagesProcessed. They differ when
maxPagescut the document short. - Spot-check tables. Ruled tables become Markdown tables; tables drawn with spaces only stay as text lines.
- Split on headings. For RAG, cut the Markdown on
#and##and keep the heading path with each chunk.
FAQ
Does it handle scanned PDFs?
Yes. Pages without a text layer are OCR'd automatically when ocrScannedPages is on.
Is my file stored?
Files are processed for the run. Apify keeps run datasets according to your account retention settings; do not send documents you are not allowed to process.
Is there a free option?
Yes, the browser converter on this site is free and unlimited for single files.
What happens if one PDF in the batch fails?
It gets status "error" with the reason, the rest of the run continues, and you are not charged for it.
Last updated: November 2026. Facts about third-party tools come from their public repositories and documentation. Check licenses before commercial use.