Image Text Extractor OCR

What Is OCR (Optical Character Recognition)?

OCR (Optical Character Recognition) extracts readable text from images, screenshots, photos, and scanned documents. Instead of manually retyping text from a picture, this tool identifies characters in the image and converts them to selectable, copyable, searchable text. The recognizer is Tesseract (Apache-2.0), the open-source engine Google sponsored for a decade, compiled to WebAssembly by the tesseract.js project and run here in your browser tab. It reads printed and on-screen text in photos, screenshots and scans; it was not built for handwriting, and we have not tested it on any.

Common OCR Use Cases

Use OCR to extract text from screenshots of chat messages, error logs, or UI mockups. Digitize printed documents — receipts, invoices, business cards, and letters. For scanned PDFs, use the PDF OCR tool, which runs the same engine page by page and can write a searchable PDF. Copy code from screenshots shared in forums or tutorials.

How to Use This Tool

  1. Add an image — Drop it on the box, choose a file, or paste a screenshot with Ctrl+V / Cmd+V. PNG, JPEG, WebP, GIF and BMP work (anything the browser itself can decode).
  2. Pick the language — Choose the language the text is written in. The first run in a language downloads that language’s model (0.7 to 3.0 MB); the browser caches it.
  3. Leave layout and upscale on auto — Change the layout only when auto fails: “one block” for a paragraph crop, “sparse” for screenshots with scattered labels, “single line” for one line.
  4. Extract and check — Press Extract Text. The result opens in an editable box with the mean confidence and a list of words the engine scored under 60%; check those first, then copy the text or download it as .txt.

Worked example: how text size changes accuracy

On October 12, 2026 we rendered test images in headless Chromium, ran each one through this page in Chromium with the same tesseract.js 5.1.0 build it loads for you, and compared the output with the text we typed. The score is the character error rate (CER): the edit distance between output and truth divided by the length of the truth, after collapsing runs of whitespace. 0% means every character came back. First, the same three English lines in DejaVu Sans at nine sizes, captured at one image pixel per CSS pixel, as a normal 1x screenshot would be:

Font sizeText line heightCER at 1xCER at 2xCER at 3xCER with auto
8 px9 px16.4%0%0%0% (re-read at 4x)
9 px9 px7.0%0%0%0% (re-read at 4x)
10 px10 px2.8%0%0%0% (re-read at 4x)
12 px13 px0%0%0%0% (re-read at 3x)
14 px14 px0%0%0%0% (re-read at 3x)
18 px18 px0%0%0%0% (read once at 1x)
24 px24 px0%0%0%0% (read once at 1x)
32 px31 px0%0%0%0% (read once at 1x)
48 px47 px0%0.5%1.4%0% (read once at 1x)

Below about 12 px the error rate climbs fast: at 8 px one character in six comes back wrong, and Tesseract’s own confidence drops to 61%. Enlarging the same image 2x before recognition brings every size back to zero. That is why Upscale: auto, the default, reads the image once, measures the median height of the text lines Tesseract found, and if they are under 16 px tall, reads it again enlarged so the lines are about 32 px, keeping whichever pass has the higher mean confidence. Large text is left alone on purpose: at 48 px, 2x and 3x copies did slightly worse than the original.

The six harder English images, each read at 1x, 2x and with auto:

Test imageCER at 1xCER at 2xCER with autoMean confidence (auto)
Clean UI text, 16 px0%0%0%95%
Small print, 11 px0.5%0%0%95%
Dark-mode terminal, 15 px light on #1e1e1e5.1%1.9%1.9%90%
Code screenshot, 13 px monospace4.5%0.9%0.9%83%
Low contrast, #9a9a9a on #e6e6e60%0%0%95%
Photo of a page: 2.2° tilt, uneven light, noise, blur, JPEG q400.5%27.3%0.5%95%

Two failures are worth knowing about. The photographed page read almost perfectly at 1x (one lost space, “ata quarter”) but lost 27% of its characters at 2x, because Tesseract’s layout analysis cut the enlarged lines short. The code screenshot’s characters came through, but its indentation did not: Tesseract returns lines of words, not the leading spaces of a code block, so re-indent pasted code. Inverting the dark-mode screenshot ourselves made no difference (5.1% at 1x either way), because Tesseract already retries any line it reads with low confidence on an inverted copy of the image; we removed the invert option for that reason.

The other nine languages, one short paragraph each in the languages’ own scripts:

Language (17–22 px text)CER at 1xCER at 2xCER with auto
Spanish0%0%0%
French0%0%0%
German0%0%0%
Italian0%0%0%
Portuguese0%0%0%
Japanese0%0%0%
Chinese (Simplified)0%0%0%
Korean0%66.7%0%
Arabic2.6%2.6%2.6%

Korean shows the same trap as the photo: enlarged 2x, its 40 px lines were split into scattered fragments and two thirds of the text was lost, while 1x and auto were exact. Arabic came back with every letter but three missing spaces (“التاسعةصباحا”), which is the whole 2.6%. Japanese and Chinese were scored without spaces, since neither language puts spaces between words.

Why enlarging helps small text and can hurt large text

Tesseract 4 and later recognize text one line at a time with an LSTM neural network. Gilbey and Schönlieb (Cambridge, 2021) describe the pipeline: the page is first split into blocks, paragraphs and lines, then each line is rescaled to the network’s fixed input height of 36 pixels. Lines that start out only 9 or 10 pixels tall have very little detail left for that rescale to work with, and the models were trained on 300 dpi scans. In their tests on 60 dpi scans, plain Tesseract on bicubic-enlarged images still reached 96.6% to 99.7% character accuracy depending on the font, against 99.7% to 100% on the original 300 dpi scans, which matches the small-text losses in our first table.

The layout step runs before that, on the whole image, and it is the part that broke on our enlarged photo and Korean samples. Tesseract’s own guidance points the same way: it lists rescaling, binarisation, noise, skew and page segmentation mode as the main causes of bad output, notes that a skewed page “significantly” reduces line segmentation quality, and suggests a different segmentation mode when you only need a small region. The layout menu here maps to those modes: automatic (mode 3), one block (6), sparse text (11) and a single line (7). We dropped mode 4 (“single column of varied sizes”) after it read the tilted photo as two columns and scrambled 61% of it.

Preprocessing matters more as images get worse. Sporici and colleagues (2020) ran Tesseract 4.0 on a dataset of difficult real-world images and found character-level accuracy of only 0.134 on the raw images, rising to 0.616 with learned convolution filters applied first. This tool only converts to grayscale and enlarges small text; for curled pages, glare or heavy blur, a straighter, sharper photo will help more than any setting.

What the confidence number means

Tesseract gives every word a confidence from 0 to 100 and the page a mean. On clean text it tops out around 95 (it never reported more than 95 in our runs; Gilbey and Schönlieb note it never exceeds 97). In our set, every image at 92% or above came back with at most three wrong characters, and the two lowest scores (83% on the code screenshot, 61% on 8 px text at 1x) were also the two worst readings at that size. Use it as a flag, not a guarantee: the words listed under 60% are the ones to check first.

What runs where

Your image never leaves the device. It is drawn to a canvas, converted to grayscale and handed to a Web Worker running Tesseract. What the page downloads, once, from the jsDelivr CDN: the tesseract.js 5.1.0 loader (67 KB), its worker script (124 KB), the WebAssembly core (3.9 MB) and the trained model for the language you pick (0.7 MB for French up to 3.0 MB for English, from the 4.0.0_best_int set). After that the browser cache serves them. The Paste Image button uses the asynchronous Clipboard API, supported since Chrome 76, Safari 13.1 and Firefox 127 (Firefox shows its own paste prompt); Ctrl+V / Cmd+V on the page works everywhere.

Frequently Asked Questions

What image formats are supported?+
Anything your browser can decode: PNG, JPEG, WebP, GIF and BMP (and AVIF in browsers that support it). Animated GIFs are read from their first frame. Transparent areas are placed on white before recognition. Lossless PNG screenshots give the cleanest results; heavily compressed JPEGs blur small text.
Does this work with handwritten text?+
Not reliably. Tesseract’s models are trained on printed and typeset text, and we have not tested handwriting with this tool. Neat block capitals may partly come through; cursive will not. Treat any handwriting result as a rough draft.
Is my image uploaded to a server?+
No. The image is drawn to a canvas and recognized by Tesseract running in a Web Worker in your browser. The only network traffic is a one-time download of the engine (about 4.1 MB) and the model for the language you choose (0.7 to 3.0 MB) from the jsDelivr CDN; no image data is sent with those requests.
What languages are supported?+
English, Spanish, French, German, Italian, Portuguese, Japanese, Chinese (Simplified), Korean and Arabic, one at a time. Pick the language the text is written in: each has its own trained model, and the wrong one drops accents or misreads whole scripts. In our October 2026 test, a short paragraph in each of the ten languages came back exactly, except Arabic, which lost three spaces between words.
How accurate is the text extraction?+
On our 24 test images (October 2026, scored as character error rate against the typed text), 21 came back exactly with the default settings and the worst was 2.6%. Accuracy falls when text is small: at 8 px, a single pass got one character in six wrong, which is why auto mode re-reads text lines under 16 px at a larger size. Photos with tilt, glare or blur and very low-resolution screenshots do worse; always proofread numbers and names, starting with the words listed under 60% confidence.
Can I extract text from a PDF?+
Use the PDF OCR tool for scanned PDFs: it renders each page and runs the same Tesseract engine, and can save a searchable PDF. For PDFs that already contain real text (you can select it in a viewer), the PDF Text Extractor reads that text directly without OCR, which is faster and exact.

Built by Derek Giordano · Part of Ultimate Design Tools

Privacy Policy · Terms of Service