---
title: Extract Text from PDF API
slug: extract-text-from-pdf
url: https://apyhub.com/apyhub/service/extract-text-from-pdf
provider: ApyHub
categories: [Data Extraction, File Manipulation]
auth: api_key
---

# Extract Text from PDF API

Extract text from a PDF by URL or file upload. Supports page ranges and region bounds, returning plain text in a single data field.

## Endpoints

| Method | Path | Description | Atoms |
| --- | --- | --- | --- |
| POST | `/extract/text/pdf-url` | What it does Extracts text from a PDF located at a remote URL and returns the extracted content as… | 50 |
| POST | `/extract/text/pdf-file` | What it does Uploads a PDF file and extracts text from it. You can optionally limit extraction to a… | 50 |

## About

## What it does
PDF Text Extraction lets you send a PDF from a remote URL or upload a PDF file and get the extracted text back in a single `data` field. Use it when you need the readable text from reports, invoices, contracts, or scanned documents without building your own parser.

With `POST /url`, pass a `url` to a PDF and optional page controls: `start_page`, `end_page`, and coordinate bounds with `starting_x_coordinate`, `starting_y_coordinate`, `ending_x_coordinate`, and `ending_y_coordinate`. Set `preserve_paragraphs` when you want the output to keep paragraph structure. With `POST /file`, upload the PDF as `file` and use the same page and coordinate options, including `preserve_paragraphs`.

The response is intentionally simple: `data` contains the extracted text as a string. That makes PDF Text Extraction easy to drop into indexing pipelines, document search, compliance review, content migration, or any workflow where you need text before further processing.

If you only need text from specific pages or a defined region of a page, the page and coordinate filters help you narrow the extraction without post-processing the full document.

## Usage

Authenticate with an ApyHub API key in the `apy-token` header.
Full docs and a live playground: https://apyhub.com/apyhub/service/extract-text-from-pdf
