Free OCR API for PDFs and Scanned Documents

Quick answer: For a hosted OCR API with no credit card, use OCR.space (25,000 requests/month) for small images and short PDFs, or Google Gemini for long or complex documents (up to 1,000 pages per file). The moment documents are sensitive or volume is real, self-host Docling (MIT, unlimited, runs on your laptop). Two of the most capable options — Gemini and Mistral — no longer publish their free-tier limits, so plan for HTTP 429 rather than a fixed number.

Every RAG pipeline, invoice parser, and document agent starts with the same problem: the text you need is trapped inside a PDF that's really a picture of a page. OCR gets it out, and in 2026 there are more ways to do it at $0 than ever. But "free OCR API" covers three different deals — a real recurring quota with no card, a discount inside a paid product, and open weights you run yourself — with different ceilings, failure modes, and licenses. Every number below is quoted from provider docs; where a provider stopped publishing its limits, this guide says so.

Which free OCR API should you use?

OptionWhat "free" meansCard?Best for
OCR.space25,000 req/month, 500/day per IPNoSmall images and 1-3 page PDFs; fastest start
Cloudflare Workers AI10,000 Neurons/day, recurringNoOCR at the edge inside a Worker you already run
Google GeminiFree tier on Flash models; limits unpublishedNoWhole documents — 1,000 pages/file, layout + meaning in one call
Google Cloud VisionFirst 1,000 units/month free, then $1.50/1,000YesHigh-volume plain text at the lowest committed price
Mistral OCR 4Free mode exists; page limits unpublishedNoMarkdown + tables + bounding boxes in one response
Docling / Tesseract / olmOCRGenuinely unlimited — open source, self-hostedNoPrivate data, air-gapped, no quota ceiling ever

OCR.space: the no-friction free tier

The least glamorous option and the fastest to a working result. Request a free key by email — no console, no billing account. The API page gives you 25,000 requests/month, capped at 500/day per IP, across three engines (Engine 3 covers 200+ languages). The catches: files max 1 MB, PDFs max 3 pages, each page counting separately. This is an API for receipts and single-page forms, not a 200-page contract. Uniquely, its FAQ grants commercial use on the free plan (with no uptime guarantee).

import requests

resp = requests.post(
    "https://api.ocr.space/parse/image",
    files={"file": open("receipt.jpg", "rb")},
    data={"apikey": "YOUR_FREE_KEY", "language": "eng", "OCREngine": "2", "isTable": "true"},
    timeout=60,
)
resp.raise_for_status()
result = resp.json()

# A 200 does not mean every page was read. Over the 3-page cap the API still
# returns 200, sets IsErroredOnProcessing, and hands back only the first three.
if result.get("IsErroredOnProcessing"):
    raise RuntimeError(f"OCR exit {result.get('OCRExitCode')}: {result.get('ErrorMessage')}")

for page in result["ParsedResults"]:
    print(page["ParsedText"])

isTable: true preserves column alignment with whitespace — far more parseable for receipts and tables.

The 3-page cap does not fail loudly

We generated PDFs with a known number of pages and sent them through, because a documented limit and an enforced one are different things. The limit is real, but the way it reports itself will cost you data if you are not looking for it:

InputHTTPIsErroredOnProcessingWhat you get back
3-page PDF200falseAll 3 pages
5-page PDF200truePages 1-3 only, OCRExitCode 4

The message is explicit — "The maximum page limit of 3 was reached and only pages upto the limit were parsed successfully" — but it arrives inside a 200 OK. Code that checks the status code and then reads ParsedResults[0], which is how most examples are written including the one in this article until today, prints page one and never learns that two pages were discarded. On a batch of receipts you would not notice for weeks. Check IsErroredOnProcessing on every response.

One warning about evaluating it: the helloworld key OCR.space publishes for testing returned 503 on roughly half our requests, regardless of file size. That is the shared demo key being busy, not the service being down — get your own free key before judging reliability.

Cloudflare Workers AI: OCR at the edge

If you already deploy on Cloudflare, the OCR sits next to your code. The pricing page gives 10,000 Neurons/day free on both Free and Paid plans; the Free plan hard-stops instead of billing you (the Paid plan charges $0.011/1,000 Neurons). Reach for @cf/moondream/moondream3.1-9B-A2B, which Cloudflare describes as delivering OCR and structured output.

export default {
  async fetch(request, env) {
    const bytes = await request.arrayBuffer();
    const response = await env.AI.run("@cf/moondream/moondream3.1-9B-A2B", {
      image: [...new Uint8Array(bytes)],
      prompt: "Transcribe all text in this image exactly. Output plain text only.",
      max_tokens: 1024,
    });
    return Response.json({ text: response.description ?? response });
  },
};

The caveat: these are VLMs, so cost is measured in tokens and a dense page produces a lot — budget empirically. See our guide to Cloudflare Workers AI and its free edge model catalogue.

Google Gemini: the most capable free path

Gemini reads a document the way a person would — knowing that this block is a header, that this is a table, that this margin scrawl is a correction. The docs support PDFs up to 50MB or 1,000 pages (258 tokens/page), and the Files API is free in all regions, storing uploads for 48 hours. Several Flash models are "Free of charge" on the standard tier, and a free key needs no card.

But Google no longer publishes free-tier rate limits. The rate limits page now says they "can be viewed in Google AI Studio" — account-specific, with no public RPM/RPD table. Any capacity plan built on a specific free RPD figure is building on a number Google won't commit to in writing. Check your own quota and handle 429 at runtime.

from google import genai

client = genai.Client(api_key="YOUR_GEMINI_KEY")
uploaded = client.files.upload(file="scanned_contract.pdf")
response = client.models.generate_content(
    model="gemini-2.5-flash",
    contents=[uploaded,
        "Transcribe this document to clean Markdown. Preserve heading levels "
        "and render every table as a Markdown table. Do not summarize or omit anything."],
)
print(response.text)

That single call does OCR, layout reconstruction, and Markdown conversion at once. The trade-off is every LLM's: it can hallucinate a confident, plausible-but-wrong digit where a classical engine returns detectable garbage. For invoices or medical records, validate against a second pass. See our complete guide to the free Google Gemini API.

Google Cloud Vision: the cheap high-volume workhorse

The enterprise-grade classical option, with the most transparent pricing. Per the pricing page: first 1,000 units/month free, then $1.50/1,000 up to 5M (dropping to $0.60 above). Each PDF page counts as one image, so 1,000 free units ≈ 1,000 free pages. The gate: it requires a GCP billing account with a card — the free units are a discount, not a fence. At $1.50/1,000 pages it's roughly 2.7× cheaper than Mistral OCR 4 for straight text.

from google.cloud import vision

client = vision.ImageAnnotatorClient()
with open("scan.png", "rb") as f:
    image = vision.Image(content=f.read())
response = client.document_text_detection(image=image)
print(response.full_text_annotation.text)

Mistral OCR 4: structure in one response

A purpose-built OCR model, not a general VLM moonlighting. Per the docs, a response can include markdown, images, tables, hyperlinks, and blocks (bounding boxes via include_blocks=True), from PNG, JPEG, PDF, PPTX, and DOCX inputs. Watch the price — the widely-quoted ~$1/1,000 figure is stale. The current page lists OCR at $4/1,000 pages (Document AI $5), halved with batch. A free mode exists, but like Google, Mistral publishes no free-tier number — it lives in your admin panel.

from mistralai import Mistral

client = Mistral(api_key="YOUR_MISTRAL_KEY")
uploaded = client.files.upload(
    file={"file_name": "report.pdf", "content": open("report.pdf", "rb")}, purpose="ocr")
signed = client.files.get_signed_url(file_id=uploaded.id)
result = client.ocr.process(
    model="mistral-ocr-latest",
    document={"type": "document_url", "document_url": signed.url})
for page in result.pages:
    print(page.markdown)

If you already use Mistral's chat models, this is one more capability behind the same key — see the Mistral AI free API guide.

The pattern nobody talks about: free limits went dark

The most useful finding here isn't a number — it's that two of the four hosted providers, Gemini and Mistral, have removed their free-tier limits from public docs entirely. Both now say "log in and look." Free-tier capacity is now account-specific and adjustable without an announcement. Three things follow:

  • Distrust every specific free-tier RPD figure you read, including in articles published this month — if the provider doesn't publish it, the author can't verify it.
  • Check your own console and treat the number as true for your account today only.
  • Handle 429 as a normal condition. Backoff and a fallback provider are no longer optional — LiteLLM makes multi-provider fallback a two-line config.

OCR.space (25,000/month), Cloudflare (10,000 Neurons/day), and Cloud Vision (1,000 units/month) still publish hard numbers — a legitimate reason to prefer them for anything you must plan around.

Self-hosting: the only truly unlimited free OCR

If documents are sensitive, volume is real, or you want a number nobody can change on you, run the model yourself. Docling (IBM, MIT, 63k stars) is the best default — it handles layout, reading order, table structure, formulas, and OCR over scanned PDFs, with explicit "air-gapped environments" support. Its Markdown output drops straight into a free vector database like Qdrant or Chroma.

from docling.document_converter import DocumentConverter

result = DocumentConverter().convert("scanned_report.pdf")
print(result.document.export_to_markdown())  # tables preserved, ready to chunk

Tesseract (Apache 2.0) is still the fastest way to OCR a clean image on CPU — but its own docs warn it needs 300+ DPI and degrades fast on skew or uneven backgrounds. Excellent on clean straight scans, weak on a phone photo of a crumpled receipt; preprocessing is the job. olmOCR (AllenAI, Apache-2.0) is built for scale, with a README claim of "less than $200 per million pages" — versus ~$1,500 on Cloud Vision and ~$4,000 on Mistral. Pair it with Modal's free GPU credits if you don't own a GPU. PaddleOCR (Apache-2.0, 85k stars) leads on multilingual (50-111 languages); RapidOCR (Apache-2.0) wraps its models in ONNX for CPU-only and embedded use.

The licensing trap: free code, restricted weights

This is the section that justifies the article. Two of the best-known OCR projects — Marker and Surya (both Datalab) — split licensing across two layers, and the second one bites.

ProjectCode licenseModel weights license
MarkerApache 2.0Modified AI Pubs Open Rail-M — free for research/personal use and startups under $5M funding/revenue
SuryaApache 2.0Modified AI Pubs Open Rail-M — free for research/personal use and startups under $5M

Seeing "Apache 2.0" on Surya's badge tells you about the code and nothing about your right to use the model commercially. Cross the revenue threshold and you need a purchased license from Datalab, for either project. These are fine tools — Surya reports 83.3% on olmOCR-bench and 5 pages/s on an RTX 5090 — but "open source" and "free for your use case" are different claims. The unencumbered set, safe for commercial use with no revenue test: Docling (MIT), Tesseract, olmOCR, PaddleOCR, and RapidOCR (all Apache 2.0). Both thresholds are quoted from the projects' own READMEs as of August 2026 — Marker relicensed its code from GPL-3.0 to Apache 2.0 and both now sit at $5M, so older write-ups citing GPL or a $2M cap are out of date. Read the actual LICENSE file and README before you ship.

OCR or document AI? Pick the right tool

  • You need OCR when the goal is characters — page in, string out. Tesseract, Cloud Vision, OCR.space. Fast, cheap, deterministic, never make anything up.
  • You need document AI when the goal is structure or meaning — reading order across columns, "which cell is the total," Markdown for a chunker. Mistral OCR, Docling, Gemini.

Running Tesseract on a two-column academic PDF and getting interleaved sentences isn't an OCR failure — the characters were right; reading order is a layout task. Docling and Mistral solve it natively; Tesseract doesn't claim to. On the money side: at 5,000 pages a one-off ingest is ~$6 on Cloud Vision or $0 self-hosted on Docling — at 500,000 pages ($750), self-hosting is obviously correct.

FAQ

What is the best completely free OCR API with no credit card?

OCR.space — 25,000 requests/month, no card, explicit commercial-use grant. Its 1 MB and 3-page ceilings are the price. If those block you, Cloudflare Workers AI's 10,000 Neurons/day is the next-best no-card quota.

Can I use a free OCR API commercially?

OCR.space, yes (no uptime guarantee). Among open-source tools it depends on the license: Docling, Tesseract, olmOCR, PaddleOCR, RapidOCR are commercially safe; Marker and Surya carry revenue-capped weight licenses above their thresholds. For hosted APIs, check the provider's current terms.

Is Gemini good at OCR compared to a real OCR engine?

On messy documents — photos, skew, handwriting, complex layouts — a modern VLM usually reads better because it uses context. That same mechanism is the risk: it can produce a confident wrong character where Tesseract emits obvious garbage. For high-stakes numbers, prefer a deterministic engine or validate.

What is the cheapest way to OCR a million pages?

Self-hosting olmOCR ("less than $200 per million pages" per its README). The cheapest hosted option is Cloud Vision at $1.50/1,000 units — about $1,500 for a million pages, dropping to $0.60/1,000 above 5 million.

The bottom line

Free OCR in 2026 is genuinely solved for small volumes and cheap for large ones. OCR.space, Cloudflare, and Cloud Vision publish hard numbers you can plan against; Gemini and Mistral, the two most capable, have moved their ceilings behind a login. Check your own console, handle rate limits as a normal path, and keep a fallback key. And when a project truly matters — private documents, climbing volume, a license lawyer with questions — the answer has been in the open all along: pip install docling, MIT, runs on your laptop, no quota, no meter. The best free OCR API may be the one you host yourself.

Related Reads