Extract Page-Labeled Text From a Scanned PDF
Extract Text from Scanned PDF recognizes image pages in the languages you choose and returns a .txt file with a heading before each page, so every passage can be traced to its page. Pages that already have text are copied unchanged.
Drag and drop files here, or click to choose
Accepts PDF · up to 500.0 MB per file · up to 20 files at once
You can also paste a file with Ctrl/Cmd+V, or from the clipboard menu.
Quoting a scanned report or loading it into a notes system is much easier when each passage knows its page. This page is preset to add a heading such as --- Page 7 --- before the text of every page, so a search hit or a quotation can be traced back to the scan. You can turn the headings off if you only want running text.
Pages with no text layer are rendered and recognized with Tesseract in the languages you choose, up to four. Pages that already contain text are copied from the PDF rather than recognized again. A page range lets you extract only the chapter you need, and up to 50 pages that need recognition are processed per request on this site, with files up to 500 MB.
The output is plain text: layout, columns and tables are not preserved, and OCR can misread blurry or small print. Review figures and names before you rely on them. For headings and lists use OCR to Markdown, and for rows and columns use the table tool.
Features
- A heading before every page, preset on this page
- Existing text copied, scanned pages recognized
- Up to four languages and an optional page range
- Plain .txt output that is easy to index or quote
- Page and file-size limits stated on the page
When to use this tool
- Citing passages from a scanned report with page references
- Loading a scanned book chapter into a notes or retrieval tool with page labels
- Checking which page a phrase came from
How do I extract text from a scanned PDF with page numbers?
- Upload the scanned PDF
- Choose the languages and, if wanted, a page range
- Leave the page headings on
- Click Process and download the .txt file
Limits and edge cases
- Up to 50 pages that need OCR per request on this site
- Plain text only; layout and tables are not preserved
- Accuracy depends on the scan and the selected languages
Test results and conditions
- Test files: one-page scans made for this project's test suite (200 dpi, light blur and noise, 0.4 degree skew). The result began with the line --- Page 1 --- followed by the recognized text, ready to quote with a page reference.
- The page number is the page's position in the file, not a number printed on it.
Privacy for this tool
Files are uploaded over HTTPS, processed in memory or a short-lived temporary directory on our servers, and deleted when your result is ready. We do not keep copies for later browsing, training, or advertising profiles. See the Privacy Policy for retention details and AdSense cookie disclosures.
Frequently asked questions
- What do the page headings look like?
- A line such as --- Page 3 --- before the text of page 3. You can switch them off in the options if you want continuous text.
- Are the page numbers the PDF's own page numbers?
- They are the position of the page in the PDF file, counting from 1, not any number printed on the page.
- Can I extract only some pages?
- Yes. Enter a range such as 5-12 in the page field and only those pages are read.
- How is this different from Scanned PDF to Text?
- It is the same engine, preset to label each page. Scanned PDF to Text gives continuous text by default.
Last updated:
Call this from code
Every tool on this site is a plain REST endpoint - no account or API key needed for anonymous use. Built for AI agents and developers as much as for browsers.
curl -X POST "https://pdf123.xyz/api/v1/misc/ocr-text" \
-F "[email protected]" \
-F "languages=eng" \
-F "ocrType=Normal" \
-F "pageMarkers=false" \
-F "pageNumbers=all" \
-o output.pdfAlso available as an MCP tool for agent clients that speak Model Context Protocol (JSON-RPC 2.0 over POST /mcp). Full API reference
Use it from an AI agent
SkillClaude Code, Codex, Cursor and other AI agents can run OCR PDF to Text for you with this skill: /skills/pdf123-ocr-text.md
Files are used only for this processing job and deleted automatically afterward.