# PDF Text Extractor: Text, Pages, Metadata & Links (Bulk) (`globose_talent_mn9/pdf-text-extractor`) Actor

Extract text from PDF URLs in bulk: full text plus text per page, word counts, title, author, dates, page count and embedded links. Ready for RAG, LLMs, search and data pipelines. No OCR; scanned PDFs are free. $2 per 1,000 PDFs.

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

## Pricing

from $2.00 / 1,000 pdf extracteds

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

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: text, pages, metadata and links from PDF URLs

Turn any list of PDF links into clean, structured text. For every PDF you get the **full text**, the **text of each page**, word and character counts, **title, author, subject, keywords, creation and modification dates**, page count, file size and every **hyperlink embedded in the document**.

It's built for RAG and LLM pipelines, search indexing, research, compliance archives, invoice and report processing, and anyone who needs PDF content as JSON, CSV or Excel without running their own parser.

### Why this Actor

- **$2 per 1,000 PDFs** (+ a $0.00005 start fee). The price is per PDF, not per page, so a 300-page report costs the same as a one-pager.
- **You only pay for PDFs with text.** Broken links, non-PDF URLs, files over your size limit and scanned (image-only) PDFs are returned with an error message and are **free**.
- **Text per page** plus full text in one row, ready for chunking.
- **Metadata and links** included at no extra cost.
- Fast and light: pure text-layer extraction (Mozilla pdf.js), 512 MB memory by default, several PDFs in parallel.

### Input

| Field | Description |
|---|---|
| `pdfUrls` | Direct PDF links, one per line. Redirects are followed. |
| `includePages` | Add a `pages` array with each page's text (default on). |
| `includeLinks` | Return the URLs embedded in the PDF (default on). |
| `maxPagesPerPdf` | Only extract the first N pages (0 = all). |
| `maxFileSizeMb` | Skip bigger files for free (default 50, max 200). |
| `maxPdfs` | Stop after N URLs (0 = no limit). |
| `concurrency` | PDFs processed in parallel (1–10, default 3). |

```json
{ "pdfUrls": ["https://www.irs.gov/pub/irs-pdf/fw9.pdf", "https://arxiv.org/pdf/1706.03762"] }
```

### Output

One dataset item per PDF:

```json
{
  "url": "https://www.irs.gov/pub/irs-pdf/fw9.pdf",
  "finalUrl": "https://www.irs.gov/pub/irs-pdf/fw9.pdf",
  "fileSizeBytes": 140815,
  "totalPages": 6,
  "pagesExtracted": 6,
  "title": "Form W-9 (Rev. March 2024)",
  "author": "SE:W:CAR:MP",
  "subject": "Request for Taxpayer Identification Number and Certification",
  "createdAt": "2024-03-06T13:18:13.000Z",
  "pdfVersion": "1.7",
  "wordCount": 6278,
  "charCount": 37693,
  "hasTextLayer": true,
  "text": "Form W-9 (Rev. March 2024) Request for Taxpayer Identification Number ...",
  "pages": [{ "page": 1, "text": "...", "wordCount": 1012 }],
  "links": [],
  "error": null
}
```

Very large documents (over about 4 million characters) keep the first part in `text` and link the complete text file in `fullTextUrl`.

Export the dataset as JSON, CSV, Excel or HTML, or read it through the Apify API and integrations (Make, Zapier, n8n, LangChain, LlamaIndex).

### Limits

- **No OCR.** Scanned or image-only PDFs have no text layer; they are flagged with `hasTextLayer: false` and not charged.
- Password-protected PDFs can't be opened and are free.
- Only process documents you are allowed to access and use.

### Related tools

Website Contact Details Scraper, SEO Audit Crawler, Sitemap URL Extractor, RSS Feed Reader and Wayback Machine Snapshots by the same author.

### Related Actors

#### Documents suite

- [Scanned PDF & Image OCR](https://apify.com/globose_talent_mn9/pdf-image-ocr)
- [Article Extractor](https://apify.com/globose_talent_mn9/article-extractor)
- [URL & HTML to PDF Converter](https://apify.com/globose_talent_mn9/url-to-pdf)

#### SEO & web suite

- [SEO Audit Crawler](https://apify.com/globose_talent_mn9/seo-audit-crawler)
- [Broken Link Checker](https://apify.com/globose_talent_mn9/broken-link-checker)
- [Sitemap URL Extractor](https://apify.com/globose_talent_mn9/sitemap-urls)
- [Bulk Redirect Checker](https://apify.com/globose_talent_mn9/redirect-checker)
- [Website Metadata / Open Graph Extractor](https://apify.com/globose_talent_mn9/website-metadata-extractor)
- [Website Screenshot](https://apify.com/globose_talent_mn9/website-screenshot)
- [Website Image Extractor](https://apify.com/globose_talent_mn9/website-image-extractor)
- [SSL Certificate Checker](https://apify.com/globose_talent_mn9/ssl-certificate-checker)
- [Subdomain Finder](https://apify.com/globose_talent_mn9/subdomain-finder)
- [DNS & Email Security Checker (SPF/DKIM/DMARC)](https://apify.com/globose_talent_mn9/dns-email-security-checker)
- [WHOIS Domain Lookup](https://apify.com/globose_talent_mn9/whois-domain-lookup)
- [Domain Availability Checker](https://apify.com/globose_talent_mn9/domain-availability-rdap)
- [Tech Stack Detector](https://apify.com/globose_talent_mn9/tech-stack-detector)

#### Jobs suite

- [Greenhouse Jobs API](https://apify.com/globose_talent_mn9/greenhouse-jobs-api)
- [Lever Jobs API](https://apify.com/globose_talent_mn9/lever-jobs-api)
- [Ashby Jobs API](https://apify.com/globose_talent_mn9/ashby-jobs-api)
- [Workday Jobs API](https://apify.com/globose_talent_mn9/workday-jobs-api)
- [Company Jobs API (10 ATS)](https://apify.com/globose_talent_mn9/ats-jobs-api)
- [Remote Jobs Aggregator](https://apify.com/globose_talent_mn9/remote-jobs-aggregator)

#### Also by us

- [Wayback Machine Snapshots](https://apify.com/globose_talent_mn9/wayback-machine-snapshots)
- [RSS Feed Reader](https://apify.com/globose_talent_mn9/rss-feed-reader)
- [Website Contact Details Scraper](https://apify.com/globose_talent_mn9/website-contact-details-scraper)

# Actor input Schema

## `pdfUrls` (type: `array`):

Direct links to PDF files, one per line. Redirects are followed.

## `includePages` (type: `boolean`):

Add a 'pages' array with the text and word count of each page, next to the full text.

## `includeLinks` (type: `boolean`):

Return the unique hyperlinks (URLs) embedded in the PDF.

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

Only extract the first N pages of each PDF. 0 = all pages. The price is per PDF either way.

## `maxFileSizeMb` (type: `integer`):

Skip PDFs larger than this (free). Up to 200 MB; large files need more memory.

## `maxPdfs` (type: `integer`):

Stop after this many URLs. 0 = no limit.

## `concurrency` (type: `integer`):

How many PDFs to process at once (1-10).

## Actor input object example

```json
{
  "pdfUrls": [
    "https://www.irs.gov/pub/irs-pdf/fw9.pdf",
    "https://arxiv.org/pdf/1706.03762"
  ],
  "includePages": true,
  "includeLinks": true,
  "maxPagesPerPdf": 0,
  "maxFileSizeMb": 50,
  "maxPdfs": 0,
  "concurrency": 3
}
```

# Actor output Schema

## `overview` (type: `string`):

All extracted PDFs in the default dataset, shown with the 'overview' table view.

## `summary` (type: `string`):

Counts of extracted, text-less and failed PDFs.

# 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 = {
    "pdfUrls": [
        "https://www.irs.gov/pub/irs-pdf/fw9.pdf",
        "https://arxiv.org/pdf/1706.03762"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("globose_talent_mn9/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 = { "pdfUrls": [
        "https://www.irs.gov/pub/irs-pdf/fw9.pdf",
        "https://arxiv.org/pdf/1706.03762",
    ] }

# Run the Actor and wait for it to finish
run = client.actor("globose_talent_mn9/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 '{
  "pdfUrls": [
    "https://www.irs.gov/pub/irs-pdf/fw9.pdf",
    "https://arxiv.org/pdf/1706.03762"
  ]
}' |
apify call globose_talent_mn9/pdf-text-extractor --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,globose_talent_mn9/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/h6jGpuygOC6Pw3pO4/builds/JgNTwIIMHwHcj64DP/openapi.json
