PDFLab
← Back to Guides
Online PDF Lab Team••Updated •5 min read

How to OCR a Scanned PDF and Turn It Into Text

TL;DR: A scanned PDF is pictures, not text. OCR reads the pictures and returns editable text, in your browser, with no upload. Clean scans at 300 DPI give the best results, and handwriting and speech are outside what OCR does.

In this guide

What does OCR actually do?

A scanned PDF is a set of pictures of pages. The words look readable on screen, and you can see them clearly, but the computer sees pixels rather than letters. That is why you cannot select the text with your mouse, search for a word inside the file, or copy a paragraph out of it. The file holds images, and images have no words in them as far as the computer is concerned.

OCR, short for optical character recognition, reads those pictures and works out which letters they show. It turns the image of a word into the word itself, so the result is text you can copy, search, and edit. The process runs entirely in your browser with OCR PDF, so the pages never leave your device. You open the file, the tool reads each page, and you get editable text back.

The quality of the result follows the quality of the scan. A clean page of printed text at a decent resolution comes out close to perfect, with only the odd character wrong. A crooked photo of a page taken in dim light comes out with mistakes on most lines. OCR is pattern matching rather than understanding. It compares shapes on the page with the shapes of letters it knows, and it guesses when a shape is unclear.

Does my PDF need OCR?

Try selecting a sentence with your mouse before you run anything. If the words light up and you can paste them into another document, the file already has a text layer, and running OCR on it would only add errors to text that is already there. In that case use PDF to Text instead, which pulls the existing text out directly.

Some files are mixed, with a few pages of real text and the rest scanned, often because someone merged a digital document with scanned pages. Those files need OCR for the scanned pages only. Split PDF can pull the scanned pages out first if you want to treat them separately.

How do I turn a scanned PDF into text?

Open the OCR tool, drop in the scan, run the recognition, then copy or download the text. The whole job takes a few minutes, and there is no account to create and nothing to install.

  • Step 1, open the OCR tool: go to OCR PDF in your browser. The tool loads once, and after that the work happens on your own computer.
  • Step 2, drop in your scanned PDF: drag the file onto the page or pick it from your device. The file is read in your browser and never uploaded to a server.
  • Step 3, run the recognition: start OCR and let the tool read each page. A short document finishes quickly, while a long scan takes longer, so give it time on a file with many pages.
  • Step 4, copy or download the text: read through the result, copy what you need, or download it as a text file. Check the result against the original before you use it for anything important, because even a good scan produces a few wrong characters.

The same OCR tool is also reached from Free OCR PDF, and Extract Text From PDF covers the same job with a guide aimed at pulling text out of a file.

How do I get cleaner OCR results from a scan?

Scan at 300 DPI, straight and well lit, in the right language. Resolution matters more than any setting. A page scanned at 300 DPI gives OCR clear letter shapes to read, while a page scanned at 100 DPI gives it blurry shapes that could be several different letters. If you are scanning the document yourself, 300 DPI is the resolution to use. Going higher than that adds file size without adding accuracy, since the letters are already clear at 300.

Straight pages help almost as much. A page scanned at an angle forces the tool to read tilted lines, and tilted lines confuse it, especially near the edges. Most scanners have a setting that straightens pages, and it is worth turning on. Contrast matters too. Faded print, grey paper, or a page photographed under yellow light all make letters harder to tell apart. A clean black on white page reads far better than a page with a coloured background or a shadow across it.

Language plays a part as well. OCR reads best when the document is in a language the tool supports, and a document that mixes languages will have more errors on the less common one.

What does OCR get wrong?

Handwriting is the most common disappointment. Printed text has consistent letter shapes, while handwriting changes from person to person and even from line to line. A neatly written note may come out mostly right, but ordinary handwriting comes out with many errors, and cursive comes out worse still.

Speech is outside what OCR does entirely. A PDF cannot hold a recording in a way OCR could read, and the tool transcribes printed text only. It cannot turn an audio recording or spoken words into text, and that job needs a speech to text service instead. Transcribe PDF says this plainly on its page, because people arrive there expecting it to handle audio, and it does not.

Tables, columns, and footnotes also cause trouble. OCR reads line by line, so a two column article can come out with the columns interleaved, and a table can come out as a jumble of numbers with the rows lost. A password protected PDF will not open at all until it is unlocked, so remove the password first. Small print, smudges, stamps over text, and pages where the ink has bled through from the other side all add errors in the same way, by making the shapes harder to tell apart.

What should I do with the OCR text once I have it?

Read the result before you trust it. The fastest check is to search for a few words you know appear in the document and confirm they came out right, then skim the first page line by line. Numbers deserve a second look in particular, since a misread digit changes a date, an amount, or a reference number without looking wrong. A 3 read as an 8, or a 1 read as a 7, is easy to miss if you are skimming.

Once the text is clean, it becomes useful in ways a scan never is. You can search it, quote from it, paste it into a document, or feed it into a translation tool. Paste it into your word processor and fix the layout there, since OCR returns plain text rather than a formatted page. Keep the original scan alongside the text file. The scan is the record of what the page actually said, and the text is a working copy that may still hold a mistake you have not spotted yet.

Need to process a PDF now?

Free, fast, and completely in-browser.

Turn a scanned PDF into text