First, the 60-second test
Any n8n invoice OCR decision starts with one question about the file: is it a document or a picture? A document's characters were stored by the program that made it, and any tool can copy them out with the layout intact. A picture — a scan, a phone photo — has pixels and no characters behind them. The second kind is what OCR is for. The first kind is what you get when a supplier exports the invoice from accounting software.
You can tell which one you have without installing anything. Open the PDF and try to select
a line of text with the mouse. If the selection works, the text is there. From a terminal,
pdftotext invoice.pdf - | wc -c prints a number: a few hundred bytes means a text
layer, a handful of bytes means a picture.
The same test inside n8n is Extract From File, operation Extract From
PDF. It has no OCR step: it reads the characters the PDF already contains and returns
them as text.1 On a run over five PDFs, four of ours
returned 263, 198, 263 and 157 characters of legible invoice text. The fifth — the same invoice
page rasterised into an image, which is what a scan is — returned 0 characters and no
error. That silence is the trap: there is nothing to catch, the workflow simply
carries on with an empty string.
Why the empty result matters more than the failed one. A thrown error stops a workflow. An empty extraction does not: the next node finds no supplier, no total, no invoice number, and if it is written carelessly it books a row of blanks. Whatever you build, make "no text layer" a recorded outcome with a reason, not an absence.
The four routes, and what each one is for
| Route | Cost for 1,000 one-page invoices | What leaves your server | Works on a scan |
|---|---|---|---|
| Text layer (Extract From File) | nothing | nothing | no |
| Cloud OCR API | USD 1.50 to 10, see below | the whole PDF | yes |
| LLM vision call | priced per token, no fixed figure | the page image or the PDF | yes |
| Local OCR engine | nothing but your CPU | nothing | yes |
The cost column is arithmetic on the vendors' published prices, one page per invoice, 1,000 invoices. No discount tier, no free allowance, no rounding in our favour. Prices change: check the page before you budget.
Route 1 — the text layer, which costs nothing
If the 60-second test said "selectable", you are done: Extract From File plus a parser, on the machine you already run. No API key, no per-page fee, and the invoice never leaves the box. This is the route our own templates take, and the reason is not ideology: a deterministic parser produces the same answer for the same bytes, you can read the code that produced it, and when it is wrong you can point at the line.
The catch is that "text layer" is not a promise of clean text. A PDF from a good accounting system yields tidy lines; one exported from a word processor can yield text in drawing order, with the total before the supplier's name; and a "print to PDF" of a viewer can carry a text layer assembled from an image, which extracts as garbage. Extracting is the easy half — the invoice pipeline guide is about the other half.
Route 2 — a cloud OCR API
Three services, each reachable from n8n with an HTTP Request node; AWS Textract and Mistral also have their own nodes in the core package. Prices read from the vendor's own page on 2026-11-17, quoted in USD, first tier only:
| Service | Published price | Per 1,000 pages |
|---|---|---|
| Google Document AI, Enterprise Document OCR | USD 1.50 per 1,000 pages (1–5,000,000 pages/month); USD 0.60 above that | USD 1.50 |
| Google Document AI, Invoice parser | USD 0.10 for every 10 pages | USD 10 |
| AWS Textract, Detect Document Text | USD 0.0015 per page for the first 1,000,000 pages/month; USD 0.0006 after | USD 1.50 |
| AWS Textract, Analyze Expense | USD 0.01 per page for the first 1,000,000 pages/month; USD 0.008 after | USD 10 |
| Mistral OCR 4.1 | USD 4 per 1,000 pages; USD 5 per 1,000 annotated pages | USD 4 |
Sources: Google Cloud Document AI pricing, Amazon Textract pricing (US West, Oregon), Mistral OCR 4.1. Azure Document Intelligence publishes a per-page price too, but its pricing page renders the numbers with a script, so no figure is quoted here rather than a figure we could not read ourselves.
What leaves your server: the document. That is the whole trade. For a supplier invoice it is a page with names, addresses, bank details and amounts on it, sent to a third party under their terms, in a jurisdiction you may not have chosen. Whether that is acceptable is a question for your business, not for this page — but it is the question a price list cannot answer.
What the price does not include: pages. Google's own note is that every page of a PDF is a page, and that an image is one page, so a ten-page statement is ten pages and a supplier who sends one invoice per file as a two-page PDF doubles your unit cost. Nothing in the table includes the retry when the API times out, or the re-run of last month because the export was wrong.
Route 3 — an LLM vision call
Send the page image, or the PDF, to a multimodal model with instructions to return JSON. It is genuinely good at layouts that break patterns: a supplier who puts the total in the footer, a table with merged cells, a credit note whose sign is in a footnote.
It is also the route with the least predictable bill, because the unit is a token, not a page. A dense A4 invoice image costs several times what a sparse one costs, and the same invoice re-sent at a different resolution is a different price. So this page does not quote a per-invoice figure for it: any number would be a guess dressed as a measurement. If you go this way, measure on your own twenty invoices first, and count retries.
The second cost bites at audit time: a model that answers differently on Tuesday is not wrong, it is unexplainable. If a booked amount later looks odd, you can point at a regex; pointing at a sampled answer is harder. Keep the model's raw answer and the page image it saw, so a human can check both later.
Route 4 — a local OCR engine
Tesseract is the free, open-source OCR engine that most "local OCR" means. It runs on your
own machine, costs nothing per page, and sends nothing anywhere.2
It reads images, which matters in n8n: a PDF has to become page images before Tesseract
can look at them, and n8n's core nodes have no rasterising step. That is a real piece of work,
not a checkbox — either a helper container that calls pdftoppm, or an external
service.
There is a community node that wraps Tesseract.js for n8n
(n8n-nodes-tesseractjs, version 1.7.0 at the time of writing; its npm description
reads "A n8n module that exposes Tesseract.js, an OCR library that can detect text on
images").3 It is
worth knowing before you plan around it: a community node is third-party code you install into
your instance, and since n8n 2.0 the Execute Command and Local File Trigger
nodes are disabled by default, so the "shell out to tesseract" trick needs a
configuration change (NODES_EXCLUDE) and a security decision that goes with
it.4
The usual good compromise: run Tesseract in its own small container, call it over HTTP from n8n, and keep the invoice on the same machine the whole way.
Before you trust any total
Whichever route your n8n invoice OCR uses, the number that matters is not the accuracy percentage — it is whether a wrong read can reach your ledger unnoticed. Four checks do most of that work:
- Net plus tax equals the total, within a cent or two. OCR that misreads one digit of a total almost always breaks this, and it costs nothing to check.
- Format checks on the obvious fields: an invoice number with at least one digit, a date inside a sane range, a currency that is one of the ones you actually use.
- A status and a reason per row.
ok,needs_reviewwith the reason,duplicate. A ledger where "missing" and "wrong" look the same is worse than one that admits both. - The original file, kept. Every row should point at the PDF it came from, so a human can settle a doubt in ten seconds instead of re-reading a month.
And the duplicate problem does not go away because OCR was involved: the same invoice arrives twice, forwarded, re-sent, or scanned again by a colleague. Matching on supplier plus invoice number as text catches most of it; the invoice guide has the three checks in the order that works.
When to stop automating
OCR earns its keep when you have many suppliers, many scans, and a person already spending hours typing. Below that line the honest answer is often a folder and a habit: twelve scanned invoices a month from three suppliers is ten minutes of typing, not a pipeline nobody maintains. Automate the shape that repeats, not the exception that irritates — and if half of your suppliers photograph invoices on a phone, you need a review queue more than you need OCR, because somebody has to look at those invoices anyway.
What our pack does — and does not
Plainly: we do not do OCR. The eleven-workflow pack and the three free starters read the text layer and parse it with plain JavaScript. A scan comes out as empty fields and a reason, by design — a guess in a ledger is worse than a gap. If your invoices are scans, route 2 or route 4 is the right answer, and this site will not pretend otherwise.
If they are machine-made PDFs, the pack does the whole job on your own machine: IMAP trigger, text layer, parse, the arithmetic check, three duplicate checks, a review queue, approvals, and a nightly dated copy of the ledger. The attachment guide covers getting the PDFs out of the mailbox in the first place.
Invoice Ledger — 11 workflows, USD 49
Also listed on the n8n template library. Before buying, run the free starter on one of your own invoices: it is the same parser, and it saves nothing, so it costs you a minute.
Sources
- n8n docs — Extract From File (the operation list: CSV, HTML, JSON, ICS, ODS, PDF, RTF, Text, XLS, XLSX, base64 — there is no OCR operation). Read 2026-11-17.
- Tesseract OCR (open-source engine, Apache-2.0; reads images). Read 2026-11-17.
- npm — n8n-nodes-tesseractjs (version 1.7.0, Tesseract.js wrapper). Read 2026-11-17.
- n8n docs — v2.0 breaking changes (Execute Command and Local File Trigger disabled by default;
NODES_EXCLUDE). Read 2026-11-17.