Guides

How to OCR scanned PDFs in Hindi, Tamil and other Indian languages

Government orders, land records, school certificates, old letters and books: a great many documents in Indian languages exist only as scans. A scan is a picture of a page, so you cannot search it, select a sentence or copy a quotation from it. OCR (optical character recognition) fixes that by reading the text in the picture.

Not every OCR tool supports Indian scripts. A2ZDocs OCR uses Tesseract, an open-source recognition engine, with language data for 124 languages, including the major Indian ones. It runs in your browser, so your scans are not uploaded anywhere.

Indian languages you can recognise

The language list includes:

  • Devanagari script: Hindi, Marathi, Nepali and Sanskrit.
  • Bengali script: Bengali and Assamese.
  • Tamil, Telugu, Kannada and Malayalam.
  • Gujarati, Punjabi (Gurmukhi script) and Odia.
  • Urdu and Sindhi.

English is there too, along with many other languages, so a document that mixes scripts can be read in one pass.

How to make a scanned PDF searchable

  1. Open OCR and choose your scanned PDF. If you only have photos of the pages, turn them into a PDF first with Scan to PDF.
  2. Under Document languages, search for your language, for example Tamil, and tick it. Tick every language the document uses. English is ticked to begin with; untick it if the document has no English at all.
  3. Choose the quality. More accurate reads each page at 300 dpi and is the default; Faster uses 200 dpi and suits clean, large print.
  4. Leave "Skip pages that already have text" ticked if some pages are already digital text, so only the scanned pages are read.
  5. Tick "Also save the text as a .txt file" if you want the recognised text on its own as well.
  6. Select Recognise text. Each page takes a few seconds, depending on your device. Your new file ends in _ocr.pdf.

When you run OCR, your browser downloads the recognition data for the languages you ticked from a2zdocs.com. For most Indian languages that is around one to three megabytes, and your browser may keep a copy for next time. Your scan itself stays on your device.

What you get

The result looks exactly like your scan, because the scan itself is left untouched. A2ZDocs adds an invisible layer of text on top of each page, lined up with the words in the picture. You can now:

  • Search the document with Ctrl+F (Cmd+F on a Mac).
  • Select and copy words, sentences and paragraphs.
  • Find the file by its content, in search tools that look inside PDFs.

Before reading a page, A2ZDocs also lightens long table borders and form lines in the copy it reads, so that text inside bordered tables is read as text rather than mistaken for strange characters. Your page keeps its lines.

Documents that mix English and an Indian language

Many documents combine scripts: a Hindi letter with English names and numbers, a Tamil form with English headings, a Marathi notice with an English reference number. Tick both languages. A2ZDocs passes them to the engine with the Indian language first and English last, because the engine gives preference to the first language; this keeps the Indian-language text accurate while still reading the English parts.

Tick only the languages that are really in the document. Each extra language makes recognition a little slower, and languages that are not there give the engine more ways to misread a character.

Getting a good scan

The quality of the scan matters more than anything else. A few habits make a big difference:

  • Resolution: scan at around 300 DPI. Much lower and the small strokes and vowel signs of Indian scripts blur together; much higher mostly makes files bigger.
  • Straight pages: keep the page square to the scanner or camera. Tilted or curved lines are harder to read.
  • Good contrast: dark text on a light, even background. Avoid shadows, glare and text showing through from the other side of the paper.
  • Complete, sharp characters: make sure nothing is cut off at the edges and the page is in focus.
  • Phone photos: use Scan to PDF. It finds the page in each photo, crops and straightens it, and its Document clean-up removes shadows and whitens the paper, much like a flatbed scanner.

Limits to know about

  • Handwriting is not reliable. OCR is designed for printed text, and handwritten notes in any script will mostly come out wrong.
  • Accuracy varies by script and print quality. Clean, modern print usually works well. Old documents, faint typewriter text, decorative fonts, very small print and poor photocopies cause more mistakes, and some scripts are recognised better than others.
  • Complex layouts, such as newspapers with several columns or forms with text in boxes, can come out in an unexpected reading order.
  • Always proofread. Recognised text is a strong starting point, not a guaranteed copy. Check names, numbers and dates against the scan before you rely on them.

Exporting the text

Once the PDF has a text layer, you can take the text elsewhere:

  • PDF to text saves all the text as a plain .txt file, and can mark where each page starts. Run it on your _ocr.pdf file, or simply tick "Also save the text as a .txt file" in the OCR tool.
  • PDF to Word turns the document into an editable .docx file. Its "Recognise text on scanned pages first" option runs OCR as part of the conversion, with its own Scan language list, so you can go straight from a scan to a Word document. It works best with simple layouts; complex pages will need some tidying.

The text is saved as Unicode, so you can paste it into documents, emails and spreadsheets. If Indian-language text shows as empty boxes when you open a file, the program or device you are using lacks a font for that script; the text itself is still there.

The OCR tool page is also available in Hindi and Tamil.

Tools in this guide

All guides