Math Formula OCR
Capture screen regions, clipboard images, or files to recognize printed and handwritten math formulas into LaTeX offline and copy automatically.
Screenshots
Key Features
Select a screen region to recognize math formulas as LaTeX and copy
formula capture / screenshot latex / math ocr region
Recognize math formulas from clipboard images and copy LaTeX
clipboard formula / clipboard latex / paste formula ocr
Recognize formulas from image files, preview rendering, and copy LaTeX
formula ocr / latex ocr / math to latex / image to latex
Overview & Usage Guide
Recognize mathematical formulas from screen captures, the clipboard, or image files into LaTeX locally on your device without uploading images. Supports both printed formulas (textbooks, papers, slides) and handwritten formulas. Can also be opened directly by typing latex in the launcher.
First-Time Setup
The recognition model is not bundled with the client installer. The first time you open Math Formula OCR, press Enter to download it (around 114 MB, one-time download). Downloads run inside the client and continue even if you close the plugin, showing progress when reopened. Failed downloads can be retried while preserving intact downloaded files. Once downloaded, recognition runs completely offline.
Usage
- Region Capture (
formula capture,screenshot latex): Hides the ZTools window so you can drag-select a formula on screen and pressEnter(Escto cancel). The recognized LaTeX is copied to the clipboard in your selected format with a system notification. - Clipboard Recognition (
clipboard formula,clipboard latex): Recognizes a formula image from the clipboard and copies the resulting LaTeX back to the clipboard. - Formula Workbench (
formula ocr,latex ocr):- Use "Capture Region" (
⌘/Ctrl+N) or "Add Images" (⌘/Ctrl+O, supports multi-select, processed sequentially) in the top bar. The action panel also offers "Select Folder..." (⌘/Ctrl+Shift+O, recursively collects up to 5 levels and 100 images per batch) and "Recognize Clipboard Image" (⌘/Ctrl+Shift+V), or you can drag and drop or paste images and folders directly. Screen capture and clipboard results are copied automatically. - The right pane displays the original image preview, rendered math preview, and raw LaTeX source for verification. Previews preserve original aspect ratio and colors; older entries may retain only source text.
- On completed items, press
Enterto copy in the active format, or⌘/Ctrl+Enter/⌘/Ctrl+Eto edit (with live preview;⌘/Ctrl+Entersaves,Escdiscards).⌘/Ctrl+Klists all copy formats. On failed items, pressEnterto retry.
- Use "Capture Region" (
- Copy Format: Choose on the right of the workbench search bar: Inline Math
$…$(default, ideal for Markdown, Typora, Obsidian, Notion), Display Math$$…$$, or Raw LaTeX. The preference is saved and also applies to region capture and clipboard commands. - Selection Tips: Capture one formula at a time—leaving a bit of margin is fine since extra whitespace is trimmed automatically. Dark-background screenshots are also supported.
Scope & Limitations
- Recognizes one formula per capture (multi-line formulas such as systems of equations, matrices, and piecewise functions are supported). For mixed text-and-formula pages, select the formula region separately.
- Non-math text mixed inside a formula (such as prose words) is poorly recognized; select only the mathematical expression.
- Output is LaTeX source code and individual symbols may occasionally be misread; verify against the rendered preview on the right for important work.
- Bold styling, vector markers, grouping braces, and text spacing are preserved without automatic stripping. A successful render or high model score does not guarantee accuracy—always verify against the original image; the "Please verify" badge is only an extra reminder when model confidence is low.
Platforms & Requirements
- Supported: macOS (requires client version 1.1.8.11 or later). Windows support will open after physical-device verification.
- macOS: Region capture requires enabling Screen Recording permission for ZTools under System Settings > Privacy & Security.
Network & Data
- Network access is used only for the initial model download (tries the official ZTools CDN, Hugging Face, and its mirror in order; upstream and mirror pin the exact same commit, and every file is verified against the same SHA-256 checksum). Recognition runs offline and images never leave your device.
- Temporary screenshots from region capture and clipboard recognition are deleted immediately after recognition.
- Recognition results and image previews are kept in memory only and cleared when the client exits. Up to 50 finished results and 4 MiB of preview images are retained; deleting results or clearing the list removes their previews. Headless commands do not keep image previews.
- Recognition model: Pix2Text-MFR 1.5 (MIT License).
Frequently Asked Questions (FAQ)
How do I install and launch "Math Formula OCR" in ZTools?
Open the Plugin Marketplace inside ZTools Workbench, search for "Math Formula OCR", and install it. Then type its name in the launcher bar to open it.
Is "Math Formula OCR" free? Which platforms are supported?
Yes, it is free to install with source code published in the ZTools-extensions repository. Supported platforms: macOS.