How to extract text from a scanned PDF (and what to check afterwards)

By the Osmanth team at Osmanth Docs · Published 2026-10-03

If you cannot select any text in a PDF, it is probably a scan: a picture of each page with no text inside. A program has to read the picture with OCR (optical character recognition) to get the words out. This guide shows how to tell, what a real OCR run produced on our sample, and what to check afterwards.

First, is it really a scan?

The quickest test: open the PDF and try to select a word with your mouse. If a word highlights, the text is already in the file and you may not need OCR at all. If nothing highlights, or a whole page selects as one block, the page is an image.

A file can also be mixed, with some pages that have real text and some that are pictures. The tool on this site checks each page, and reads only the pages without text with OCR. It is built on Docling, whose documentation lists OCR support for scanned PDFs and images. It tells you what it found: the result is marked as a digital PDF, a scanned PDF, or a mixed one, and for a scan the notes say that the text was recognised with OCR.

What OCR does

OCR looks at the image of a page, finds the lines and words, and writes down the characters it believes it sees. It is very good on clean, straight, sharp pages and gets worse as the page gets worse: faint print, shadows, tilted or curved pages, and tiny type all make mistakes more likely.

A worked example

To see what a real run produces, we tested a one-page memo with invented text, turned it into an image with a slight tilt and some speckle, and saved it as a PDF with no text inside, to imitate a scan. Real scans vary a lot, so treat this as an illustration, not a measurement. We uploaded it to PDF to Text on this site.

The original text:

Memo: warehouse move
The warehouse on Harbour Road closes on 31 October. All stock must be counted before the move.
Please check the following before Friday:
1. Pallet labels match the stock list.
2. Damaged items are tagged and photographed.
3. Keys are returned to the front office.
Questions go to the operations desk. Sample text, invented for this guide.

What came out:

MEMO: WAREHOUSE MOVE

The warehouse on Harbour Road closes on 31 October. All stock must be counted before the move.

Please check the following before Friday:

• Pallet labels match the stock list.

• Damaged items are tagged and photographed.

• Keys are returned to the front office.

Questions go to the operations desk. Sample text, invented for this guide.

Every word was read correctly, but three things changed, and the result was still labelled "Looks good":

  • The title came out in capitals. The original was "Memo: warehouse move".
  • The numbered list became bullets. The numbers 1, 2 and 3 were lost. For a checklist that is harmless, but for a legal clause or a step-by-step procedure it would not be.
  • Lines were joined into paragraphs. The wrapped sentence in the original is now one line. That is by design for clean text, because the line breaks of a printed page are rarely wanted.

The lesson is that "Looks good" means the tool saw no warning signs. It does not mean the output is identical to the page. Wherever the exact form matters, compare against the original.

One thing that surprises people: "Raw text" is empty for scans

The download options include both Clean text and Raw text. Raw text is the text that is already embedded in the PDF, and a scan has none, so for our example it contained only a page marker. For scanned documents, use the Clean text.

What to check afterwards

  • Names, numbers and dates. These are where a misread character does the most damage. OCR commonly confuses characters that look alike, such as the digit 0 and the letter O.
  • Anything with numbering or structure. As the example shows, lists, headings and clause numbers can change.
  • The overall length. If a page looks full but the result is short, part of it may not have been read.

What reads poorly

Dense scanned tables, such as old statistical reports, are often not read reliably on this site, and the results are marked for review rather than presented as correct. The about page says so. For a table inside a scan, expect to compare the numbers against the original, line by line. If you need the numbers in a spreadsheet, this guide on getting a PDF table into Excel covers what to check.

Getting a better scan

Tesseract, a widely used open-source OCR engine, documents what helps. Our tool uses a different engine, so treat this as general OCR advice rather than a description of how ours behaves.

  • Scan at a resolution of at least 300 dpi. Tesseract's documentation says it works best on images of that resolution or higher.
  • Keep the page straight. A skewed page makes it harder to find the lines of text.
  • Crop away dark scanner edges. Tesseract's documentation warns that they can be read as extra characters.
  • Keep the page free of speckle and noise, which also make text harder to read.

What happens to your file

PDF to Text uploads your PDF to our servers, where open-source software processes it, including the OCR step. It is not sent to any third-party AI or document API. The uploaded PDF is deleted as soon as processing finishes, and the results stay for 60 minutes so you can download them. Files can be up to 50 MB and 100 pages. If a file must not leave your device, do not upload it. The privacy page has the details.

Sources

  1. Tesseract documentation: Improving the quality of the output (no date shown, checked 2026-10-11)
  2. Docling documentation, the engine behind our converter (no date shown, checked 2026-10-11)

More guides