← Back to blog

How to Extract Text From a PDF and Recognize Scanned Pages

· The MY PDF FIX Team · 4 min read

PDF conversion · Scanned PDFs

The visible words may not be stored as text

A PDF can contain actual text objects, a picture of a printed page, or both. A scanned PDF may have an invisible OCR text layer that lets you search the page. Conversely, a page that looks like ordinary typed text may contain outlines or a photograph and provide nothing useful to a text extractor.

PDF to Text extracts embedded text into a plain .txt file. It does not perform OCR or recover words from images. Its result is a starting point to review, not a guarantee of complete reading order or a faithful table layout.

Practice: compare a text PDF with a scan

Download the editing practice PDF and the dark-scan practice PDF. Both have visible invoice wording, but only the first stores the words as ordinary text objects.

  1. Open PDF to Text and choose the editing practice file.
  2. Click Process and download the .txt output. Open it in a text editor and look for “Invoice Total 125.00” and the later page labels.
  3. Try the dark-scan sample in a new operation. It contains an image, not an OCR layer, so the tool should report the lack of extractable text rather than inventing the invoice wording.
  4. In a PDF reader, try selecting a word and searching for it in each original. These checks help you understand the difference, but selection alone does not prove that every character will extract correctly.

The practice documents are intentionally synthetic. Do not upload a confidential scan to an unfamiliar OCR service just to reproduce this example.

Review the output before reusing it

Compare names, dates, currency amounts and characters that look similar, such as zero and the letter O. A font mapping can produce incorrect or missing characters even when the page renders correctly. Columns, headers, footnotes and tables may be extracted in a different order from how a human reads them.

Plain text does not retain PDF page layout, fonts, images or interactive features. If you need a quotation, compare it with the visible source and retain an appropriate reference to the page. Do not use an unreviewed extraction for important calculations or legal wording.

When OCR is the next step

For an image-only page, use an OCR-capable application approved for the document's sensitivity. Choose suitable language settings, review its result and keep the scan. OCR can create searchable text, but handwriting, poor contrast and unusual layouts can still cause errors.

PDF Fix Hub currently does not include OCR. Adjust PDF Brightness can change the visible tones of a scan, but it does not recognize text and rasterizes the exported pages. Do not assume that brightening alone will create a selectable layer.

Common mistakes and troubleshooting

An empty extraction is not always a damaged PDF. Check whether the page is a scan, whether a selectable layer exists and whether protection prevents processing. Supported protected files can be unlocked with a known password and permission first.

If only one page fails, use Extract Pages to test that page separately. If the words appear but spacing is odd, compare the original's columns and positioned fragments before attempting automatic cleanup.

Frequently asked questions

Does Edit PDF offer OCR? No. Edit PDF can select supported text objects and add notes to scanned pages, but image words are not existing editable text.

Can OCR prove a scanned signature is genuine? No. Text recognition does not authenticate a document or signature.

Are all languages guaranteed? No. Extraction depends on embedded text, encoding and font mappings. Review the language and characters in your own output.

Technical reference: PDF.js text-content extraction API.