What is optical character recognition (OCR)?
Optical character recognition (OCR) is the technology that turns an image of text into actual text. A scanned invoice is just pixels; after OCR it contains characters that can be searched, copied, and fed to other software. OCR is the first step in almost every document workflow, from mailroom scanning to mobile check deposit to reading the serial plate on a machine.
OCR handles printed and typed text. Handwriting is the domain of intelligent character recognition (ICR), and understanding what the text means (which number is the invoice total, which party is the buyer) belongs to intelligent document processing (IDP) and natural language processing.
How OCR works
Modern OCR runs in stages. Preprocessing straightens the page, removes noise, and improves contrast. A text detection model finds the lines and words on the page. A recognition model, usually a neural network that reads a whole line at once rather than one character at a time, converts each line to characters with a confidence score. A layout step reconstructs reading order, columns, and tables. Older engines matched individual characters against templates and were sensitive to fonts and skew; neural OCR copes far better with poor scans and mixed fonts. Vision-language models now read documents directly and can answer questions about them, though at a higher cost per page.
OCR in practice
A collections agency receives thousands of mailed payments each month with remittance stubs. Scanned stubs pass through OCR, which reads the account number, the amount, and the check number. Reads with high confidence post automatically to the account system; low-confidence fields go to a clerk’s queue with the image zoomed to the field in question. A law firm uses OCR to make decades of scanned case files searchable before an e-discovery review, so that attorneys can find every document mentioning a party instead of reading boxes of paper.
What to watch for
- Scan quality dominates results. Three hundred dots per inch, a flat page, and good contrast matter more than the choice of engine.
- Use the confidence score. Route low-confidence fields to a person rather than accepting every read, because one wrong digit in an account number costs more than a minute of review.
- Check how the engine handles tables, multi-column layouts, stamps, and text on colored backgrounds, which are where most engines fail.
- Many PDFs already contain a text layer; extract it directly and apply OCR only to image-only pages.
- Documents often contain personally identifiable information, so decide whether OCR runs on premises or in a cloud service before the first scan leaves the building.