Indra OCR: Free Offline OCR That Turns PDFs and Scans Into Markdown or Text on Any CPU (Windows, Mac, Kali), vs Tesseract, Tables to Excel and Searchable PDFs
Indra OCR is a free, offline OCR tool from Datalab that turns PDFs and images into Markdown, plain text or JSON on any ordinary CPU, with no graphics card: its models total about 18 MB, the main one has just 1.24 million parameters, and it reads a page in roughly a quarter of a second on four CPU cores, up to 49 pages a second on a 32-core server. On its makers' benchmark it is about 24 times faster than Tesseract at a fraction of the time per page, and it also finds headings, lists, tables and reading order, which Tesseract does not. Install it with pip install indra-ocr (Python 3.10 or newer) on Windows 11, Mac or Kali Linux, then run indra-ocr scan.pdf. Two things to know first: it does not read handwriting, and scans in Arabic, Hebrew, Thai, Japanese or Korean come out wrong (digital PDFs in those languages are fine). And the license is free for personal use, research and startups under $20 million, not for every business. Below: the install, every useful command, the Python API, the benchmarks, how it compares with Tesseract and your computer's built-in OCR, and how to make a scanned PDF searchable.
Jake's computer shop keeps a cardboard box of paper: supplier invoices, warranty cards, signed repair forms. When a customer asks "when did I buy that charger?", someone digs through the box. Jake wanted the paper turned into searchable text, but on the old office PC with no graphics card, and without uploading customer forms to an online converter. Ethan found a tool small enough for that PC and good enough to keep the tables in the invoices intact. This page is what he set up.
New to running AI tools on your own computer? Our free plain-English series covers the basics. If you have a good graphics card and want a bigger, vision-model approach to the same job, our LightOnOCR 3 guide covers that route.
What Indra OCR is, in plain English
OCR (optical character recognition) means turning a picture of text into actual text you can search, copy and edit. A scanned page, a phone photo of a receipt and an image-only PDF all need OCR before a computer can read the words in them.
Indra OCR comes from Datalab, the team behind the open-source PDF tools Marker and Surya. Its trick is size. Most modern OCR that can understand page layout runs on large AI models that want a graphics card. Indra's recognition model has about 1.24 million parameters, and all its models together are about 18 MB, smaller than a single phone photo. It runs on ONNX Runtime, a lightweight engine that uses your CPU, so it needs neither a GPU nor PyTorch.
Small does not mean basic. Indra does more than read lines of text:
- It reads digital PDFs directly. If a PDF already has a text layer (it was created from a document, not scanned), Indra uses that text where it passes its checks and runs OCR only on the parts that need it, such as text inside images. That is both faster and more accurate than OCR on every page.
- It understands layout. It labels blocks as text, headings, page headers and footers, lists, tables, captions, footnotes, tables of contents and forms, and puts them in reading order.
- It writes useful formats. Markdown with headings and lists (tables come out as HTML inside the Markdown), plain text with one line per detected line, or JSON with every line's position, confidence and the block it belongs to.
- It straightens pages. It rotates upside-down or sideways pages and corrects small tilts before reading them.
Its name comes from Indra, the Hindu god of the sky, a nod to its speed.
Jake: "Eighteen megabytes? The scanner driver is bigger than that."
Ethan: "That is why it runs on the office PC. The heavy OCR tools want a gaming card. This one wants four CPU cores."
Will it work for your documents? What it reads and what it does not
Be clear about the limits before you trust a box of paper to any OCR tool. Indra's are specific and worth knowing.
| Document | How Indra does |
|---|---|
| Digital PDFs (any language) | Very well: it uses the text layer, tested across 75 language families including Arabic, Hebrew, Chinese, Japanese, Korean and Indic scripts |
| Scans and photos in Latin-script languages | Good: about 50 languages, including English, French, Spanish and German |
| Scans in Cyrillic, Greek, Devanagari, Bengali or Chinese | Supported for OCR (Chinese lines go to a separate Chinese recognizer) |
| Scans in Arabic, Hebrew, Thai, Japanese kana or Korean | Not reliable; works only through a digital PDF's text layer |
| Handwriting | Not supported (about 8% on its handwriting tests) |
| Old, faded or damaged scans | Weak (about 20% on old-scan tests) |
| Simple grid tables | Good |
| Complex tables (merged cells, no ruling lines) | Cells can land in the wrong row or column |
| Math formulas | Plain text by default; LaTeX with --math |
| Vertical text, very wide banner pages | Not supported / weak |
| Engineering drawings | Labels often come out as small tables |
Two more details for scans. Pages larger than 100 megapixels at the default 200 dpi are rendered at a lower resolution, so very small print on a huge page can be lost. And the automatic rotation step gets about half of upright Arabic and Hebrew scans wrong, which is one more reason to use a digital PDF for those languages.
For Jake's box, the verdict was easy: printed English invoices and warranty cards, a few typed forms, nothing handwritten except signatures, which nobody needs as text anyway.
Scan it right: five habits that make any OCR better
OCR can only read what the scan shows. A few minutes spent on how you scan saves hours of fixing text later, whichever tool you use.
- Scan at 300 dpi for normal text. 200 dpi (Indra's default when it renders PDFs) is fine for clean printed pages; 300 dpi gives small print and faint receipts a better chance. Going far above that mostly makes files bigger.
- Keep the page flat and the light even. Curved pages near a book's spine and shadows from a phone held over the paper are the most common reasons for missing words. A flatbed scanner beats a phone; a phone in good daylight beats a phone under a desk lamp.
- Use grayscale for text-only pages. Color is only worth it when color carries meaning, such as stamps or highlighted totals. Grayscale files are smaller and just as readable.
- One document per file. Scanning the whole box into one 400-page PDF makes it hard to name, search and fix later. One invoice, one file, with the date or supplier in the name.
- Keep the digital originals when you have them. A PDF that came from an email has a perfect text layer; printing it and scanning it back throws that away. Indra reads the original's text directly and gets every character right.
For thermal-paper receipts that are already fading, scan them now rather than later. Fading is the one problem no OCR tool can undo.
Install Indra OCR on Windows 11, Mac and Kali Linux
You need Python 3.10 or newer. The install pulls in ONNX Runtime, OpenCV and pypdfium2 (for reading PDFs), and nothing else heavy.
# Windows 11 (PowerShell) mkdir C:\ocr; cd C:\ocr python -m venv .venv .\.venv\Scripts\Activate.ps1 pip install indra-ocr # Mac and Kali Linux mkdir ~/ocr && cd ~/ocr python3 -m venv .venv source .venv/bin/activate pip install indra-ocr
A few system notes:
- Windows: install Python from python.org and check the box "Add python.exe to PATH" during setup. If PowerShell will not run the activate script, run
Set-ExecutionPolicy -Scope CurrentUser RemoteSignedonce. - Kali and other Debian-based Linux: if
python3 -m venvfails, runsudo apt install python3-venvfirst. Check your version withpython3 --version. - Mac: the Python from python.org or Homebrew (
brew install python) both work. Apple Silicon and Intel Macs are both fine, since it runs on the CPU.
The first time you convert a document, Indra downloads its models from Hugging Face (about 18 MB) and caches them, so that first run needs an internet connection. After that, it works offline. The offline section shows how to set it up for a machine that never goes online.
Your first conversions: the commands you will actually use
Run these in the same terminal, with the virtual environment active. Each line converts and prints or saves the result.
indra-ocr invoice.pdf # Markdown, printed to the screen indra-ocr invoice.pdf > invoice.md # Markdown, saved to a file indra-ocr *.pdf --out results/ # every PDF in the folder, one .md each indra-ocr receipt.jpg --format text # plain text, one line per line on the page indra-ocr form.png --format json # lines, boxes, layout blocks, confidences indra-ocr scan.pdf --mode ocr --timings # OCR every page; print time per page indra-ocr paper.pdf --keep-furniture # keep page headers and footers indra-ocr notes.pdf --math # write math as LaTeX (slower) indra-ocr *.pdf --out results/ --cores 4 # limit how many CPU cores it uses
On Windows PowerShell, *.pdf works as written. The output folder is created if it does not exist. With --out, Markdown files end in .md, text files in .txt and JSON in .jsonl (one JSON object per page).
Every option, in one place:
| Option | What it does |
|---|---|
--out DIR | Save one file per input instead of printing |
--format md|text|json | Output format; Markdown is the default |
--mode auto|ocr|text | auto uses a PDF's text layer where it passes checks and OCRs the rest; ocr ignores the text layer; text uses it even when checks fail |
--model-order | Use the reading-order model instead of the PDF's own text order |
--no-image-ocr | Skip OCR of text inside images on digital pages |
--cores N | Number of worker processes (default: all usable cores) |
--dpi N | PDF render resolution (default 200) |
--max-pages N | Stop after N pages |
--password | Open an encrypted PDF |
--keep-furniture | Keep page headers and footers (left out by default) |
--math | Detect math lines and write them as LaTeX |
--timings | Print where each page's text came from and how long it took |
--model-dir DIR | Use models from a folder instead of downloading |
If a file cannot be read, the tool skips it, carries on with the rest, and exits with an error code at the end, so a batch of a thousand files does not stop at the first damaged one. Check the output for missing files after a big run.
Jake: "Can it do the whole box at once?"
Ethan: "Scan everything into one folder, then one command. It uses every core the PC has, one page per core."
A double-click batch file for Windows
If other people in the office will use this, they should not have to open PowerShell. Save the following as convert-scans.bat in C:\ocr. Anyone can then drop PDFs into C:\ocr\inbox and double-click the file; the Markdown appears in C:\ocr\done.
@echo off cd /d C:\ocr call .venv\Scripts\activate.bat if not exist inbox mkdir inbox if not exist done mkdir done indra-ocr inbox\*.pdf --out done echo. echo Finished. Your text files are in C:\ocr\done pause
The pause at the end keeps the window open so the person can see that it finished, or read an error if a file was damaged. To include photos too, add a second line for inbox\*.jpg.
On Mac and Kali, the same idea is a short shell script. Save it as convert-scans.sh in ~/ocr:
#!/bin/sh cd ~/ocr || exit 1 . .venv/bin/activate mkdir -p inbox done indra-ocr inbox/*.pdf --out done echo "Finished. Your text files are in ~/ocr/done"
Make it executable once with chmod +x convert-scans.sh, then run it with ./convert-scans.sh. On a Mac, renaming it to end in .command makes it double-clickable in Finder, just like the Windows batch file.
Run it every night. If scans arrive all day, let the computer convert them after hours. On Windows, open Task Scheduler, choose Create Basic Task, set a daily trigger (say 10 p.m.), and point the action at C:\ocr\convert-scans.bat; remove the pause line from the batch file first, or the task will wait forever for a key press. On Mac and Linux, a cron line does the same: run crontab -e and add 0 22 * * * $HOME/ocr/convert-scans.sh. Move finished PDFs out of the inbox afterwards, or each night will convert the whole pile again.
See what it read: the local viewer
Before you trust a tool with hundreds of documents, look at what it does with a few. Indra comes with a small viewer that runs in your browser on your own computer:
indra-ocr-viewer --port 8765
Open http://localhost:8765, drop in a document, and the viewer draws every detected line and block over the page, shows the reading order, and gives you the rendered Markdown, the Markdown source, the confidence scores, the JSON and the time each step took. If you have Tesseract installed (with the pytesseract package), start the viewer with --tesseract to compare the two on the same page. This is the fastest way to decide whether Indra suits your kind of paperwork.
On a remote Linux machine, keep the viewer private and reach it through SSH instead of opening the port: ssh -N -L 8765:localhost:8765 user@yourserver, then open http://localhost:8765 on your own computer.
Use it from Python
For anything more than a one-off conversion, the Python API is more flexible. Here is a single document:
import indra_ocr
conv = indra_ocr.load(threads=4) # mode="auto" by default
for i, page in conv.convert("invoice.pdf"):
print("page", i, "from", page.source, "in", page.timings["total_ms"], "ms")
print(page.markdown)
for block in page.blocks: # layout blocks, in reading order
print(block["label"], block["bbox"])
Each page tells you where its text came from (page.source): text for a digital text layer, ocr for recognized text, hybrid for a digital page with OCR'd images, or error. It also gives you page.lines (each line with its box and confidence), any rotation and tilt it corrected, and a note explaining why the page took the path it did. load also accepts dpi, mode, pdf_order, image_ocr, furniture and math; convert accepts max_pages and password.
For many files at once, use convert_many, which spreads the work across processes. On Windows and Mac, the if __name__ == "__main__": line is required, because new worker processes start by importing your script:
import glob
import indra_ocr
if __name__ == "__main__":
files = glob.glob("scans/*.pdf")
for path, result in indra_ocr.convert_many(files, cores=None):
if isinstance(result, indra_ocr.InputError):
print("skipped", path)
continue
with open(path + ".md", "w", encoding="utf-8") as f:
for i, page in result:
f.write(page.markdown + "\n\n")
The encoding="utf-8" matters on Windows, where Python otherwise writes files in the older local encoding and can fail on symbols such as the euro sign or accented names.
Worked example: invoice tables into a spreadsheet
The most useful thing Jake's shop got out of the box was not the text but the tables: every invoice's line items, in one spreadsheet. Indra writes tables as HTML inside its Markdown, and the pandas library can read HTML tables directly, so the step from scan to spreadsheet is short. Install the extras first: pip install pandas lxml openpyxl.
import glob, io, os
import pandas as pd
import indra_ocr
if __name__ == "__main__":
conv = indra_ocr.load(threads=4)
frames = []
for path in glob.glob("invoices/*.pdf"):
for i, page in conv.convert(path):
if "<table" not in page.markdown:
continue
for table in pd.read_html(io.StringIO(page.markdown)):
table["source_file"] = os.path.basename(path)
table["page"] = i
frames.append(table)
if frames:
pd.concat(frames, ignore_index=True).to_excel("all-invoice-lines.xlsx", index=False)
print("Saved", len(frames), "tables")
Every table from every invoice ends up in one Excel file, with the file name and page next to each row so you can check any line against the original. Expect to tidy the result: suppliers use different column names, totals rows come along with item rows, and a table with merged cells may need a manual fix. For simple grid invoices, which is most of them, the rows come through as they are on paper.
Jake: "So I can finally see how much we spent on chargers last year?"
Ethan: "Filter the spreadsheet by description. It's every line from every invoice in the box."
Check the output before you trust it
OCR that is right 98% of the time sounds excellent until the 2% is an invoice total. Before you throw away paper or rely on the text for anything with money or dates in it, a short routine catches most problems:
- Spot-check ten pages per batch in the viewer, picking the worst-looking scans on purpose: faded receipts, skewed photos, pages with stamps. If those are fine, the clean ones will be too.
- Watch the classic confusions in numbers and codes: 0 and O, 1 and l, 5 and S, 8 and B. Serial numbers and part codes suffer most, because there is no surrounding word to make the right reading obvious.
- Check totals against line items. For invoices, add up the extracted lines and compare with the extracted total. A mismatch points straight at the cell that was misread or dropped, and it is easy to do in the spreadsheet from the tables example.
- Look for pages that failed. In the Python API, a page whose source is
errorproduced nothing usable; with--timingson the command line, every page reports where its text came from. Rescan those pages rather than fixing them by hand. - Keep the originals. Store the scans next to the text, with matching file names, so anyone who doubts a number can open the paper version in a second.
None of this is special to Indra; every OCR tool needs it. What Indra changes is the cost of running a batch again: at a quarter of a second a page, rescanning twenty bad pages and converting them takes less time than correcting one by hand.
Jake: "So I still have to look at some of them?"
Ethan: "Ten pages a batch, the ugliest ones. And anything with a total gets added up by the spreadsheet, not by trust."
Fully offline: install once, then cut the cord
"Offline" has one catch: the first run downloads the models. For a computer that must never touch the internet, such as a machine holding confidential records, do the download on another computer and copy the models across.
- On a connected computer, install Indra and convert any small file once, so the models download and cache.
- Copy the model folder to the offline machine (a USB stick works), for example into
C:\ocr\modelsor~/ocr/models. - On the offline machine, point Indra at that folder with the environment variable or the option:
# Windows (PowerShell, current window) $env:INDRA_OCR_MODEL_DIR = "C:\ocr\models" # Mac and Kali export INDRA_OCR_MODEL_DIR=~/ocr/models # or per command indra-ocr invoice.pdf --model-dir ~/ocr/models
You will also need to install the Python packages on the offline machine without the internet. The usual way is to run pip download indra-ocr -d wheels on a connected computer with the same operating system and Python version, copy the wheels folder across, and install with pip install --no-index --find-links wheels indra-ocr.
The --math option uses two extra models that download only when you first use it, so run one math conversion on the connected computer too if you will need it offline.
Math and science documents: --math
By default, formulas come out as plain text, which is fine for an invoice and useless for a physics paper. With --math, a classifier finds lines that contain math and a second recognizer writes them as inline LaTeX, the format that Markdown renderers and editors such as Obsidian or Typora display as proper formulas.
It costs speed. On four cores, the median page goes from about 210 milliseconds to about 360, and throughput drops by roughly 30% on 4 cores and 35% on 32. Digital PDF pages slow the most, from a median of 130 ms to 345 ms, because math detection runs even where the text layer would have been enough. The payoff is large: on the math tests in Datalab's benchmark, the score rises from 14.3 to 56.5, and the overall headline score from 62.1 to 66.8. Use it for papers, worksheets and textbooks; leave it off for business documents.
How good is it? Indra vs Tesseract and PaddleOCR
Datalab measured Indra on OmniParseBench, its own benchmark of 16,288 pass-or-fail tests across 2,937 pages, with every engine on four x86 CPU cores and one page at a time. The headline score averages text, tables and layout.
| Engine | Headline | Text | Tables | Layout | Median time per page |
|---|---|---|---|---|---|
| Indra OCR (auto) | 62.1 | 41.3 | 56.4 | 88.6 | 228 ms |
| Indra OCR with --math | 66.8 | 57.5 | 54.8 | 88.1 | about 360 ms |
| PaddleOCR PP-StructureV3 | 58.4 | 55.6 | 47.8 | 71.7 | 40,958 ms |
| PaddleOCR PP-OCRv6 small (text only) | — | 35.8 | 0 | — | 2,685 ms |
| Tesseract 5 (Latin model) | — | 19.3 | 0 | — | 5,496 ms |
Read it this way. Against Tesseract, the long-standing free OCR engine, Indra scores twice as high on text and runs about 24 times faster per page in this setup, and it adds tables and layout, which Tesseract (and the text-only PaddleOCR models) do not produce at all, hence their zeros. Against PaddleOCR's full layout pipeline, PP-StructureV3, Indra is slightly behind on plain text but ahead on tables and layout, and about 180 times faster. Even with faster settings for its rivals (Tesseract on English with one thread at 3.4 seconds a page, PP-StructureV3 trimmed down at 10.5 seconds), Indra stays 15 to 45 times faster.
On older academic tests (olmOCR-bench), Indra beats Tesseract 4 clearly on headers and footers (91.2 against 35.5) and tables (60.5 against 1.0), and roughly ties on multi-column pages, long tiny text and old scans. On Chinese, it scores 64.7 against 65.4 for PaddleOCR's mobile Chinese models.
And it scales. On a 32-core AMD EPYC server, Indra reached 49.4 pages a second, against 2.92 for Tesseract 5 on the same machine. A real batch of 300 pages, including loading the models, ran at 7.2 pages a second on 4 cores and 37.7 on 32.
| Pages per second | 4 cores | 8 cores | 16 cores | 32 cores |
|---|---|---|---|---|
| Indra OCR | 7.3 | 14.2 | 27.2 | 49.4 |
| PaddleOCR PP-OCRv6 small | 0.65 | 1.24 | 2.42 | 4.28 |
| Tesseract 5 | 0.78 | 1.37 | 2.27 | 2.92 |
These are the maker's own numbers on its own benchmark, run in OCR mode on the same 300 pages, so test on your own documents before you decide; the viewer's Tesseract comparison makes that quick. But the size of the gap is hard to argue with: for a typical office PC, a thousand pages is a few minutes with Indra and hours with Tesseract.
Indra, Tesseract, LightOnOCR or your computer's built-in OCR?
You may already have OCR on your computer, and for a single page it is the quickest tool. Here is when to use what:
| Tool | Best for | Needs |
|---|---|---|
| Windows 11 Snipping Tool (Text actions) or PowerToys Text Extractor | Copying text from one screenshot or image | Nothing extra; built in or a free Microsoft add-on |
| Mac Live Text (Preview, Photos) | Selecting text in a photo or a scanned page | Built into macOS |
| Indra OCR | Batches of PDFs and scans into Markdown, text or JSON, with layout and tables | Python and any CPU |
| Tesseract / OCRmyPDF | Making a scanned PDF searchable while keeping it a PDF; many languages | A free install |
| LightOnOCR and other vision models | Hard layouts, mixed content, the highest accuracy | A good graphics card |
In Windows 11, open the Snipping Tool, take a screenshot and choose Text actions to copy the text. Microsoft's free PowerToys adds Text Extractor, which you start with Win + Shift + T and drag over any part of the screen. On a Mac, open an image or scanned PDF in Preview and drag across the text as if it were a normal document. These are perfect for "I need the text from this one picture," and they cost nothing. For a folder of a hundred invoices, with tables you want to keep, Indra is the better tool.
Jake: "I have been using the Snipping Tool for receipts for a year."
Ethan: "Keep doing that for one receipt. For the box, use Indra."
Why offline OCR matters: what you upload to free converters
Search for "PDF to text" and the first results are free websites where you upload a file and download the text. They work, and for a restaurant menu that is fine. For invoices, contracts, medical forms, ID cards or anything with a customer's name and address, think twice: the file goes to someone else's server, under their terms, in a country you may not know, and you cannot check whether it is deleted afterward.
Offline OCR removes the question. With Indra, the document never leaves your computer, the models run locally, and the output sits in a folder you control. For a small business, that is the difference between "we uploaded customer forms to a website" and "the forms never left the office," which is a much easier sentence to say to a customer or under data-protection rules such as the GDPR in Europe or state privacy laws in the US.
It also works when the internet does not: on a laptop on a plane, in a site office with a weak connection, or on a machine that is deliberately kept offline.
One thing offline OCR does not do for you is protect the output. The text files hold the same names, addresses and amounts as the paper, in a form that is far easier to copy. Keep the inbox and done folders on a drive that is backed up, limit who can open them, and delete the text along with the paper when your retention period ends.
Make a scanned PDF searchable (and where Indra fits)
Indra gives you text, Markdown or JSON. Sometimes what you want instead is the original PDF with an invisible text layer added, so it still looks exactly like the scan but you can search it and copy from it. That is a different job, and the long-standing free tool for it is OCRmyPDF, which uses Tesseract underneath.
# Kali and other Debian-based Linux sudo apt install ocrmypdf ocrmypdf scanned.pdf searchable.pdf # Mac (Homebrew) brew install ocrmypdf ocrmypdf scanned.pdf searchable.pdf
On Windows, the simplest route is to run the same commands inside WSL (Windows Subsystem for Linux), which you can install from an administrator PowerShell with wsl --install.
The two tools work well together. Use OCRmyPDF when people need to open and search the original documents. Use Indra when you want the content itself: text for a search index, tables for a spreadsheet, or Markdown for an AI assistant. Jake's shop ended up doing both: searchable PDFs in the shared folder for staff, and Indra's Markdown feeding a small search tool so "when did she buy that charger?" became a five-second question.
Find anything in the converted files, with no extra software
Once the box is text, the simplest search tool is the one already on your computer. Every converted document is a plain .md or .txt file, and all three systems can search a folder of those in a second:
# Windows (PowerShell): every file and line that mentions "charger" Select-String -Path C:\ocr\done\*.md -Pattern "charger" # Windows (Command Prompt): file names only findstr /s /i /m "charger" C:\ocr\done\*.md # Mac and Kali: file names only, ignoring upper and lower case grep -ril "charger" ~/ocr/done
The PowerShell version shows the file name, the line number and the line itself, which is usually enough to answer "when did she buy that charger?" without opening anything. Searching is case-insensitive in Select-String by default, and the -i flags make the other two behave the same.
Two habits make this work far better. Name files with the date and supplier, such as 2025-03-14-supplier-invoice.pdf, so the result list sorts by date and tells you what you found before you open it. And search for the word as it is printed on the paper ("adapter," "PSU," "charger"); plain text search matches letters, not meaning. When people start asking questions phrased differently from the paper, that is the moment for the meaning-based search in the next section.
For quick counts, pipe the search into a counter: | Measure-Object after Select-String in PowerShell counts matching lines, and | wc -l after grep -ril on Mac and Linux counts matching files. "How many invoices from this supplier did we get last year?" becomes one line, if the file names carry the date.
Feed your documents to an AI assistant
Indra's Markdown is a good input for AI tools, because headings, lists and tables survive. Once your paperwork is text, you can make it searchable by meaning with an embedding model, so a search for "power adapter warranty" finds the invoice that says "charger, 12-month cover." Our EmbeddingGemma 2 guide shows how to do that locally with Ollama, and you can then let a local chat model answer questions from the matching documents.
Two tips make that work better. Keep each document's file name and date with its text, so answers can point back to the source. And use the JSON output when you need positions, for example to highlight the matching line on the original scan, because each line comes with its box on the page.
The license: who can use Indra OCR for free
This part matters for businesses. Indra's code is under Apache 2.0, but its model weights use a modified OpenRAIL-M license. In short, the weights are free for research, personal use, and startups under $20 million in funding or revenue, and they cannot be used to compete with Datalab's own API. Larger companies need a commercial license from Datalab, which also runs a managed document-conversion service.
For a small shop like Jake's, that is comfortably inside the free terms. For a larger employer, check with whoever handles software licensing before you build a workflow on it. Read the license file in the project's repository for the exact wording; the summary here is no substitute for it.
OCR on AWS: Amazon Textract or Indra on your own instance
If your documents already live in the cloud, you have two routes on AWS.
Amazon Textract is AWS's managed OCR service. It extracts printed and handwritten text, forms (key-value pairs) and tables from scans and PDFs, with no models or servers to manage, and it reads files straight from Amazon S3. It handles handwriting, which Indra does not, and it scales without any setup. You pay per page, so check its pricing for your volume.
Indra on your own compute is the other route. Because it needs no GPU and only about 18 MB of models, it runs on an ordinary CPU instance or inside a container, close to where your files sit in S3. For large batches of typed documents, that can be much cheaper than per-page pricing, and the data never leaves your own account. The trade is that you run and update it yourself, and it will not read handwriting.
A practical rule: Textract for forms, handwriting and anything you want fully managed; Indra for big batches of printed documents where cost and control matter.
Errors and fixes
pip says no matching distribution, or the install fails
Your Python is older than 3.10. Check with python --version (or python3 --version), install a newer Python, and create the virtual environment again with it.
"indra-ocr" is not recognized as a command
The virtual environment is not active, or the install went into a different Python. Activate the environment (.\.venv\Scripts\Activate.ps1 on Windows, source .venv/bin/activate on Mac and Linux) and run it again.
The first run hangs or fails on an offline computer
It is trying to download the models. Copy the models from a connected computer and set INDRA_OCR_MODEL_DIR or use --model-dir.
Python script crashes on Windows or Mac with a multiprocessing error
Put the code that calls convert_many under if __name__ == "__main__":. Worker processes import your script when they start, and without that line they try to start workers of their own.
Encrypted PDF will not open
Pass the password with --password on the command line, or password= in convert.
Page headers and footers are missing
That is the default, to keep the text clean. Add --keep-furniture to keep them.
Text from a digital PDF comes out in the wrong order
Some PDFs store their text out of order. Add --model-order to use Indra's reading-order model instead of the PDF's internal order.
A digital PDF comes out garbled
Its text layer is broken, which happens with some exported or protected files. Force OCR with --mode ocr.
Small print is missing on a large scan
Pages over 100 megapixels at 200 dpi are rendered at a lower resolution. Split very large pages, or scan at a size closer to a normal page.
It is slower than expected
Check --cores (the default uses every usable core), close other heavy programs, and remember that --math adds about 30% to the time.
Frequently asked questions
What is Indra OCR?
A free, offline OCR tool from Datalab that converts PDFs and images into Markdown, plain text or JSON on a CPU. Its recognition model has about 1.24 million parameters and its models total about 18 MB.
Does Indra OCR need a GPU?
No. It runs on ONNX Runtime on the CPU and needs neither a graphics card nor PyTorch. A page takes about 230 milliseconds on four CPU cores.
How do I install Indra OCR?
Install Python 3.10 or newer, then run pip install indra-ocr. It works on Windows 11, macOS and Linux, including Kali.
Is Indra OCR free?
The code is Apache 2.0. The model weights are free for research, personal use and startups under $20 million in funding or revenue; larger companies need a commercial license from Datalab.
Does Indra OCR work offline?
Yes, after the first run downloads its models. For a machine with no internet, copy the models across and set INDRA_OCR_MODEL_DIR or use --model-dir.
Can Indra OCR read handwriting?
No. Handwriting is not supported. Amazon Textract and large vision models are options for handwritten documents.
Which languages does Indra OCR support?
For scans: about 50 Latin-script languages, Cyrillic, Greek, Devanagari, Bengali and Chinese. Digital PDFs work in any script through their text layer.
Is Indra OCR better than Tesseract?
On Datalab's benchmark, it scores 41.3 on text against 19.3 for Tesseract 5, adds tables and layout, and takes about 228 ms per page against 5,496 ms on four cores.
How do I convert a PDF to Markdown offline?
Run indra-ocr file.pdf to print Markdown, or indra-ocr *.pdf --out results/ to save one .md file per PDF. Tables come out as HTML inside the Markdown.
How do I convert an image to text offline?
Run indra-ocr image.jpg --format text. On Windows 11 the Snipping Tool's Text actions and PowerToys Text Extractor also copy text from a single image.
How do I make a scanned PDF searchable for free?
Use OCRmyPDF: ocrmypdf scanned.pdf searchable.pdf. It adds a hidden text layer and keeps the PDF looking the same. On Windows, run it in WSL.
Can Indra OCR extract tables?
Yes. Simple grid tables come out well, as HTML inside the Markdown. Complex tables with merged cells or no lines can have cells in the wrong place.
Does Indra OCR handle math?
With --math, it writes formulas as inline LaTeX. It makes conversion about 30% slower and raises the math score on Datalab's tests from 14.3 to 56.5.
How fast is Indra OCR?
About 7.3 pages a second on 4 CPU cores and 49.4 on 32 cores, on Datalab's throughput test. A typical office PC handles a thousand pages in a few minutes.
What is the best free offline OCR software?
For batches of PDFs and scans with layout and tables, Indra OCR. For searchable PDFs, OCRmyPDF. For a single screenshot, your computer's built-in OCR in Windows 11 or macOS.
Indra OCR or Amazon Textract?
Textract is managed, reads handwriting, forms and tables, and charges per page. Indra is free for small users, runs on your own CPU and is faster and cheaper for big batches of printed documents.
How do I run Indra OCR automatically every night?
On Windows, schedule the batch file in Task Scheduler (remove its pause line). On Mac and Linux, add a crontab line that runs the shell script.
How do I search the text Indra OCR produces?
Use Select-String in PowerShell, findstr in Command Prompt, or grep -ril on Mac and Linux, pointed at the output folder.
Who makes Indra OCR?
Datalab, the team behind the open-source PDF tools Marker and Surya. Its managed document-conversion service is a separate paid product.
For readers preparing for an AWS certification
We have been covering AWS certifications alongside our fixes, so here is a short extra for readers studying for one. If you only came for the fix, you already have it; feel free to skip this part.
Exams that test this topic: AI Practitioner (AIF-C01) • Machine Learning Engineer – Associate (MLA-C02) • Solutions Architect – Associate (SAA-C03).
Here are the exam-style questions this topic tends to raise, with the reasoning you need to answer them:
1. Scanned forms must be turned into text, key-value pairs and tables, including handwriting, with no servers to manage. Which service?
Amazon Textract.
2. Extracted text must be checked for personal data such as names and phone numbers. Which service helps?
Amazon Comprehend PII detection.
3. Scanned originals must be kept for years at the lowest storage cost and are rarely read. Where do you keep them?
Amazon S3, in an archive storage class such as S3 Glacier Deep Archive.
4. Every new scan uploaded to a bucket must be processed automatically. How do you trigger it?
An S3 event notification that invokes a Lambda function.
5. Staff want to ask questions in plain English across thousands of extracted documents. What do you build?
Retrieval-augmented generation, for example Amazon Bedrock Knowledge Bases over the extracted text.
6. Extracted text in Spanish must be shown to English-speaking staff. Which service?
Amazon Translate.
Exam codes and dates change often. Our AWS certification changes page keeps track of what is current.
The cardboard box took one afternoon of scanning and four minutes of Indra on the old office PC. The invoices came out with their tables intact; the two handwritten notes came out as nonsense, as expected, and Jake typed those himself. Now "when did she buy that charger?" is a search, not a dig. "The box is gone," Jake said. "The box is text," said Ethan.
📌 If you keep one line from this page
Indra OCR turns PDFs and scans into Markdown, text or JSON on any CPU (pip install indra-ocr, then indra-ocr file.pdf), about 24 times faster than Tesseract with layout and tables; it does not read handwriting, and its weights are free for personal use, research and startups under $20M.
Python 3.10+ · 18 MB of models · INDRA_OCR_MODEL_DIR for offline machines · --math for formulas · OCRmyPDF for searchable PDFs.
Revision note. Written October 19, 2026. "Good things come in small packages," the saying goes; this one is 18 MB and reads a page in a quarter of a second.