[Integrations](https://spiral.ai/integrations) › [Gemini](https://spiral.ai/integrations/gemini) › [Mistral OCR document extraction](https://spiral.ai/integrations/gemini/mistral-ocr-document-extraction)

# How to Use Mistral OCR document extraction in Gemini

Extracts page-by-page Markdown, tables, images, and document structure from PDFs and images. Use it to turn reports or scanned documents into readable content, with annotations when you need structured records.

|  |  |
| --- | --- |
| Model | Mistral OCR document extraction |
| Available through | Mistral |
| Category | Data |
| Price | $0.0052 per page ($0.0065 with document or bounding-box annotations). |
| Returns | json |
| Runs | In the background |
| Setup | About 2 minutes, no API key |

## Prompts to try with Mistral OCR document extraction in Gemini

- Use Mistral OCR document extraction on https://arxiv.org/pdf/1706.03762 and show me the abstract and section headings.
- Use Mistral OCR document extraction on https://arxiv.org/pdf/2201.04234 and show its extracted tables with their page numbers.
- Use Mistral OCR document extraction on https://arxiv.org/pdf/2410.07073 and list the extracted figures alongside their surrounding captions.
- Use Mistral OCR document extraction on https://arxiv.org/pdf/2302.13971 and extract the paragraphs discussing training data, keeping their page references.
- Use Mistral OCR document extraction on the first ten pages of https://arxiv.org/pdf/1511.08771 and show the extracted headings and equations.

## How to set up Mistral OCR document extraction in Gemini

Pick the way that suits you. Each takes about two minutes.

### Use the Gemini connector

1. **Open Connected Apps**: On your computer, go to gemini.google.com. At the bottom, click Settings › Connected Apps. If you don't see Connected Apps, click Personal Intelligence first, then Connected Apps.

2. **Add Spiral as a custom app**: Under Custom apps, click Add a custom app and paste this MCP server URL:

```text
https://api.spiral.ai/mcp
```

3. **Sign in to Spiral and approve**: Follow the on-screen instructions. Spiral opens: sign in, pick the organization and click Authorize. No API key.

### Use the Spiral skill

1. **Send Gemini this message**: Your agent reads Spiral's skill and sets itself up.

```
set up https://spiral.ai/SKILL.md
```

2. **Sign in or paste a key**: Approve Spiral in the browser, or give the agent a key from the console.

### Use the Spiral CLI

1. **Install and sign in**: Installs the Spiral CLI, signs you in and adds its skill to your coding agents.

```bash
npx -y spiral-cli@latest init
```

### Call the Spiral API

1. **Create an API key**: In the console, under API keys.

2. **Run Mistral OCR document extraction**: One request; the result comes back by polling or a webhook.

```bash
curl https://api.spiral.ai/v1/runs \
  -H "Authorization: Bearer $SPIRAL_API_KEY" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{
    "provider": "mistral",
    "model": "mistral-ocr-latest",
    "input": {
      "document": {
        "document_url": "<document_url>"
      }
    }
  }'
```

Then paste one of the prompts above: Gemini finds Mistral OCR document extraction on Spiral, shows the price and runs it.

Setup guide in the docs: https://spiral.ai/docs/quickstarts/gemini

## Mistral OCR document extraction tools and prices

- [Mistral OCR Latest](https://spiral.ai/tools/mistral/mistral-ocr-latest) (Mistral): $0.0052 per page ($0.0065 with document or bounding-box annotations).

## Settings you can ask for

| Setting | Allowed values | Default | Description |
| --- | --- | --- | --- |
| pages |  | — | Specific pages to process. Accepts a list of integers or a string of comma-separated numbers and ranges (e.g. '0,1,2' or '0-5' or '0,2-4'). Page numbers start from 0. |
| image_limit |  | — | Max images to extract |
| table_format | markdown, html | — |  |
| extract_footer |  | false | Extract the page footer into the response's `footer` field and remove it from the markdown content |
| extract_header |  | false | Extract the page header into the response's `header` field and remove it from the markdown content |
| image_min_size |  | — | Minimum height and width of image to extract |

## What can you do with Mistral OCR document extraction in Gemini?

Get readable text and tables from a research PDF for a discussion grounded in its contents. Mistral OCR provides the extracted pages and images your chat assistant can use to explain a section or compare reported results.

### Make research papers searchable

Convert paper PDFs into Markdown and organize extracted sections by page for a research search index.

### Compare tables across published reports

Extract tables from annual reports, then compare matching rows while retaining their source pages.

### Turn equipment manuals into reference material

Extract manual text, tables, and diagrams so a support assistant can work from the supplied documentation.

### Build a figure catalog

Collect extracted figures and their page locations, then request individual figure annotations for a browsable research catalog.

### Prepare document review overlays

Use paragraph bounding boxes and structural labels to connect extracted content with the corresponding region of a document page.

### Create structured report records

Use document annotations to extract selected titles, reporting periods, and other stated details into a consistent JSON structure.

### Digitize multilingual publications

Extract text from English, French, German, and Spanish publications for a searchable archive that retains the original wording.

## Overview

- [Mistral](https://spiral.ai/providers/mistral)
- [All Gemini guides](https://spiral.ai/integrations/gemini)

## Mistral OCR document extraction in other agents

- [Amp](https://spiral.ai/integrations/amp/mistral-ocr-document-extraction)
- [ChatGPT](https://spiral.ai/integrations/chatgpt/mistral-ocr-document-extraction)
- [Claude](https://spiral.ai/integrations/claude-desktop/mistral-ocr-document-extraction)
- [Claude Code](https://spiral.ai/integrations/claude-code/mistral-ocr-document-extraction)
- [Cline](https://spiral.ai/integrations/cline/mistral-ocr-document-extraction)
- [Codex](https://spiral.ai/integrations/codex/mistral-ocr-document-extraction)
- [Cursor](https://spiral.ai/integrations/cursor/mistral-ocr-document-extraction)
- [Devin](https://spiral.ai/integrations/devin/mistral-ocr-document-extraction)
- [dots](https://spiral.ai/integrations/dots/mistral-ocr-document-extraction)
- [Factory Droid](https://spiral.ai/integrations/factory-droid/mistral-ocr-document-extraction)
- [Gemini CLI](https://spiral.ai/integrations/gemini-cli/mistral-ocr-document-extraction)
- [Google Antigravity](https://spiral.ai/integrations/antigravity/mistral-ocr-document-extraction)
- [goose](https://spiral.ai/integrations/goose/mistral-ocr-document-extraction)
- [Grok](https://spiral.ai/integrations/grok/mistral-ocr-document-extraction)
- [Grok Build](https://spiral.ai/integrations/grok-build/mistral-ocr-document-extraction)
- [Hermes](https://spiral.ai/integrations/hermes/mistral-ocr-document-extraction)
- [Instinct](https://spiral.ai/integrations/instinct/mistral-ocr-document-extraction)
- [Manus](https://spiral.ai/integrations/manus/mistral-ocr-document-extraction)
- [Muse](https://spiral.ai/integrations/muse/mistral-ocr-document-extraction)
- [Muse Code](https://spiral.ai/integrations/muse-code/mistral-ocr-document-extraction)
- [n8n](https://spiral.ai/integrations/n8n/mistral-ocr-document-extraction)
- [Notion](https://spiral.ai/integrations/notion/mistral-ocr-document-extraction)
- [OpenClaw](https://spiral.ai/integrations/openclaw/mistral-ocr-document-extraction)
- [opencode](https://spiral.ai/integrations/opencode/mistral-ocr-document-extraction)
- [Perplexity](https://spiral.ai/integrations/perplexity/mistral-ocr-document-extraction)
- [Raycast](https://spiral.ai/integrations/raycast/mistral-ocr-document-extraction)
- [VS Code](https://spiral.ai/integrations/vscode/mistral-ocr-document-extraction)
- [Windsurf](https://spiral.ai/integrations/windsurf/mistral-ocr-document-extraction)
- [Zapier](https://spiral.ai/integrations/zapier/mistral-ocr-document-extraction)

## More Gemini guides

- [Mistral OCR 4.1](https://spiral.ai/integrations/gemini/mistral-ocr-4-1)
- [Mistral document OCR](https://spiral.ai/integrations/gemini/mistral-document-ocr)
- [GitHub user repositories](https://spiral.ai/integrations/gemini/github-user-repositories)
- [Mistral document text and table extraction](https://spiral.ai/integrations/gemini/mistral-document-text-and-table-extraction)
- [GitHub user pull requests](https://spiral.ai/integrations/gemini/github-user-pull-requests)
- [Mistral document text extraction](https://spiral.ai/integrations/gemini/mistral-document-text-extraction)

## Questions about Mistral OCR document extraction in Gemini

**Can Gemini use Mistral OCR document extraction?**

Yes. Add Spiral to Gemini as an MCP server, and Gemini can find and run Mistral OCR document extraction like any built-in tool.

**How much does Mistral OCR document extraction cost in Gemini?**

$0.0052 per page ($0.0065 with document or bounding-box annotations). You pay from your Spiral balance as you go, with no subscription, and a failed run is not charged. Your Gemini plan is separate.

**Do I need a Mistral account to use Mistral OCR document extraction in Gemini?**

No. Spiral runs Mistral OCR document extraction on its own Mistral account. You sign in to Spiral once and never paste a key.

**How long does it take to set up Mistral OCR document extraction in Gemini?**

About two minutes: open Connected Apps, then add Spiral as a custom app, then sign in to Spiral and approve.

**Does Gemini wait while Mistral OCR document extraction runs?**

Mistral OCR document extraction runs in the background. Gemini starts the run, checks on it and gives you the json when it's ready.

**How large can a document be?**

Mistral's chunking cookbook identifies limits of 50 MB and 1,000 pages. For larger documents, it recommends splitting the file, processing the pieces, and combining their results.

**Which languages can Mistral OCR read?**

The documented OCR language list includes English, French, German, Spanish, Portuguese, Italian, Dutch, Polish, and Czech. Coverage extends beyond English-language documents.

**Does document-level annotation inspect every extracted image?**

It receives the OCR Markdown plus the first eight extracted image bounding boxes. For figure-heavy documents, use annotations on individual extracted figures when you need descriptions beyond that boundary.

**Does the latest OCR model stay fixed?**

The latest alias can change: Mistral's changelog currently points it to OCR 4.1. The OCR response also identifies which model produced the extraction.

**How can I check recognition quality?**

OCR 4.1 supports paragraph locations, structural labels, and block-level confidence scores, which can help target a review. Mistral also acknowledges that generated output can be inaccurate.

