Beginner 12 minVision

Free PDF OCR: make a scanned PDF recherchable

Sheets of paper are spread out beside a laptop on a wooden desk.
Direct response

To OCR a PDF for free without uploading it, use OCRmyPDF: this open-source tool adds an invisible text layer to a scanned PDF, making it searchable and copyable while keeping the images at their original resolution. Install it with the French language data for Tesseract, then run ocrmypdf -l fra entree.pdf sortie.pdf. Online tools such as PDF24 process the file on their servers. Version 17.14.2 as of November 18, 2026.

A scanned PDF is just a sequence of images: you can't search it for a word or copy a sentence from it. OCR fixes this by adding the recognized text beneath each page. You'll learn how to choose between an online tool and a local tool, install OCRmyPDF with French language support, process a scan, a mixed PDF, or a skewed one, and check the result.

By Mohamed Meguedmi·Update 2026-11-22·Tested on Windows, macOS, and Linux

#What is PDF OCR?

PDF OCR (optical character recognition) reads the text contained in the images of a scanned PDF, then adds it to the file as an invisible text layer. The page image stays in place, but you can finally search it for a word, select a sentence, and copy it.

A PDF produced by a scanner contains only images. A "born-digital" PDF, exported from a word processor, already contains real text and doesn't need OCR.

OCR
A technique that turns an image of text into characters a computer can read. Tesseract and RapidOCR are two open-source OCR engines.
Text layer
Invisible text placed beneath each page's image, in the correct positions. It's what makes a scanned PDF searchable and copyable.
PDF/A
A PDF variant designed for long-term archiving. It imposes certain constraints, such as no password protection.
Mixed PDF
A document that mixes born-digital pages, with real text, and scanned pages, with no text.

OCRmyPDF is free, open-source command-line software that, according to its official repository, adds an OCR text layer to scanned PDFs so you can search them or copy and paste from them. It uses the Tesseract engine on your machine: the document never leaves your computer.

#Which free OCR software should you choose for a PDF?

The complete kit for building your own AI assistant.

Benefit from our experience and a guided path to build your local assistant and use your AI every day.

  • Lifetime online access
  • PDF + files
  • Refunded within 30 days

To make a scanned PDF searchable for free, OCRmyPDF is the preferred local option when the result needs to stay a PDF: it is open source, free, and adds the text layer to the existing file. Free online OCR tools are simpler, but they upload your file to a server.

The PDF24 OCR page, accessed November 18, 2026, states that text is recognized on its cloud servers, that these servers are located in Germany, and that files are deleted automatically after one hour. For a contract, a pay slip, or a medical record, a local tool like OCRmyPDF avoids uploading anything.

Free PDF OCR: which option fits your situation (verified November 18, 2026)
Your use caseFree optionWhere pages are processedWhat you get
Ordinary document, one-off need, no terminalOnline OCR tool (PDF24, iLovePDF, etc.)Vendor's serverSearchable PDF, terms specific to each service
Confidential document, Mac, Linux, or WindowsOCRmyPDF with TesseractYour computerPDF or PDF/A with a text layer, original intact
Tables, codes, small cellsOCRmyPDF with the RapidOCR engineYour computer, on the CPUPDF with a text layer, heavier installation
Need only the text, no PDFTesseract directlyYour computerPlain text file
Extract tables and structure for an AILocal vision model or converterYour computer, sometimes with a GPUStructured text, not a searchable PDF

#How do you install OCRmyPDF and the French language pack?

To install OCRmyPDF, use your system's package manager: Homebrew on Mac, apt on Debian and Ubuntu, winget and uv on Windows. You need three separate components: OCRmyPDF, the Tesseract engine, and the French language data. With the wrong language, OCR quality can be poor, the documentation warns.

The installation documentation sets minimum requirements: Python 3.11 and Tesseract 4.1.1, on Ubuntu 22.04 LTS or Debian 12 at the oldest. Because Debian and Ubuntu packages can lag several major versions behind, it recommends uv in that case.

  1. 01
    Mac: install with Homebrew
    Run brew install ocrmypdf, then brew install tesseract-lang. According to the documentation, Homebrew installs Tesseract, Ghostscript, jbig2enc, pngquant, unpaper and all required dependencies, with English only; the tesseract-lang package adds all other languages, including French.
  2. 02
    Debian or Ubuntu: install with apt
    Run sudo apt-get install ocrmypdf, which also installs Tesseract and Ghostscript. The French language package is called tesseract-ocr-fra in the Ubuntu archives (apt-cache search tesseract-ocr lists them all): the documentation gives the template apt-get install tesseract-ocr-chi-sim, where you just replace chi-sim with fra. If the available version is too old, install uv, then run uv tool install ocrmypdf.
  3. 03
    Windows: install Tesseract, uv, then OCRmyPDF
    Install Tesseract and uv with winget, then install Ghostscript manually from its website: it isn't available in winget. In a new window, run uv tool install ocrmypdf. For French, the documentation doesn't say whether the Tesseract installer obtained through winget provides fra.traineddata (the Chocolatey one includes only English): check whether it's present in C:\Program Files\Tesseract-OCR\tessdata, and if not, download it from the official tessdata repository.
  4. 04
    Check the installed version
    Run ocrmypdf --version. The examples in this guide use the --mode option, introduced in OCRmyPDF 17; on an older version, use the legacy options listed below.
Mac (Homebrew)
brew install ocrmypdf
brew install tesseract-lang
Linux (Debian, Ubuntu, WSL)
sudo apt-get update
sudo apt-get -y install ocrmypdf
apt-cache search tesseract-ocr
ocrmypdf --version
Windows (PowerShell)
winget install -e --id tesseract-ocr.tesseract
winget install -e --id astral-sh.uv
uv tool install ocrmypdf
ocrmypdf --version

The latest release published on the OCRmyPDF GitHub repository, checked on November 18, 2026, is 17.14.2, released on November 16, 2026. On Fedora, the documentation specifies dnf install ocrmypdf tesseract-osd; language packages there are named tesseract-langpack followed by the language code.

#Local web interface: the OCRmyPDF Docker image

The official OCRmyPDF Docker image includes a small Streamlit web interface and, according to its documentation, already includes French among its six default languages. When you start it with the command below, it opens at http://localhost:8501 and processes files on your machine. The documentation describes it as a demo tool with no security or authentication: never expose it to the internet.

Docker
docker run --entrypoint python -p 8501:8501 jbarlow83/ocrmypdf /app/webservice.py

#How do you OCR a PDF with OCRmyPDF?

To OCR a PDF, give OCRmyPDF the input file, a different output file name, and the document's language. The command below produces a standard searchable PDF in French and leaves the original untouched.

Terminal
ocrmypdf -l fra --output-type pdf courrier-scan.pdf courrier-scan-ocr.pdf
-l fra
Specifies the language. According to the official cookbook, OCRmyPDF assumes an English document if nothing is specified, because Tesseract can't detect an unknown language. For a bilingual document, write -l eng+fra.
--output-type pdf
Produces a standard PDF. Since version 17.0.0, the default output is auto: OCRmyPDF tries a PDF/A and falls back to a regular PDF if the conversion fails. Choose pdfa only if archiving requires it, because a PDF/A cannot be password-protected.
--sidecar fichier.txt
Also writes the recognized text to a separate text file, handy for proofreading the OCR. Pages that already contained text are not included.

#How do you handle a mixed PDF or one that has already been OCRed?

For a mixed PDF, use --mode skip: OCRmyPDF leaves pages that already have text untouched and processes only the scanned pages. Without this option, the tool stops as soon as a page contains text, without modifying the file, to protect born-digital PDFs.

Terminal
ocrmypdf -l fra --output-type pdf --mode skip dossier-mixte.pdf dossier-mixte-ocr.pdf
OCRmyPDF 17 OCR modes and their legacy options
ModeEffect according to the documentationWhen to use itOption before version 17
None (default)Error if text is foundFully scanned PDFNone
skipSkips pages that already have textMixed PDF, assembled document set--skip-text
redoRemoves the old invisible OCR layer and redoes the OCROld, poor-quality OCR layer--redo-ocr
forceConverts everything to images, then runs OCR, keeping the linksLast resort, non-searchable text--force-ocr
force-ocr-no-linksLike force, but also removes the linksLinks that are themselves sensitiveNone

Force mode is a last resort: the advanced documentation states that it converts every page into an image, rasterizes printable text, and flattens form fields. The real text of digital pages is then replaced by approximate recognition. Redo mode, on the other hand, doesn't rasterize, but it's incompatible with image processing options such as deskewing.

The advanced documentation recommends --output-type pdf to ensure that born-digital pages in a tagged PDF keep their structure, which conversion to PDF/A by Ghostscript 10 strips out. The old --skip-text, --redo-ocr, and --force-ocr options are still accepted as aliases: use them if ocrmypdf --version shows a version earlier than 17.

#How do you straighten a skewed or rotated scan before OCR?

For a skewed scan, add --deskew; for a page rotated a quarter turn or upside down, add --rotate-pages. Both options correct the image before recognition, but they modify the page: use them only on scans that need them.

Terminal
ocrmypdf -l fra --output-type pdf --rotate-pages --deskew scan-penche.pdf scan-penche-ocr.pdf

According to the official cookbook, --deskew is for when the page is just slightly crooked, and --rotate-pages for when the overall orientation is wrong. The default value of --rotate-pages-threshold is conservative: on some files, OCRmyPDF won't rotate any page unless it's very confident. On Fedora, automatic rotation requires the tesseract-osd package.

!
Review the pages after processing
The documentation recommends reviewing files after any image processing, which can remove useful content from low-quality scans. A command that runs without errors doesn't prove the orientation is correct: check every rotated or deskewed page.

#How do you check that PDF OCR succeeded?

You verify a successful PDF OCR on both the text and the document: open the original and the output side by side, then check search, accents, numbers, and page rendering.

  1. 01
    Search for an exact phrase
    Use Ctrl+F or Cmd+F to search for a sentence you read on a specific page of the scan. It should be found on that page.
  2. 02
    Copy and paste a paragraph
    Paste a paragraph into a text editor. Check the accents (é, è, à, ç), the œ ligature and the apostrophes.
  3. 03
    Compare the numbers
    Compare amounts, dates, and reference numbers against the original. Mix-ups between 0 and O, or between 1 and l, often creep in.
  4. 04
    Control pages and rendering
    The page count and page order must match. At high zoom, compare sharpness, colors, and orientation, especially after --deskew or --rotate-pages. Then keep the original PDF alongside the output.
i
Test from November 17, 2026
Tested on Linux aarch64 with OCRmyPDF 17.14.2, Tesseract 5.3.4, and Ghostscript 10.02.1, on three demo PDFs created for the purpose: a scanned French letter, a mixed PDF processed with --mode skip, and a skewed scan that was deskewed. Accents, the reference, and the amount (1 234,56) were recovered; the text on the native page of the mixed PDF was unchanged; the rendering of the scan and of the mixed PDF's scanned page is pixel-for-pixel identical, and the deskewing was inspected. Limitation: a simple synthetic corpus, with no overall recognition rate and no guarantee of accuracy for every PDF.

#When not to run OCR on a PDF

OCRmyPDF doesn't modify digitally signed PDFs: the security documentation states that the tool detects signed PDFs and leaves them unmodified, unless you use the --invalidate-digital-signatures option, which invalidates the signature. A certificate-encrypted PDF can't be opened at all, and a PDF whose text is already correct needs no processing.

#AI-powered OCR: when should you switch to RapidOCR or a vision model?

AI OCR refers to engines based on neural networks, described as more accurate than Tesseract on certain documents. OCRmyPDF has included one since version 17.14.0: RapidOCR, which runs PaddleOCR's PP-OCR models on the CPU, without a graphics card, and still produces a searchable PDF.

Terminal
uv tool install 'ocrmypdf[rapidocr]'
ocrmypdf --ocr-engine rapidocr -l fra --output-type pdf scan.pdf scan-ocr.pdf

According to the official documentation, RapidOCR often reads numbers, codes, and small table cells more accurately than Tesseract; this is the publisher's claim, so verify it on your own documents. The cost is real: the option adds about 340 MB to the installation, and RapidOCR needs about 1.2 GB of memory per worker process and about four times as much CPU time per page as Tesseract. French is among the languages supported by the bundled model, and -l accepts Tesseract language codes. One caveat for offline use: with --rotate-pages, RapidOCR downloads its orientation model from Hugging Face the first time it runs.

When your goal is to extract tables or feed documents to an AI, a local vision model such as DeepSeek-OCR or PaddleOCR-VL is a better fit: these tools produce structured text, not a searchable PDF (see the guides linked below).

Frequently asked questions
Can you OCR a password-protected PDF?+
OCRmyPDF doesn't remove a PDF's password: its security documentation points to separate software, qpdf, to remove it when you know it, before running OCR. To then password-protect the PDF that OCRmyPDF produces, request --output-type pdf, because a PDF/A can't have one.
Can you convert a scanned PDF to Word with OCR?+
OCRmyPDF doesn't produce a Word file: it adds a text layer to a PDF, which remains a PDF. The --sidecar option writes the recognized text to a .txt file you can paste into Word. To keep headings and tables, a document converter such as Docling is better suited than plain OCR.
Is OCRmyPDF really free, even for a business?+
OCRmyPDF is free software released under the Mozilla Public License 2.0, which allows commercial use and integration into closed-source software, provided you publish any changes made to OCRmyPDF's own code. Ghostscript, which OCRmyPDF requires, is licensed under AGPLv3: the documentation asks you to comply with the licenses of all dependencies, especially if you integrate OCRmyPDF into a product or service.
Do you need a graphics card to OCR a PDF?+
No. OCRmyPDF with Tesseract runs on the CPU and spreads the work across all available cores, according to its official repository. The RapidOCR engine also runs on the CPU, but uses more memory. A graphics card is mainly useful for vision models, which serve a different need.
Is the PDF larger after OCR than the original?+
Not necessarily. The OCRmyPDF repository states that the tool optimizes images and often produces files smaller than the original. However, the installation documentation notes that the OCRmyPDF packages for Debian, Ubuntu, and Fedora don't install the JBIG2 encoder, and that without it the output files are larger. On Debian 13 and Ubuntu 24.04 or later, you can install it with apt install jbig2.
Does OCRmyPDF recognize French and handwriting?+
OCRmyPDF recognizes French as soon as Tesseract's French language data is installed and you add -l fra. The repository states that Tesseract supports more than 100 languages. Handwriting is not the intended use case: according to its FAQ, Tesseract is designed for printed text.

#Sources and verification as of November 18, 2026

The commands, options, versions, and limits cited here were checked on November 18, 2026, against the official OCRmyPDF documentation, its GitHub repository, and the PDF24 OCR page. Version numbers, distribution packages, and the terms of online services may change.

Did this guide help you?

Feedback, an error, or a clarification? Let us know—it improves the guide for everyone.