# PDF Text Extractor & Parser — OCR for Scans, Changed Pages (`northbell/pdf-text-extractor`) Actor

Paste PDF links and get the text of every page, plus title, dates and page count. Scanned pages are read with OCR (19 languages). Run it again and get only the PDFs and pages whose text changed. Good for price lists, policies, menus and reports. $3 per 1,000 PDFs.

- **URL**: https://apify.com/northbell/pdf-text-extractor.md
- **Developed by:** [Northbell](https://apify.com/northbell) (community)
- **Categories:** AI, Developer tools
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $2.40 / 1,000 pdfs

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## PDF Text Extractor & Parser — Text, OCR for Scans & Only Changed Pages

Paste **PDF links** and get the **text of every page** as clean JSON, with the **title, subject, creation and modification dates, page count and file size**. **Scanned pages are read with OCR** (19 languages, including Japanese, Chinese, Korean and Arabic). Turn on **One row per page** for long documents or RAG chunks. Schedule it with **Only new and changed PDFs** and you get back only the PDFs whose text changed since the last run — with the **numbers of the pages that changed** — so you can watch price lists, policies, terms, menus, tenders and reports without reading them again.

**Try it now. The input is already filled in.** Press **Start**: the IRS Form W-9 PDF — **6 pages, 6,285 words of text in about 7 seconds, for $0.013** (measured on 28 Oct 2026). The row:

| `title` | `pageCount` | `words` | `hasText` | `ocrPages` |
| --- | --- | --- | --- | --- |
| Form W-9 (Rev. March 2024) | 6 | 6,285 | true | \[] |

The row also has the full `text`, author, subject, dates and a SHA-256 fingerprint. Run it again and `status` says whether the PDF changed, and `changedPages` which pages.

### What you get

| Row | Fields |
|---|---|
| `pdf` | `url`, `title`, `author`, `subject`, `keywords`, `creator`, `producer`, `createdAt`, `modifiedAt`, `pdfVersion`, `pageCount`, `pagesRead`, `fileBytes`, `sha256`, `status` (`new` / `changed` / `unchanged`), `changedPages`, `removedPages`, `hasText`, `textChars`, `words`, `ocrPages`, `ocrConfidence`, `text`, `note` |
| `page` | `url`, `page`, `pageCount`, `text`, `chars`, `words`, `ocr`, `changed` (with *One row per page*) |
| `error` | `url`, `message` — free |

`author` is the PDF's own *Author* field, as the file states it.

### Use it for

- **Watching documents that change quietly**: supplier price lists, terms of service, privacy policies, school menus, council minutes, tender documents: schedule it daily and get a row only when the text changes, with the changed pages
- **AI and RAG**: page-level text ready for chunking and embedding, refreshed only where it changed
- **Document inventories**: title, dates and page counts for a list of PDFs
- **Search and analysis**: full text of reports and filings for keyword search or LLM summaries

### Input

```json
{ "urls": ["https://www.irs.gov/pub/irs-pdf/fw9.pdf"], "splitPages": true, "onlyChanged": true }
```

Measured on 23 October 2026: the 6-page IRS Form W-9 (6,285 words) in 1.4 seconds.

### How it reads

- Each site's **robots.txt is read first** (the rules for all robots and those addressed to Claude crawlers); links it does not allow are skipped with a free error row. Links to private networks are not read.
- The file is downloaded over plain HTTP (no browser, no login) and read with PDF.js. **Scanned pages are read with OCR** (Tesseract, inside the run — the file is not sent to another service): a page without a text layer has its picture read in the language(s) you pick under *OCR languages*. `ocrPages` lists those pages and `ocrConfidence` their average confidence; OCR text can contain mistakes. Turn off *Read scanned pages (OCR)* to skip them.
- *Only new and changed PDFs* compares each page's text with this Actor's last run on the same link. A PDF whose file is byte-for-byte the same is not even re-read.

### Pricing

**$3 per 1,000 PDFs** ($0.003 each, page rows included), plus **$3 per 1,000 pages read with OCR** ($0.003 per scanned page where OCR found text) and $0.01 per run. Error rows, PDFs with no text at all and unchanged PDFs (with *Only new and changed PDFs*) are free. The $0.01 run-start fee is the one charge every run pays, even one that returns nothing.

### For AI agents

`{"urls": ["https://example.com/report.pdf"], "splitPages": true}` returns one `pdf` row with the details and one `page` row per page with its text. Rows have `type`: `pdf`, `page` or `error`.

# Actor input Schema

## `urls` (type: `array`):

One direct link to a .pdf file per line. Each site's robots.txt is checked first; links it does not allow are skipped with a free error row.

## `splitPages` (type: `boolean`):

Off: one row per PDF with the whole text. On: one row per PDF with the details, plus one row per page with that page's text (best for long documents and for RAG chunks).

## `onlyChanged` (type: `boolean`):

Compare with the last run of this Actor on the same link. Unchanged PDFs return nothing and are not charged. A changed PDF lists which pages changed; with One row per page on, only the changed pages are returned. The first run returns everything.

## `ocr` (type: `boolean`):

Pages without a text layer (scans, photos of documents) are read with OCR inside the run. $0.003 per page read with OCR, on top of the PDF price. Pages that already have text are never OCR'd.

## `ocrLanguages` (type: `array`):

The language(s) of the scanned text, up to 3. Each extra language makes OCR slower and a little less accurate.

## `maxPagesPerPdf` (type: `integer`):

Pages read from each PDF, from the start.

## `maxFileMb` (type: `integer`):

Larger files are skipped with a free error row.

## Actor input object example

```json
{
  "urls": [
    "https://www.irs.gov/pub/irs-pdf/fw9.pdf"
  ],
  "splitPages": false,
  "onlyChanged": false,
  "ocr": true,
  "ocrLanguages": [
    "eng"
  ],
  "maxPagesPerPdf": 500,
  "maxFileMb": 50
}
```

# Actor output Schema

## `pdfs` (type: `string`):

Title, status since the last run, changed pages, page count and text of every returned PDF.

## `pages` (type: `string`):

One row per page with its text (when One row per page is on).

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "urls": [
        "https://www.irs.gov/pub/irs-pdf/fw9.pdf"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("northbell/pdf-text-extractor").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = { "urls": ["https://www.irs.gov/pub/irs-pdf/fw9.pdf"] }

# Run the Actor and wait for it to finish
run = client.actor("northbell/pdf-text-extractor").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "urls": [
    "https://www.irs.gov/pub/irs-pdf/fw9.pdf"
  ]
}' |
apify call northbell/pdf-text-extractor --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,northbell/pdf-text-extractor"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/41zVhHeGN9Z79tZp9/builds/fzFzWekbRF4syFdD7/openapi.json
