# PDF to Markdown Extractor: Page Numbers & Tables

> PDF to Markdown extractor: convert PDF to Markdown and plain text from URLs with Page N markers, headings, tables, and links for RAG and LLM pipelines. No OCR: fully scanned PDFs and failed downloads are free.

- **Page:** https://kizukidata.com/actors/pdf-to-markdown/
- **Markdown:** https://kizukidata.com/actors/pdf-to-markdown.md
- **Categories:** AI, Developer tools, Automation
- **Returns only changed items:** no
- **On Apify Store:** yes

## Pricing

USD 1.60 per 1,000 documents on Free; USD 1.45 on Starter, USD 1.31 on Scale, USD 1.09 on Business

## Run it

[View on Apify Store](https://kizukidata.com/go/pdf-to-markdown)

## What it does

Convert PDF to Markdown and plain text from direct PDF URLs: one row per file with `## Page N` markers, headings, tables, and links ready for RAG pipelines, LLMs, and searchable citations.

Empty input (`{}`) converts two small sample PDFs in about three seconds.

## How to use it

1. Copy the **file URL** of each PDF (the address ends in `.pdf` or serves the file directly — not a page that
   shows a PDF viewer).
2. Paste the URLs into **PDF URLs** (`pdfUrls`), one per entry.
3. Optionally set **Maximum PDFs** (`maxItems`), **Maximum pages per PDF** (`maxPages`), **Maximum file size** and **Maximum characters per
   PDF**.
4. Run the Actor and read the dataset, or take the `markdown` field of each row.

For web pages instead of PDFs, URL to Markdown does the same without a browser.

### Input example

```json
{
    "pdfUrls": [
        "https://example.com/annual-report-2025.pdf",
        "https://example.com/whitepaper.pdf"
    ],
    "maxPages": 100,
    "maxItems": 10
}
```

## Inputs

| Input | Type | Required | Default | Description |
| --- | --- | --- | --- | --- |
| PDF URLs (`pdfUrls`) | array | No | `https://pdfobject.com/pdf/sample.pdf, https://www.orimi.com/pdf-test.pdf` | Up to 100 direct PDF file URLs (not HTML viewer pages). Empty converts 2 sample PDFs. Local/private IPs refused; failed downloads are free. |
| Maximum PDFs (`maxItems`) | integer | No | `5` | Max PDFs to convert per run (1-100, default 5). Each converted PDF is charged; PDFs beyond the cap are listed in OUTPUT skippedInputs. |
| Maximum pages per PDF (`maxPages`) | integer | No | `100` | Max pages read per PDF (1-500, default 100). Longer PDFs return the first pages and set truncated: true; pageCount shows full length. |
| Maximum file size (MB) (`maxMbPerFile`) | integer | No | `50` | Max PDF size in MB (1-50, default 50; oversized files are free). Default 1 GB RAM converts up to ~40 MB; raise to 2 GB for 50 MB (min 1 GB). |
| Maximum characters per PDF (`maxChars`) | integer | No | `400000` | Character cap for Markdown and text per PDF (1000-500000, default 400000). Longer output is cut with truncated: true. |
| Respect robots.txt (`respectRobotsTxt`) | boolean | No | `true` | true (default) skips PDFs disallowed by robots.txt (listed in OUTPUT, free); false ignores robots.txt (use only when allowed). |

Advanced: `proxyConfiguration` is available for proxy settings and is not required.

## Output

| Field | Type | Description |
| --- | --- | --- |
| `id` | string | Stable ID of the document: a SHA-256 prefix of its URL. |
| `source` | string | "pdf": the row comes from this Actor. |
| `url` | string | URL of the PDF as you gave it. |
| `finalUrl` | string | URL the file was served from, after redirects. |
| `title` | string \| null | Title stored in the PDF metadata, when it has one. |
| `status` | string | "ok" when the text layer gave text; "scan" when it gave none (a scan without OCR, or a document whose every page holds only a page number or a stamp); "failed" when the file could not be downloaded or converted, with the reason in error. A scan or failed row is written so the URL is never silently missing, and it is not charged. |
| `pageCount` | integer | Pages in the file. |
| `pagesReturned` | integer | Pages included in markdown and text (at most maxPages). |
| `markdown` | string | The document as Markdown: the title (if any), then one "## Page N" section per page. Headings, lists, tables, links, bold and italic come from the converter; its own headings sit two levels below the page marker. A page with no text layer says so; a page with only a short line (a page number, a stamp, a caption) keeps that line and gets a note under it. |
| `text` | string | The same text as plain text, with a "Page N" line before each page. Markup is removed; wording is kept. |
| `charCount` | integer | Characters in text. |
| `byteCount` | integer | Size of the downloaded file in bytes. |
| `truncated` | boolean | True when maxPages or maxChars cut the document. |
| `scrapedAt` | string | When the document was converted, ISO 8601 (UTC). |
| `pdfType` | string \| null | How the converter classified the document. null when only the fallback converter ran. |
| `pagesNeedingOcr` | array | 1-indexed returned pages that are scans and need OCR. A page is listed when it has no text, or when its text is short (under 50 characters) and it draws a full-page image, or its text sits only in the header or footer (a running head, a page number, a stamp). A short page of a normal document (a chapter's last lines, a caption) is not listed. The text that was read stays in markdown, with a one-line note under a listed page. |
| `truncatedBy` | string \| null | Which cap cut the document: "pages" (maxPages) or "chars" (maxChars); null when nothing was cut. |
| `error` | string \| null | A fixed sentence on a "failed" row saying why the file could not be converted; null otherwise. |

## Sources and limits

- The PDFs you name: One HTTP request per PDF.

### Limitations

- **Independent tool, no login.** Not affiliated with, endorsed by or sponsored by any of the sites whose documents you convert. Needs no login or account.
- **No OCR, no layout reconstruction.** Scanned PDFs without a text layer are not charged and return `pagesNeedingOcr` (including scanned pages with page numbers/header stamps or full-page figure images; short normal text pages are not flagged). Scanned pages carry a one-line note, and extracted text is kept within `maxChars`. The text is only as good as the PDF's text layer; a scan is reported, not
  read.
- **One request per PDF.** A server that requires a login, a CAPTCHA or JavaScript to serve the file can not be
  read; a redirect to a login page is reported as `the response was not a PDF`.
- **Files over `maxMbPerFile` are not converted**: they are listed in OUTPUT `skippedInputs` and not charged (a
  body above the Actor's absolute limit comes back as an uncharged `failed` row).
- **A big file needs memory.** The converter works on the whole file at once. With the default 1 GB, files up to
  about 40 MB are converted; a larger file (up to the 50 MB limit) is skipped with a reason that names the memory
  it needs, instead of failing the run. Raise **Memory** to 2 GB for the largest files. Runs do not start below
  1 GB.
- **Only `http` and `https` URLs** are accepted, and local and private addresses are refused (loopback, private
  ranges, link-local) so the Actor can not be pointed at the platform's internal network.
- **No links are followed.** The Actor reads exactly the URLs you give it, once each, and does not crawl.

### Run status and the OUTPUT record

Each run ends with a short status message and writes an `OUTPUT` record to its key-value store with the counts
(requests, documents read, documents returned, blocked requests) and:

- `skippedInputs`: entries that were invalid, duplicated, not a PDF, too large, unreadable, too large for this
  run's memory, disallowed by robots.txt, or over `maxItems`, with their position in your list and the reason.
  None of them is charged;
- `uncheckedInputs`: entries the run did not reach because it stopped first (no budget left, or the site refused
  too many requests). Entries over `maxItems` are in `skippedInputs`, not here.

A run **succeeds** whenever it accounts for every URL you listed: a file that is not a PDF, or a page the site
disallows, is skipped with a reason; a scan comes back as an uncharged `scan` row; a download that failed, or a URL
that did not answer at all, comes back as an uncharged `failed` row with a fixed reason. A run is marked **FAILED**
only when the Actor itself hit an unexpected error; its log has the details, and an Issue with the run ID helps.

The run's `code` names why a run returned nothing. A URL that answers 404 or 410, or a response that is not a PDF,
is `input_not_found`; a run whose every URL was too large for the memory it was given is `insufficient_memory`
(raise **Memory** and run again, though the file can still fail for another reason). Both are successful runs and
charge nothing.

Read the data-source note: https://kizukidata.com/data-sources/#pdf-to-markdown

## Billing

Apify charges per result; the Store page is the commercial reference. Rows that only record a failure are not charged. Every run also carries a start fee of USD 0.00005 per GB of memory (USD 0.00005 at the default 1 GB), even a run that returns no results.

## Verification

The facts on this page come from the Actor's own documentation and its input and dataset schemas. No customer testimonials, ratings, or uptime numbers are shown.

## All Kizuki Actors

https://kizukidata.com/actors/ · https://kizukidata.com/llms.txt
