All tools run in your browser — your files never leave your device.
All tools154

Image & Photo

How to extract text from an image with OCR

OCR quality is set by the picture, not the software. Three things about the image decide almost everything about the result.

The short answer. Optical character recognition reads letter shapes out of a picture and returns editable text. Accuracy depends far more on the source image than on the engine: aim for at least 300 DPI, high contrast between the text and the background, and a page that is straight rather than skewed. A sharp, flat, well-lit scan typically reads at over 98% accuracy; a dim angled phone photo can drop below 70%.

What decides whether OCR works?

Three properties of the image, in roughly this order of importance:

  1. Resolution. Characters need enough pixels to have a recognisable shape. Roughly 300 DPI for normal body text — below about 150 DPI, similar glyphs start collapsing into each other and you get the classic rn/m and 0/O confusions.
  2. Contrast. Black on white is ideal. Grey on grey, text over a photograph, or a faded receipt gives the engine much less to work with.
  3. Geometry. OCR expects text on horizontal lines. A page photographed at an angle has lines that curve and letters that lean, and accuracy falls sharply — a few degrees of skew is tolerable, fifteen is not.

Everything else — font, language, layout complexity — matters less than these three. Which is good news, because all three are fixable before you run anything.

How do you prepare an image for a clean read?

Five minutes here saves twenty minutes of proofreading afterwards.

  1. Scan at 300 DPI rather than photographing, when you have the choice. A flatbed scanner solves resolution, lighting and geometry in one step.
  2. If you must photograph, shoot straight down in indirect daylight. No flash — it creates a hot spot in the centre and shadows at the edges.
  3. Crop to the text with the Image Cropper. Desk, fingers and page edges give the engine regions to misinterpret as characters.
  4. Do not downscale before running OCR. Small files are a virtue for sharing and a handicap here — the tool needs the pixels.
  5. For a very large image, resize up to around 300 DPI equivalent if the original was captured lower. It does not add real detail, but it does give the engine more to work with on borderline glyphs.

The Image to Text tool runs the recognition on your device, which matters here more than for most tools: the documents people OCR are typically receipts, contracts, letters and ID pages.

What will OCR reliably get wrong?

Even a good read has predictable failure modes, and knowing them tells you where to look when proofreading.

What will OCR reliably get wrong?
ContentTypical accuracyWhat to check
Printed body text, clean scanAbove 98%Little; spot-check names
Small print, 8pt and below90–96%Digits and punctuation
Tables and columnsText good, layout poorColumn alignment is usually lost
Receipts, thermal print75–92%Amounts, dates, decimal points
Handwriting0–60%Everything; treat output as a hint
Text over a photograph40–80%Everything in the low-contrast areas

The one to be careful with is numbers. A misread word is obvious in context; a misread digit in an invoice total is invisible and wrong. Always check figures against the image by eye.

Why does the output have strange line breaks?

OCR reads the page geometrically, line by line, because that is what it can see. It has no idea that a paragraph continues across a line ending, so it faithfully returns a line break wherever the original had one.

On a two-column layout it gets worse: some engines read straight across the page, interleaving the columns into nonsense. If that happens, crop each column separately and run them one at a time.

For the ordinary case of unwanted line breaks, the Text Cleaner rejoins wrapped lines and strips the doubled spaces and stray hyphens that OCR tends to leave behind. It is usually a one-click fix on prose, and worth doing before you paste the text anywhere.

Can you OCR a PDF rather than an image?

It depends on what kind of PDF it is, and the distinction confuses people because both look identical on screen.

A digital PDF — exported from Word, a browser or a design tool — already contains real text. You do not need OCR at all; you can select and copy directly. If selecting works, the text is there.

A scanned PDF is a picture of a page wrapped in a PDF container. Selecting does nothing because there is nothing to select. This needs OCR.

For a scanned PDF, convert the pages to images first with PDF to JPG at 300 DPI, then run each through OCR. It is two steps, but rendering at a controlled resolution is exactly the preparation that decides accuracy — and it lets you check each page rather than trusting a batch.

Frequently asked questions

What resolution do I need for OCR?

Around 300 DPI for normal body text. Below roughly 150 DPI, similar characters start merging and you get the classic confusions between rn and m, or 0 and O. Smaller print needs more: 400-600 DPI for anything under 8pt.

Can OCR read handwriting?

Poorly. Standard OCR is trained on printed type, and handwriting accuracy ranges from useless to about 60% even when the writing is neat. Treat any output as a starting hint to be retyped, not as a transcript.

Why does my OCR output have random line breaks?

Because OCR reads the page line by line and cannot tell a wrapped line from a real paragraph break, so it reproduces every line ending it sees. A text cleaning tool rejoins wrapped lines and removes the doubled spaces and stray hyphens.

Does OCR preserve tables and formatting?

Rarely. Most engines return a stream of text with the words in roughly the right order but the column structure lost. For tables, expect to rebuild the layout by hand, and check that values have not migrated between columns.

Is it safe to OCR sensitive documents?

It depends on where the recognition runs. Many OCR services upload your image to a server. A browser-based tool runs the engine on your own device, so a passport page or a contract never leaves it. Check the Network tab in developer tools if you are unsure.

Can I OCR a scanned PDF?

Yes, but convert the pages to images at about 300 DPI first, then run OCR on each. That gives you control over the resolution, which is the single biggest factor in accuracy, and lets you verify pages individually rather than trusting a whole batch.

Stop reading, start doing

Every tool in this guide is free.

154 browser-based utilities. No account, no upload, and no file size limit — your files are processed on your own device and never sent anywhere.

Browse all 154 tools