Skip to content

Extract invoice data

Read an invoice’s supplier, dates, totals, tax and line items into JSON or Excel.

Needs our servers

This needs Pro or an API plan. Sign in or see the plans.

Drop PDF, JPG, PNG, TIFF, HEIC or WebP files here

Needs our servers. You confirm before anything is uploaded.

Deleted 60 minutes after you download it.

Save as

Paying a supplier, filing an expense, entering a bill in your books: the figures are on the invoice, and typing them in is slow. Extract invoice data reads them for you, from a PDF or from a scan or photo of the page, and checks each value against the invoice’s own words before you rely on it. It runs on our servers with a model on Cloudflare Workers AI, which keeps neither your invoice nor its data, and the notice before you upload says when your file and the result are deleted.

About the formats

PDFPDF document

PDF is the standard format for documents that should look the same everywhere. It can hold text, images and vector graphics across many pages.

JPGJPEG image

JPG (or JPEG) is the most widely supported photo format. Its lossy compression keeps files small, which suits photos but not sharp text or transparency.

PNGPNG image

PNG is a lossless image format with transparency. It’s ideal for screenshots, logos and graphics with sharp edges, but photos come out larger than JPG.

TIFFTIFF image

TIFF is a high-quality image format used for scanning, printing and archiving. One file can hold several pages, and files are usually large.

HEICHEIC image

HEIC (HEIF) is the photo format iPhones and iPads use. It keeps high quality at about half the size of JPG, but many Windows apps and websites can’t open it.

WebPWebP image

WebP is an image format made for the web. Files are smaller than JPG and PNG and can have transparency or animation, but some older apps can’t open it.

JSONJSON file

JSON is the text format web APIs and apps use to exchange data: objects, lists, text, numbers and true or false values, nested as deep as needed.

XLSXExcel workbook

XLSX is the workbook format of Microsoft Excel since 2007: sheets of cells with formulas, formatting and charts.

Converted with Invoice extraction (Workers AI).

Questions

What do I get?

The supplier and the customer with their addresses and tax numbers, the invoice number, the issue and due dates, the currency, the subtotal, each tax line with its rate, the tax, any amount withheld, the total, and every line item with its quantity, unit price and amount. JSON gives them as fields your code can read; the Excel workbook puts the fields on one sheet and the line items on another, as figures you can sum.

How do I know the figures are right?

Every value is checked against the invoice’s own words, and one we can’t find there is left empty instead of guessed. We also check that the line items add up to the subtotal and that the subtotal and tax make the total, and the result says which checks passed. Nothing is corrected for you, so a failed check is the place to look.

Can it read scans and photos of invoices?

Yes. A scanned PDF, or a JPG, PNG, TIFF, HEIC or WebP picture, is read with OCR first, and the model is shown a picture of each page too. For a photo, lay the invoice flat in even light and let it fill the frame. Invoices of up to 10 pages can be read, and Korean can’t be read yet.

Who can extract invoices?

Invoice extraction is an add-on for Pro, the API plans and Enterprise, and it uses credits for each page, counted before it starts. Visitors without one of those plans are told before they choose a file, so nothing is uploaded. Through the API, test keys can try it on any plan.

Where is my invoice processed?

It’s stored and read on our servers in the United States, and its words and pictures of its pages go to a model on Cloudflare Workers AI, which keeps neither. Accounts that keep their files in the EU can’t use it. The invoice and the result are deleted on the schedule shown before you upload.

Extract invoice data with the API

Convert from your code with one request. See the Extract invoice data API

curl "https://api.formatjet.com/v1/convert?conversion=extract-invoice" \
  -H "Authorization: Bearer $FORMATJET_API_KEY" \
  -F file=@input.pdf \
  -o output.json